diff options
author | Matthew Burgess <matthew@linuxfromscratch.org> | 2005-03-13 15:49:41 +0000 |
---|---|---|
committer | Matthew Burgess <matthew@linuxfromscratch.org> | 2005-03-13 15:49:41 +0000 |
commit | 516b668fa04586bca9bbca6ee131f9f8299d6fc4 (patch) | |
tree | 2b9fbef5a8780b3c166202c52f5e2a484d35fe44 /chapter05 | |
parent | e2c85b1176f0059b7c877922fe22bb8b677d0982 (diff) |
* Fix bug 1061 by dynamically linking the pass1 toolchain
git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@4741 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689
Diffstat (limited to 'chapter05')
-rw-r--r-- | chapter05/binutils-pass1.xml | 36 | ||||
-rw-r--r-- | chapter05/gcc-pass1.xml | 21 | ||||
-rw-r--r-- | chapter05/toolchaintechnotes.xml | 7 |
3 files changed, 17 insertions, 47 deletions
diff --git a/chapter05/binutils-pass1.xml b/chapter05/binutils-pass1.xml index 9f35ae722..e2eafc63e 100644 --- a/chapter05/binutils-pass1.xml +++ b/chapter05/binutils-pass1.xml @@ -54,8 +54,7 @@ command like this: <userinput>time { ./configure ... && ... <para>Now prepare Binutils for compilation:</para> -<screen><userinput>../binutils-&binutils-version;/configure --prefix=/tools \ - --disable-nls</userinput></screen> +<screen><userinput>../binutils-&binutils-version;/configure --prefix=/tools --disable-nls</userinput></screen> <para>The meaning of the configure options:</para> @@ -68,36 +67,14 @@ programs in the <filename class="directory">/tools</filename> directory.</para>< <varlistentry> <term><parameter>--disable-nls</parameter></term> -<listitem><para>This disables internationalization. This is not needed -for the static programs, and NLS can cause problems when linking -statically.</para></listitem> +<listitem><para>This disables internationalization. This is not needed for the +temporary tools.</para></listitem> </varlistentry> </variablelist> <para>Continue with compiling the package:</para> -<screen><userinput>make configure-host -make LDFLAGS="-all-static"</userinput></screen> - -<para>The meaning of the make parameters:</para> - -<variablelist> -<varlistentry> -<term><parameter>configure-host</parameter></term> -<listitem><para>This forces all subdirectories to be configured -immediately. A statically-linked build will fail without it. Use this -option to work around the problem.</para></listitem> -</varlistentry> - -<varlistentry> -<term><parameter>LDFLAGS="-all-static"</parameter></term> -<listitem><para>This tells the linker that all Binutils programs -should be linked statically. However, strictly speaking, -<parameter>"-all-static"</parameter> is passed to the -<command>libtool</command> program, which then passes -<parameter>"-static"</parameter> to the linker.</para></listitem> -</varlistentry> -</variablelist> +<screen><userinput>make</userinput></screen> <para>Compilation is now complete. Ordinarily we would now run the test suite, but at this early stage the test suite framework (Tcl, @@ -113,7 +90,7 @@ first pass will soon be replaced by those from the second.</para> later on:</para> <screen><userinput>make -C ld clean -make -C ld LDFLAGS="-all-static" LIB_PATH=/tools/lib</userinput></screen> +make -C ld LIB_PATH=/tools/lib</userinput></screen> <para>The meaning of the make parameters:</para> @@ -126,8 +103,7 @@ subdirectory.</para></listitem> </varlistentry> <varlistentry> -<term><parameter>-C ld LDFLAGS="-all-static" -LIB_PATH=/tools/lib</parameter></term> +<term><parameter>-C ld LIB_PATH=/tools/lib</parameter></term> <listitem><para>This option rebuilds everything in the <filename class="directory">ld</filename> subdirectory. Specifying the <envar>LIB_PATH</envar> Makefile variable on the command diff --git a/chapter05/gcc-pass1.xml b/chapter05/gcc-pass1.xml index 503438558..f2bec515b 100644 --- a/chapter05/gcc-pass1.xml +++ b/chapter05/gcc-pass1.xml @@ -63,16 +63,12 @@ system.</para> <varlistentry> <term><parameter>--enable-shared</parameter></term> -<listitem><para>This switch may seem counter-intuitive at first. -However, this switch allows the building of +<listitem><para>This switch allows the building of <filename class="libraryfile">libgcc_s.so.1</filename> and -<filename class="libraryfile">libgcc_eh.a</filename>, and having -<filename class="libraryfile">libgcc_eh.a</filename> available ensures that the configure -script for Glibc (the next package we compile) produces the proper -results. Note that the GCC binaries will still be linked statically -because this is controlled by the <parameter>-static</parameter> value of -the <envar>BOOT_LDFLAGS</envar> variable in the next -step.</para></listitem> +<filename class="libraryfile">libgcc_eh.a</filename>. Having +<filename class="libraryfile">libgcc_eh.a</filename> available ensures that the +configure script for Glibc (the next package we compile) produces the proper +results.</para></listitem> </varlistentry> <varlistentry> @@ -86,17 +82,12 @@ tarball.</para></listitem> <para>Continue with compiling the package:</para> -<screen><userinput>make BOOT_LDFLAGS="-static" bootstrap</userinput></screen> +<screen><userinput>make bootstrap</userinput></screen> <para>The meaning of the make parameters:</para> <variablelist> <varlistentry> -<term><parameter>BOOT_LDFLAGS="-static"</parameter></term> -<listitem><para>This tells GCC to link its programs statically.</para></listitem> -</varlistentry> - -<varlistentry> <term><parameter>bootstrap</parameter></term> <listitem><para>This target does not just compile GCC, but compiles it several times. It uses the programs compiled in a first round to diff --git a/chapter05/toolchaintechnotes.xml b/chapter05/toolchaintechnotes.xml index 9c2951387..9a065a054 100644 --- a/chapter05/toolchaintechnotes.xml +++ b/chapter05/toolchaintechnotes.xml @@ -175,7 +175,10 @@ class="directory">/usr</filename>, perform a quick changeover of the toolchain defaults, then proceed in building the rest of the target LFS system.</para> -<sect2> +<!-- Removed as part of the fix for bug 1061 - we no longer build pass1 + packages statically, therefore this explanation isn't required --> + +<!--<sect2> <title>Notes on Static Linking</title> <para>Besides their specific task, most programs have to perform many @@ -218,7 +221,7 @@ programs can be used independently of the host system. However, it is worth noting that an overall successful LFS build can still be achieved when the first two packages are built dynamically.</para> -</sect2> +</sect2>--> </sect1> |