Delay the creation of the X atoms until we really need them, to allow
[wine.git] / documentation / cvs-regression.sgml
blobe82579194a24871a04f8f3479f2370755dac8317
1 <chapter id="cvs-regression">
2 <title>How to do regression testing using CVS</title>
4 <para>
5 A problem that can happen sometimes is 'it used to work
6 before, now it doesn't anymore...'. Here is a step by step
7 procedure to try to pinpoint when the problem occurred. This is
8 <emphasis>NOT</emphasis> for casual users.
9 </para>
11 <orderedlist>
12 <listitem>
13 <para>
14 Get the <quote>full CVS</quote> archive from winehq. This archive is
15 the CVS tree but with the tags controlling the versioning
16 system. It's a big file (> 40 meg) with a name like
17 full-cvs-&lt;last update date> (it's more than 100mb
18 when uncompressed, you can't very well do this with
19 small, old computers or slow Internet connections).
20 </para>
21 </listitem>
22 <listitem>
23 <para>
24 untar it into a repository directory:
25 <screen>
26 cd /home/gerard
27 tar -zxf full-cvs-2003-08-18.tar.gz
28 mv wine repository
29 </screen>
30 </para>
31 </listitem>
32 <listitem>
33 <para>
34 extract a new destination directory. This directory must
35 not be in a subdirectory of the repository else
36 <command>cvs</command> will think it's part of the
37 repository and deny you an extraction in the repository:
38 <screen>
39 cd /home/gerard
40 mv wine wine_current (-> this protects your current wine sandbox, if any)
41 export CVSROOT=/home/gerard/repository
42 cvs -d $CVSROOT checkout wine
43 </screen>
44 </para>
45 <para>
46 Note that it's not possible to do a checkout at a given
47 date; you always do the checkout for the last date where
48 the full-cvs-xxx snapshot was generated.
49 </para>
50 <para>
51 Note also that it is possible to do all this with a direct
52 CVS connection, of course. The full CVS file method is less
53 painful for the WineHQ CVS server and probably a bit faster
54 if you don't have a very good net connection.
55 </para>
56 <note>
57 <para>
58 If you use CVS directly from the winehq.com server, do not
59 forget to add to your <filename>.cvsrc</filename> file:
60 </para>
61 <screen>
62 cvs -z 3
63 update -dPA
64 diff -u
65 </screen>
66 </note>
67 </listitem>
68 <listitem>
69 <para>
70 you will have now in the <filename>~/wine</filename>
71 directory an image of the CVS tree, on the client side.
72 Now update this image to the date you want:
73 <screen>
74 cd /home/gerard/wine
75 cvs -d $CVSROOT update -D "2002-06-01 CST"
76 </screen>
77 </para>
78 <para>
79 The date format is <literal>YYYY-MM-DD HH:MM:SS</literal>.
80 Using the CST date format ensure that you will be able to
81 extract patches in a way that will be compatible with the
82 wine-cvs archive
83 <ulink url="http://www.winehq.com/hypermail/wine-cvs">
84 http://www.winehq.com/hypermail/wine-cvs</ulink>
85 </para>
86 <para>
87 Many messages will inform you that more recent files have
88 been deleted to set back the client cvs tree to the date
89 you asked, for example:
90 <screen>
91 cvs update: tsx11/ts_xf86dga2.c is no longer in the repository
92 </screen>
93 </para>
94 <para>
95 <command>cvs update</command> is not limited to upgrade to
96 a <emphasis>newer</emphasis> version as I have believed for
97 far too long :-(
98 </para>
99 </listitem>
100 <listitem>
101 <para>
102 Now proceed as for a normal update:
103 </para>
104 <screen>
105 ./configure
106 make depend && make
107 </screen>
108 <para>
109 If any non-programmer reads this, the fastest method to get
110 at the point where the problem occurred is to use a binary
111 search, that is, if the problem occurred in 1999, start at
112 mid-year, then is the problem is already here, back to 1st
113 April, if not, to 1st October, and so on.
114 </para>
115 <para>
116 If you have lot of hard disk free space (a full compile currently
117 takes 400 Mb), copy the oldest known working version before
118 updating it, it will save time if you need to go back. (it's
119 better to <command>make distclean</command> before going back in
120 time, so you have to make everything if you don't backup the older
121 version)
122 </para>
123 <para>
124 When you have found the day where the problem happened, continue
125 the search using the wine-cvs archive (sorted by date) and a
126 more precise cvs update including hour, minute, second :
127 <screen>
128 cvs -d $CVSROOT update -D "2002-06-01 15:17:25 CST"
129 </screen>
130 This will allow you to find easily the exact patch that did it.
131 </para>
132 </listitem>
133 <listitem>
134 <para>
135 If you find the patch that is the cause of the problem, you have
136 almost won; report about it to
137 <ulink url="http://bugs.winehq.com/">Wine Bugzilla</ulink>
138 or subscribe to wine-devel and post it there. There is a chance
139 that the author
140 will jump in to suggest a fix; or there is always the possibility
141 to look hard at the patch until it is coerced to reveal where is
142 the bug :-)
143 </para>
144 </listitem>
145 </orderedlist>
146 </chapter>
148 <!-- Keep this comment at the end of the file
149 Local variables:
150 mode: sgml
151 sgml-parent-document:("wine-devel.sgml" "set" "book" "part" "chapter" "")
152 End: