[www-patch] Testing C++ changes

Volker Reichelt reichelt@igpm.rwth-aachen.de
Thu Dec 4 02:36:00 GMT 2003


On 27 Nov, Jason Merrill wrote:

>>> $ rm -rf */libstdc++-v3
>>
>> Wouldn't "make clean-target-libstdc++-v3" be enough?
> 
> Usually.  If there have been configury changes since you last built v3,
> sometimes this breaks.  Reconfiguring v3 doesn't take long, so I find it
> simpler to just remove the directory and start over.

Well, personally I don't like "rm -rf" that much. If you do cut-n-paste
you easily end up with an empty hard disk :-)
I also like "make clean-target-libstdc++-v3" better since it is more portable.
(And if configury has changed, a new bootstrap sounds safer anyway.)
So, I left that untouched in the patch below.

Speaking of portability, having a make-target like
"make clean-nat-target-libjava" instead of
"test -d */libjava && make -C */libjava clean-nat"
would be nice.

>> +make -C gcc cc1plus                               # (cc1plus.exe for cygwin) build C++ compiler
> 
> Also, you don't need this step.  all-gcc is implied by
> all-target-libstdc++-v3.

This is nice. No special case for cygwin.

So, here we go again. OK to commit?

Regards,
Volker


Index: contribute.html
===================================================================
RCS file: /cvs/gcc/wwwdocs/htdocs/contribute.html,v
retrieving revision 1.56
diff -u -r1.56 contribute.html
--- contribute.html	17 Nov 2003 15:37:22 -0000	1.56
+++ contribute.html	4 Dec 2003 02:24:45 -0000
@@ -87,18 +87,34 @@
 regression tests to ensure that your patch does not break anything
 else.</p>
 
+<h3>Which tests to perform</h3>
+
 <p>If your change is to code that is not in a front end, or is to the
 C front end, you must perform a complete build of GCC and the runtime
 libraries included with it, on at least one target.  You must
 bootstrap all languages, not just C.  You must also run all of the
 testsuites included with GCC and its runtime libraries.  For a normal
-native configuration, running <code>make bootstrap</code> followed by
-<code>make -k check</code> from the top level of the GCC tree
-(<strong>not</strong> the <code>gcc</code> subdirectory) will
-accomplish this.</p>
+native configuration, running</p>
+<blockquote><pre>
+make bootstrap
+make -k check
+</pre></blockquote>
+<p>from the top level of the GCC tree (<strong>not</strong> the
+<code>gcc</code> subdirectory) will accomplish this.</p>
+
+<p>If your change is to the C++ front end, you should rebuild the compiler,
+<code>libstdc++</code>, <code>libjava</code> and run the C++ testsuite.
+Given that you already did a complete C,C++,Java bootstrap from your build
+directory before, you can use the following:</p>
+<blockquote><pre>
+make clean-target-libstdc++-v3                    # clean libstdc++ and ...
+test -d */libjava && make -C */libjava clean-nat  # ... parts of libjava
+make all-target-libstdc++-v3 all-target-libjava   # rebuild compiler and libraries
+make -k check-c++                                 # run C++/libstdc++ testsuite
+</pre></blockquote>
 
-<p>If your change is to a front end other than the C front end, or a
-runtime library other than <code>libgcc</code>, you need to verify
+<p>If your change is to a front end other than the C or C++ front end,
+or a runtime library other than <code>libgcc</code>, you need to verify
 only that the runtime library for that language still builds and the
 tests for that language have not regressed.  (Most languages have
 tests stored both in the <code>gcc</code> subdirectory, and in the
===================================================================




More information about the Gcc-patches mailing list