|
@@ -44,13 +44,24 @@ cd ../gcc-build</userinput></screen>
|
|
|
|
|
|
<para>Prepare GCC for compilation:</para>
|
|
|
|
|
|
-<screen><userinput>../gcc-&gcc-version;/configure --prefix=/tools \
|
|
|
- --libexecdir=/tools/lib --with-local-prefix=/tools \
|
|
|
- --disable-nls --enable-shared --enable-languages=c</userinput></screen>
|
|
|
+<screen><userinput>CC="gcc -B/usr/bin" ../gcc-&gcc-version;/configure
|
|
|
+ --prefix=/tools --libexecdir=/tools/lib
|
|
|
+ --with-local-prefix=/tools --disable-nls
|
|
|
+ --enable-shared --enable-languages=c</userinput></screen>
|
|
|
|
|
|
<para>The meaning of the configure options:</para>
|
|
|
|
|
|
<variablelist>
|
|
|
+<varlistentry>
|
|
|
+<term><parameter>CC="gcc -B/usr/bin"</parameter></term>
|
|
|
+<listitem><para>This parameter fixes a possible problem with building GCC
|
|
|
+at this stage, first noticed in LFS 5.1.1. If our host uses a new version
|
|
|
+of Binutils than we compiled, the host compiler may try use features not
|
|
|
+supported by our new linker, causing compilation errors. By passing the -B
|
|
|
+flag to gcc, we cause the compiler to temporarily use the host's linker,
|
|
|
+which solves the problem.</para></listitem>
|
|
|
+</varlistentry>
|
|
|
+
|
|
|
<varlistentry>
|
|
|
<term><parameter>--with-local-prefix=/tools</parameter></term>
|
|
|
<listitem><para>The purpose of this switch is to remove <filename class="directory">/usr/local/include</filename>
|