Index: gcc/INSTALL/build.html |
diff --git a/gcc/INSTALL/build.html b/gcc/INSTALL/build.html |
index 30f2b6b0a564f2530e44eeb4743c2ec1208f8488..9bee20f8e306a058d5bed304f978eaa8b2016d07 100644 |
--- a/gcc/INSTALL/build.html |
+++ b/gcc/INSTALL/build.html |
@@ -3,7 +3,7 @@ |
<title>Installing GCC: Building</title> |
<meta http-equiv="Content-Type" content="text/html"> |
<meta name="description" content="Installing GCC: Building"> |
-<meta name="generator" content="makeinfo 4.13"> |
+<meta name="generator" content="makeinfo 4.12"> |
<link title="Top" rel="top" href="#Top"> |
<link href="http://www.gnu.org/software/texinfo/" rel="generator-home" title="Texinfo Homepage"> |
<!-- |
@@ -147,7 +147,7 @@ bootstrapped, you can use <code>CFLAGS_FOR_TARGET</code> to modify their |
compilation flags, as for non-bootstrapped target libraries. |
Again, if the native compiler miscompiles the stage1 compiler, you may |
need to work around this by avoiding non-working parts of the stage1 |
-compiler. Use <code>STAGE1_LIBCFLAGS</code> to this end. |
+compiler. Use <code>STAGE1_TFLAGS</code> to this end. |
<p>If you used the flag <samp><span class="option">--enable-languages=...</span></samp> to restrict |
the compilers to be built, only those you've actually enabled will be |
@@ -171,13 +171,76 @@ the one you are building on: for example, you could build a |
<code>powerpc64-unknown-linux-gnu</code> host. In this case, pass |
<samp><span class="option">--enable-bootstrap</span></samp> to the configure script. |
+ <p><code>BUILD_CONFIG</code> can be used to bring in additional customization |
+to the build. It can be set to a whitespace-separated list of names. |
+For each such <code>NAME</code>, top-level <samp><span class="file">config/</span><code>NAME</code><span class="file">.mk</span></samp> will |
+be included by the top-level <samp><span class="file">Makefile</span></samp>, bringing in any settings |
+it contains. The default <code>BUILD_CONFIG</code> can be set using the |
+configure option <samp><span class="option">--with-build-config=</span><code>NAME</code><span class="option">...</span></samp>. Some |
+examples of supported build configurations are: |
+ |
+ <dl> |
+<dt>‘<samp><span class="samp">bootstrap-O1</span></samp>’<dd>Removes any <samp><span class="option">-O</span></samp>-started option from <code>BOOT_CFLAGS</code>, and adds |
+<samp><span class="option">-O1</span></samp> to it. ‘<samp><span class="samp">BUILD_CONFIG=bootstrap-O1</span></samp>’ is equivalent to |
+‘<samp><span class="samp">BOOT_CFLAGS='-g -O1'</span></samp>’. |
+ |
+ <br><dt>‘<samp><span class="samp">bootstrap-O3</span></samp>’<dd>Analogous to <code>bootstrap-O1</code>. |
+ |
+ <br><dt>‘<samp><span class="samp">bootstrap-debug</span></samp>’<dd>Verifies that the compiler generates the same executable code, whether |
+or not it is asked to emit debug information. To this end, this |
+option builds stage2 host programs without debug information, and uses |
+<samp><span class="file">contrib/compare-debug</span></samp> to compare them with the stripped stage3 |
+object files. If <code>BOOT_CFLAGS</code> is overridden so as to not enable |
+debug information, stage2 will have it, and stage3 won't. This option |
+is enabled by default when GCC bootstrapping is enabled, if |
+<code>strip</code> can turn object files compiled with and without debug |
+info into identical object files. In addition to better test |
+coverage, this option makes default bootstraps faster and leaner. |
+ |
+ <br><dt>‘<samp><span class="samp">bootstrap-debug-big</span></samp>’<dd>Rather than comparing stripped object files, as in |
+<code>bootstrap-debug</code>, this option saves internal compiler dumps |
+during stage2 and stage3 and compares them as well, which helps catch |
+additional potential problems, but at a great cost in terms of disk |
+space. It can be specified in addition to ‘<samp><span class="samp">bootstrap-debug</span></samp>’. |
+ |
+ <br><dt>‘<samp><span class="samp">bootstrap-debug-lean</span></samp>’<dd>This option saves disk space compared with <code>bootstrap-debug-big</code>, |
+but at the expense of some recompilation. Instead of saving the dumps |
+of stage2 and stage3 until the final compare, it uses |
+<samp><span class="option">-fcompare-debug</span></samp> to generate, compare and remove the dumps |
+during stage3, repeating the compilation that already took place in |
+stage2, whose dumps were not saved. |
+ |
+ <br><dt>‘<samp><span class="samp">bootstrap-debug-lib</span></samp>’<dd>This option tests executable code invariance over debug information |
+generation on target libraries, just like <code>bootstrap-debug-lean</code> |
+tests it on host programs. It builds stage3 libraries with |
+<samp><span class="option">-fcompare-debug</span></samp>, and it can be used along with any of the |
+<code>bootstrap-debug</code> options above. |
+ |
+ <p>There aren't <code>-lean</code> or <code>-big</code> counterparts to this option |
+because most libraries are only build in stage3, so bootstrap compares |
+would not get significant coverage. Moreover, the few libraries built |
+in stage2 are used in stage3 host programs, so we wouldn't want to |
+compile stage2 libraries with different options for comparison purposes. |
+ |
+ <br><dt>‘<samp><span class="samp">bootstrap-debug-ckovw</span></samp>’<dd>Arranges for error messages to be issued if the compiler built on any |
+stage is run without the option <samp><span class="option">-fcompare-debug</span></samp>. This is |
+useful to verify the full <samp><span class="option">-fcompare-debug</span></samp> testing coverage. It |
+must be used along with <code>bootstrap-debug-lean</code> and |
+<code>bootstrap-debug-lib</code>. |
+ |
+ <br><dt>‘<samp><span class="samp">bootstrap-time</span></samp>’<dd>Arranges for the run time of each program started by the GCC driver, |
+built in any stage, to be logged to <samp><span class="file">time.log</span></samp>, in the top level of |
+the build tree. |
+ |
+ </dl> |
+ |
<h3 class="section"><a name="TOC1"></a>Building a cross compiler</h3> |
<p>When building a cross compiler, it is not generally possible to do a |
3-stage bootstrap of the compiler. This makes for an interesting problem |
as parts of GCC can only be built with GCC. |
- <p>To build a cross compiler, we first recommend building and installing a |
+ <p>To build a cross compiler, we recommend first building and installing a |
native compiler. You can then use the native GCC compiler to build the |
cross compiler. The installed native compiler needs to be GCC version |
2.95 or later. |
@@ -249,7 +312,7 @@ compilation options. Check your target's definition of |
<h3 class="section"><a name="TOC2"></a>Building in parallel</h3> |
-<p>GNU Make 3.79 and above, which is necessary to build GCC, support |
+<p>GNU Make 3.80 and above, which is necessary to build GCC, support |
building in parallel. To activate this, you can use ‘<samp><span class="samp">make -j 2</span></samp>’ |
instead of ‘<samp><span class="samp">make</span></samp>’. You can also specify a bigger number, and |
in most cases using a value greater than the number of processors in |