Indenting chapter 05, part 1.

git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@7279 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689
This commit is contained in:
Manuel Canales Esparcia 2006-01-17 19:37:53 +00:00
parent 10115162c0
commit 81109e3ece
8 changed files with 454 additions and 348 deletions

View File

@ -1,78 +1,82 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN" "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!ENTITY % general-entities SYSTEM "../general.ent">
%general-entities;
]>
<sect1 id="ch-tools-adjusting">
<title>Adjusting the Toolchain</title>
<?dbhtml filename="adjusting.html"?>
<?dbhtml filename="adjusting.html"?>
<para>Now that the temporary C libraries have been installed, all
tools compiled in the rest of this chapter should be linked against
these libraries. In order to accomplish this, the linker and the
compiler's specs file need to be adjusted.</para>
<title>Adjusting the Toolchain</title>
<para>The linker, adjusted at the end of the first pass of Binutils,
is installed by running the following command from within the
<filename class="directory">binutils-build</filename> directory:</para>
<para>Now that the temporary C libraries have been installed, all
tools compiled in the rest of this chapter should be linked against
these libraries. In order to accomplish this, the linker and the
compiler's specs file need to be adjusted.</para>
<para>The linker, adjusted at the end of the first pass of Binutils,
is installed by running the following command from within the
<filename class="directory">binutils-build</filename> directory:</para>
<screen><userinput>make -C ld install</userinput></screen>
<para>From this point onwards, everything will link only
against the libraries in <filename class="directory">/tools/lib</filename>.</para>
<para>From this point onwards, everything will link only against the
libraries in <filename class="directory">/tools/lib</filename>.</para>
<note><para>If the earlier warning to retain the Binutils source and
build directories from the first pass was missed, ignore the above
command. This results in a small chance that the subsequent testing
programs will link against libraries on the host. This is not ideal,
but it is not a major problem. The situation is corrected when the
second pass of Binutils is installed later.</para></note>
<note>
<para>If the earlier warning to retain the Binutils source and
build directories from the first pass was missed, ignore the above
command. This results in a small chance that the subsequent testing
programs will link against libraries on the host. This is not ideal,
but it is not a major problem. The situation is corrected when the
second pass of Binutils is installed later.</para>
</note>
<para>Now that the adjusted linker is installed, the Binutils build and source
directories should be removed.</para>
<para>Now that the adjusted linker is installed, the Binutils build and source
directories should be removed.</para>
<para>The next task is to point GCC to the new dynamic linker. This is done by
dumping GCC's <quote>specs</quote> file to a location where GCC will look for it
by default. A simple <command>sed</command> substitution then alters the
dynamic linker that GCC will use:</para>
<para>The next task is to point GCC to the new dynamic linker. This is done by
dumping GCC's <quote>specs</quote> file to a location where GCC will look for it
by default. A simple <command>sed</command> substitution then alters the
dynamic linker that GCC will use:</para>
<!-- Ampersands are needed to allow copy and paste -->
<screen><userinput>SPECFILE=`dirname $(gcc -print-libgcc-file-name)`/specs &amp;&amp;
gcc -dumpspecs > $SPECFILE &amp;&amp;
sed 's@^/lib/ld-linux.so.2@/tools&amp;@g' $SPECFILE &gt; tempspecfile &amp;&amp;
mv -vf tempspecfile $SPECFILE &amp;&amp;
unset SPECFILE</userinput></screen>
<para>It is recommended that the above
command be copy-and-pasted in order to ensure accuracy.
Alternatively, the specs file can be edited by hand. This is done by
replacing every occurrence of <quote>/lib/ld-linux.so.2</quote> with
<quote>/tools/lib/ld-linux.so.2</quote></para>
<para>It is recommended that the above command be copy-and-pasted in order to
ensure accuracy. Alternatively, the specs file can be edited by hand. This is
done by replacing every occurrence of <quote>/lib/ld-linux.so.2</quote> with
<quote>/tools/lib/ld-linux.so.2</quote></para>
<para>Be sure to visually inspect the specs file in order to verify the
intended changes have been made.</para>
<para>Be sure to visually inspect the specs file in order to verify the
intended changes have been made.</para>
<important><para>If working on a platform where the name of the
dynamic linker is something other than
<filename class="libraryfile">ld-linux.so.2</filename>, replace
<quote>ld-linux.so.2</quote> with the name of the platform's
dynamic linker in the above commands. Refer back to <xref
linkend="ch-tools-toolchaintechnotes" role=","/> if
necessary.</para></important>
<important>
<para>If working on a platform where the name of the dynamic linker is
something other than <filename class="libraryfile">ld-linux.so.2</filename>,
replace <quote>ld-linux.so.2</quote> with the name of the platform's
dynamic linker in the above commands. Refer back to <xref
linkend="ch-tools-toolchaintechnotes" role=","/> if necessary.</para>
</important>
<para>During the build process, GCC runs a script
(<command>fixincludes</command>) that scans the system for header files that may
need to be fixed (they might contain syntax errors, for example), and installs
the fixed versions in a private include directory. There is a possibility that,
as a result of this process, some header files from the host system have found
their way into GCC's private include directory. As the rest of this chapter only
requires the headers from GCC and Glibc, which have both been installed at this
point, any &quot;fixed&quot; headers can safely be removed. This helps to avoid
any host headers polluting the build environment. Run the following commands to
remove the header files in GCC's private include directory (you may find it
easier to copy and paste these commands, rather than typing them by hand, due to
their length):</para>
<para>During the build process, GCC runs a script
(<command>fixincludes</command>) that scans the system for header files
that may need to be fixed (they might contain syntax errors, for example),
and installs the fixed versions in a private include directory. There is a
possibility that, as a result of this process, some header files from the
host system have found their way into GCC's private include directory. As
the rest of this chapter only requires the headers from GCC and Glibc,
which have both been installed at this point, any <quote>fixed</quote>
headers can safely be removed. This helps to avoid any host headers
polluting the build environment. Run the following commands to remove the
header files in GCC's private include directory (you may find it easier to
copy and paste these commands, rather than typing them by hand, due to
their length):</para>
<!-- && used to ease copy and pasting -->
<screen><userinput>GCC_INCLUDEDIR=`dirname $(gcc -print-libgcc-file-name)`/include &amp;&amp;
@ -80,50 +84,49 @@ find ${GCC_INCLUDEDIR}/* -maxdepth 0 -xtype d -exec rm -rvf '{}' \; &amp;&amp;
rm -vf `grep -l "DO NOT EDIT THIS FILE" ${GCC_INCLUDEDIR}/*` &amp;&amp;
unset GCC_INCLUDEDIR</userinput></screen>
<caution><para>At this point, it is imperative to stop and ensure that
the basic functions (compiling and linking) of the new toolchain are
working as expected. To perform a sanity check, run the following
commands:</para>
<caution>
<para>At this point, it is imperative to stop and ensure that the basic
functions (compiling and linking) of the new toolchain are working as
expected. To perform a sanity check, run the following commands:</para>
<screen><userinput>echo 'main(){}' &gt; dummy.c
cc dummy.c
readelf -l a.out | grep ': /tools'</userinput></screen>
<para>If everything is working correctly, there should be no errors,
and the output of the last command will be of the form:</para>
<para>If everything is working correctly, there should be no errors,
and the output of the last command will be of the form:</para>
<screen><computeroutput>[Requesting program interpreter:
<screen><computeroutput>[Requesting program interpreter:
/tools/lib/ld-linux.so.2]</computeroutput></screen>
<para>Note that <filename class="directory">/tools/lib</filename>
appears as the prefix of the dynamic linker.</para>
<para>Note that <filename class="directory">/tools/lib</filename>
appears as the prefix of the dynamic linker.</para>
<para>If the output is not shown as above or there was no output at
all, then something is wrong. Investigate and retrace the steps to
find out where the problem is and correct it. This issue must be
resolved before continuing on. First, perform the sanity check again,
using <command>gcc</command> instead of <command>cc</command>. If this
works, then the <filename class="symlink">/tools/bin/cc</filename> symlink is missing.
Revisit <xref linkend="ch-tools-gcc-pass1" role=","/> and install the symlink.
Next, ensure that the <envar>PATH</envar> is correct. This can be checked by running
<command>echo $PATH</command> and verifying that <filename
class="directory">/tools/bin</filename> is at the head of the list. If
the <envar>PATH</envar> is wrong it could mean that you are not logged in as user
<emphasis>lfs</emphasis> or that something went wrong back in <xref
linkend="ch-tools-settingenviron" role="."/> Another option is that something
may have gone wrong with the specs file amendment above. In this case,
redo the specs file amendment, being careful to copy-and-paste the
commands.</para>
<para>If the output is not shown as above or there was no output at all,
then something is wrong. Investigate and retrace the steps to find out
where the problem is and correct it. This issue must be resolved before
continuing on. First, perform the sanity check again, using
<command>gcc</command> instead of <command>cc</command>. If this works,
then the <filename class="symlink">/tools/bin/cc</filename> symlink is
missing. Revisit <xref linkend="ch-tools-gcc-pass1" role=","/> and install
the symlink. Next, ensure that the <envar>PATH</envar> is correct. This
can be checked by running <command>echo $PATH</command> and verifying that
<filename class="directory">/tools/bin</filename> is at the head of the
list. If the <envar>PATH</envar> is wrong it could mean that you are not
logged in as user <systemitem class="username">lfs</systemitem> or that
something went wrong back in <xref linkend="ch-tools-settingenviron"
role="."/> Another option is that something may have gone wrong with the
specs file amendment above. In this case, redo the specs file amendment,
being careful to copy-and-paste the commands.</para>
<para>Once all is well, clean up the test files:</para>
<para>Once all is well, clean up the test files:</para>
<screen><userinput>rm -v dummy.c a.out</userinput></screen>
<para>Building TCL in the next section will serve as an additional check that
the toolchain has been built properly. If TCL fails to build, it is an
indication that something has gone wrong with the Binutils, GCC, or Glibc
installation, but not with TCL itself.</para>
</caution>
<para>Building TCL in the next section will serve as an additional check that
the toolchain has been built properly. If TCL fails to build, it is an
indication that something has gone wrong with the Binutils, GCC, or Glibc
installation, but not with TCL itself.</para>
</caution>
</sect1>

View File

@ -1,69 +1,90 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN" "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!ENTITY % general-entities SYSTEM "../general.ent">
%general-entities;
]>
<sect1 id="ch-tools-bash" role="wrap">
<title>Bash-&bash-version;</title>
<?dbhtml filename="bash.html"?>
<?dbhtml filename="bash.html"?>
<indexterm zone="ch-tools-bash">
<primary sortas="a-Bash">Bash</primary>
<secondary>tools</secondary></indexterm>
<title>Bash-&bash-version;</title>
<sect2 role="package"><title/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/bash.xml" xpointer="xpointer(/sect1/sect2[1]/para[1])"/>
<indexterm zone="ch-tools-bash">
<primary sortas="a-Bash">Bash</primary>
<secondary>tools</secondary>
</indexterm>
<segmentedlist>
<segtitle>&buildtime;</segtitle>
<segtitle>&diskspace;</segtitle>
<seglistitem><seg>1.2 SBU</seg><seg>20.7 MB</seg></seglistitem>
</segmentedlist>
<sect2 role="package">
<title/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/bash.xml" xpointer="xpointer(/sect1/sect2[1]/segmentedlist[2])"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
href="../chapter06/bash.xml"
xpointer="xpointer(/sect1/sect2[1]/para[1])"/>
</sect2>
<segmentedlist>
<segtitle>&buildtime;</segtitle>
<segtitle>&diskspace;</segtitle>
<sect2 role="installation">
<title>Installation of Bash</title>
<seglistitem>
<seg>1.2 SBU</seg>
<seg>20.7 MB</seg>
</seglistitem>
</segmentedlist>
<!-- Edit Me -->
<para>Prepare Bash for compilation:</para>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
href="../chapter06/bash.xml"
xpointer="xpointer(/sect1/sect2[1]/segmentedlist[2])"/>
</sect2>
<sect2 role="installation">
<title>Installation of Bash</title>
<para>Prepare Bash for compilation:</para>
<screen><userinput>./configure --prefix=/tools --without-bash-malloc</userinput></screen>
<para>The meaning of the configure options:</para>
<variablelist>
<title>The meaning of the configure options:</title>
<variablelist>
<varlistentry>
<term><parameter>--without-bash-malloc</parameter></term>
<listitem><para>This options turns off the use of Bash's memory
allocation (malloc) function which is known to cause segmentation
faults. By turning this option off, Bash will use the malloc functions
from Glibc which are more stable.</para></listitem>
</varlistentry>
</variablelist>
<varlistentry>
<term><parameter>--without-bash-malloc</parameter></term>
<listitem>
<para>This options turns off the use of Bash's memory allocation
(<function>malloc</function>) function which is known to cause
segmentation faults. By turning this option off, Bash will use
the <function>malloc</function> functions from Glibc which are
more stable.</para>
</listitem>
</varlistentry>
<para>Compile the package:</para>
</variablelist>
<para>Compile the package:</para>
<screen><userinput>make</userinput></screen>
<para>To test the results, issue: <userinput>make tests</userinput>.</para>
<para>To test the results, issue:
<userinput>make tests</userinput>.</para>
<para>Install the package:</para>
<para>Install the package:</para>
<screen><userinput>make install</userinput></screen>
<para>Make a link for the programs that use <command>sh</command> for
a shell:</para>
<para>Make a link for the programs that use <command>sh</command> for
a shell:</para>
<screen><userinput>ln -vs bash /tools/bin/sh</userinput></screen>
</sect2>
</sect2>
<sect2 role="content"><title/>
<para>Details on this package are located in <xref linkend="contents-bash" role="."/></para>
</sect2>
<sect2 role="content">
<title/>
<para>Details on this package are located in
<xref linkend="contents-bash" role="."/></para>
</sect2>
</sect1>

View File

@ -1,122 +1,153 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN" "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!ENTITY % general-entities SYSTEM "../general.ent">
%general-entities;
]>
<sect1 id="ch-tools-binutils-pass1" role="wrap">
<title>Binutils-&binutils-version; - Pass 1</title>
<?dbhtml filename="binutils-pass1.html"?>
<?dbhtml filename="binutils-pass1.html"?>
<indexterm zone="ch-tools-binutils-pass1">
<primary sortas="a-Binutils">Binutils</primary>
<secondary>tools, pass 1</secondary></indexterm>
<title>Binutils-&binutils-version; - Pass 1</title>
<sect2 role="package"><title/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/binutils.xml" xpointer="xpointer(/sect1/sect2[1]/para[1])"/>
<indexterm zone="ch-tools-binutils-pass1">
<primary sortas="a-Binutils">Binutils</primary>
<secondary>tools, pass 1</secondary>
</indexterm>
<segmentedlist>
<segtitle>&buildtime;</segtitle>
<segtitle>&diskspace;</segtitle>
<seglistitem><seg>1.0 SBU</seg><seg>170 MB</seg></seglistitem>
</segmentedlist>
<sect2 role="package">
<title/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/binutils.xml" xpointer="xpointer(/sect1/sect2[1]/segmentedlist[2])"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
href="../chapter06/binutils.xml"
xpointer="xpointer(/sect1/sect2[1]/para[1])"/>
</sect2>
<segmentedlist>
<segtitle>&buildtime;</segtitle>
<segtitle>&diskspace;</segtitle>
<sect2 role="installation">
<title>Installation of Binutils</title>
<seglistitem>
<seg>1.0 SBU</seg>
<seg>170 MB</seg>
</seglistitem>
</segmentedlist>
<para>It is important that Binutils be the first package compiled
because both Glibc and GCC perform various tests on the available
linker and assembler to determine which of their own features to
enable.</para>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
href="../chapter06/binutils.xml"
xpointer="xpointer(/sect1/sect2[1]/segmentedlist[2])"/>
<para>The Binutils documentation recommends building Binutils outside of the
source directory in a dedicated build directory:</para>
</sect2>
<sect2 role="installation">
<title>Installation of Binutils</title>
<para>It is important that Binutils be the first package compiled
because both Glibc and GCC perform various tests on the available
linker and assembler to determine which of their own features to
enable.</para>
<para>The Binutils documentation recommends building Binutils outside of the
source directory in a dedicated build directory:</para>
<screen><userinput>mkdir -v ../binutils-build
cd ../binutils-build</userinput></screen>
<note><para>In order for the SBU values listed in the rest of the book
to be of any use, measure the time it takes to build this package from
the configuration, up to and including the first install. To achieve
this easily, wrap the three commands in a <command>time</command>
command like this: <userinput>time { ./configure ... &amp;&amp; make
&amp;&amp; make install; }</userinput>.</para></note>
<note>
<para>In order for the SBU values listed in the rest of the book
to be of any use, measure the time it takes to build this package from
the configuration, up to and including the first install. To achieve
this easily, wrap the three commands in a <command>time</command>
command like this: <userinput>time { ./configure ... &amp;&amp; make
&amp;&amp; make install; }</userinput>.</para>
</note>
<para>Now prepare Binutils for compilation:</para>
<para>Now prepare Binutils for compilation:</para>
<screen><userinput>../binutils-&binutils-version;/configure --prefix=/tools --disable-nls</userinput></screen>
<para>The meaning of the configure options:</para>
<variablelist>
<title>The meaning of the configure options:</title>
<variablelist>
<varlistentry>
<term><parameter>--prefix=/tools</parameter></term>
<listitem><para>This tells the configure script to prepare to install the Binutils
programs in the <filename class="directory">/tools</filename> directory.</para></listitem>
</varlistentry>
<varlistentry>
<term><parameter>--prefix=/tools</parameter></term>
<listitem>
<para>This tells the configure script to prepare to install the
Binutils programs in the <filename class="directory">/tools</filename>
directory.</para>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter>--disable-nls</parameter></term>
<listitem><para>This disables internationalization as i18n is not needed for the
temporary tools.</para></listitem>
</varlistentry>
</variablelist>
<varlistentry>
<term><parameter>--disable-nls</parameter></term>
<listitem>
<para>This disables internationalization as i18n is not needed for the
temporary tools.</para>
</listitem>
</varlistentry>
<para>Continue with compiling the package:</para>
</variablelist>
<para>Continue with compiling the package:</para>
<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,
Expect, and DejaGNU) is not yet in place. The benefits of running the
tests at this point are minimal since the programs from this
first pass will soon be replaced by those from the second.</para>
<para>Compilation is now complete. Ordinarily we would now run the
test suite, but at this early stage the test suite framework (Tcl,
Expect, and DejaGNU) is not yet in place. The benefits of running the
tests at this point are minimal since the programs from this
first pass will soon be replaced by those from the second.</para>
<para>Install the package:</para>
<para>Install the package:</para>
<screen><userinput>make install</userinput></screen>
<para>Next, prepare the linker for the <quote>Adjusting</quote> phase
later on:</para>
<para>Next, prepare the linker for the <quote>Adjusting</quote> phase
later on:</para>
<screen><userinput>make -C ld clean
make -C ld LIB_PATH=/tools/lib</userinput></screen>
<para>The meaning of the make parameters:</para>
<variablelist>
<title>The meaning of the make parameters:</title>
<variablelist>
<varlistentry>
<term><parameter>-C ld clean</parameter></term>
<listitem><para>This tells the make program to remove all compiled
files in the <filename class="directory">ld</filename>
subdirectory.</para></listitem>
</varlistentry>
<varlistentry>
<term><parameter>-C ld clean</parameter></term>
<listitem>
<para>This tells the make program to remove all compiled
files in the <filename class="directory">ld</filename>
subdirectory.</para>
</listitem>
</varlistentry>
<varlistentry>
<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
line allows us to override the default value
and point it to the temporary tools location. The value of this variable
specifies the linker's default library search path. This preparation
is used later in the chapter.</para></listitem>
</varlistentry>
</variablelist>
<varlistentry>
<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 line
allows us to override the default value and point it to the
temporary tools location. The value of this variable specifies
the linker's default library search path. This preparation is
used later in the chapter.</para>
</listitem>
</varlistentry>
<warning><para><emphasis>Do not</emphasis> remove the Binutils
build and source directories yet. These will be needed again in their
current state later in this chapter.</para></warning>
</variablelist>
</sect2>
<warning>
<para><emphasis>Do not</emphasis> remove the Binutils build and source
directories yet. These will be needed again in their current state later
in this chapter.</para>
</warning>
<sect2 role="content"><title/>
<para>Details on this package are located in <xref
linkend="contents-binutils" role="."/></para>
</sect2>
</sect2>
<sect2 role="content">
<title/>
<para>Details on this package are located in
<xref linkend="contents-binutils" role="."/></para>
</sect2>
</sect1>

View File

@ -1,91 +1,107 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN" "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!ENTITY % general-entities SYSTEM "../general.ent">
%general-entities;
]>
<sect1 id="ch-tools-binutils-pass2" role="wrap">
<title>Binutils-&binutils-version; - Pass 2</title>
<?dbhtml filename="binutils-pass2.html"?>
<?dbhtml filename="binutils-pass2.html"?>
<indexterm zone="ch-tools-binutils-pass2">
<primary sortas="a-Binutils">Binutils</primary>
<secondary>tools, pass 2</secondary></indexterm>
<title>Binutils-&binutils-version; - Pass 2</title>
<sect2 role="package"><title/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
href="../chapter06/binutils.xml"
xpointer="xpointer(/sect1/sect2[1]/para[1])"/>
<indexterm zone="ch-tools-binutils-pass2">
<primary sortas="a-Binutils">Binutils</primary>
<secondary>tools, pass 2</secondary>
</indexterm>
<segmentedlist>
<segtitle>&buildtime;</segtitle>
<segtitle>&diskspace;</segtitle>
<seglistitem><seg>1.5 SBU</seg><seg>114 MB</seg></seglistitem>
</segmentedlist>
<sect2 role="package">
<title/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
href="../chapter06/binutils.xml"
xpointer="xpointer(/sect1/sect2[1]/segmentedlist[2])"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
href="../chapter06/binutils.xml"
xpointer="xpointer(/sect1/sect2[1]/para[1])"/>
</sect2>
<segmentedlist>
<segtitle>&buildtime;</segtitle>
<segtitle>&diskspace;</segtitle>
<sect2 role="installation">
<title>Re-installation of Binutils</title>
<seglistitem>
<seg>1.5 SBU</seg>
<seg>114 MB</seg>
</seglistitem>
</segmentedlist>
<para>Create a separate build directory again:</para>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
href="../chapter06/binutils.xml"
xpointer="xpointer(/sect1/sect2[1]/segmentedlist[2])"/>
</sect2>
<sect2 role="installation">
<title>Re-installation of Binutils</title>
<para>Create a separate build directory again:</para>
<screen><userinput>mkdir -v ../binutils-build
cd ../binutils-build</userinput></screen>
<para>Prepare Binutils for compilation:</para>
<para>Prepare Binutils for compilation:</para>
<screen><userinput>../binutils-&binutils-version;/configure --prefix=/tools \
--disable-nls --enable-shared --with-lib-path=/tools/lib</userinput></screen>
<para>The meaning of the new configure options:</para>
<variablelist>
<title>The meaning of the new configure options:</title>
<variablelist>
<varlistentry>
<term><parameter>--with-lib-path=/tools/lib</parameter></term>
<listitem><para>This tells the configure script to specify the library
search path during the compilation of Binutils, resulting in <filename
class="directory">/tools/lib</filename> being passed to the linker.
This prevents the linker from searching through library directories on
the host.</para></listitem>
</varlistentry>
</variablelist>
<varlistentry>
<term><parameter>--with-lib-path=/tools/lib</parameter></term>
<listitem>
<para>This tells the configure script to specify the library
search path during the compilation of Binutils, resulting in
<filename class="directory">/tools/lib</filename> being passed
to the linker. This prevents the linker from searching through
library directories on the host.</para>
</listitem>
</varlistentry>
<para>Compile the package:</para>
</variablelist>
<para>Compile the package:</para>
<screen><userinput>make</userinput></screen>
<para>Compilation is now complete. As discussed earlier, running the
test suite is not mandatory for the temporary tools here in this
chapter. To run the Binutils test suite anyway, issue the following
command:</para>
<para>Compilation is now complete. As discussed earlier, running the
test suite is not mandatory for the temporary tools here in this
chapter. To run the Binutils test suite anyway, issue the following
command:</para>
<screen><userinput>make check</userinput></screen>
<para>Install the package:</para>
<para>Install the package:</para>
<screen><userinput>make install</userinput></screen>
<para>Now prepare the linker for the <quote>Re-adjusting</quote> phase in the next
chapter:</para>
<para>Now prepare the linker for the <quote>Re-adjusting</quote> phase in
the next chapter:</para>
<screen><userinput>make -C ld clean
make -C ld LIB_PATH=/usr/lib:/lib</userinput></screen>
<warning>
<para><emphasis>Do not</emphasis> remove the Binutils source and build
directories yet. These directories will be needed again in the next
chapter in their current state.</para>
</warning>
<warning><para><emphasis>Do not</emphasis> remove the Binutils source and
build directories yet. These directories will be needed again in the next
chapter in their current state.</para></warning>
</sect2>
</sect2>
<sect2 role="content">
<title/>
<sect2 role="content"><title/>
<para>Details on this package are located in <xref
linkend="contents-binutils" role="."/></para>
</sect2>
<para>Details on this package are located in
<xref linkend="contents-binutils" role="."/></para>
</sect2>
</sect1>

View File

@ -1,53 +1,69 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN" "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!ENTITY % general-entities SYSTEM "../general.ent">
%general-entities;
]>
<sect1 id="ch-tools-bison" xreflabel="Bison" role="wrap">
<title>Bison-&bison-version;</title>
<?dbhtml filename="bison.html"?>
<indexterm zone="ch-tools-bison">
<primary sortas="a-Bison">Bison</primary>
<secondary>tools</secondary></indexterm>
<sect1 id="ch-tools-bison" role="wrap">
<?dbhtml filename="bison.html"?>
<sect2 role="package"><title/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/bison.xml" xpointer="xpointer(/sect1/sect2[1]/para[1])"/>
<title>Bison-&bison-version;</title>
<segmentedlist>
<segtitle>&buildtime;</segtitle>
<segtitle>&diskspace;</segtitle>
<seglistitem><seg>0.6 SBU</seg><seg>10.0 MB</seg></seglistitem>
</segmentedlist>
<indexterm zone="ch-tools-bison">
<primary sortas="a-Bison">Bison</primary>
<secondary>tools</secondary>
</indexterm>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/bison.xml" xpointer="xpointer(/sect1/sect2[1]/segmentedlist[2])"/>
<sect2 role="package">
<title/>
</sect2>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
href="../chapter06/bison.xml"
xpointer="xpointer(/sect1/sect2[1]/para[1])"/>
<sect2 role="installation">
<title>Installation of Bison</title>
<segmentedlist>
<segtitle>&buildtime;</segtitle>
<segtitle>&diskspace;</segtitle>
<para>Prepare Bison for compilation:</para>
<seglistitem>
<seg>0.6 SBU</seg>
<seg>10.0 MB</seg>
</seglistitem>
</segmentedlist>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
href="../chapter06/bison.xml"
xpointer="xpointer(/sect1/sect2[1]/segmentedlist[2])"/>
</sect2>
<sect2 role="installation">
<title>Installation of Bison</title>
<para>Prepare Bison for compilation:</para>
<screen><userinput>./configure --prefix=/tools</userinput></screen>
<para>Compile the package:</para>
<para>Compile the package:</para>
<screen><userinput>make</userinput></screen>
<para>To test the results, issue: <userinput>make
check</userinput>.</para>
<para>To test the results, issue:
<userinput>make check</userinput>.</para>
<para>Install the package:</para>
<para>Install the package:</para>
<screen><userinput>make install</userinput></screen>
</sect2>
</sect2>
<sect2 role="content"><title/>
<para>Details on this package are located in <xref
linkend="contents-bison" role="."/></para>
</sect2>
<sect2 role="content">
<title/>
<para>Details on this package are located in
<xref linkend="contents-bison" role="."/></para>
</sect2>
</sect1>

View File

@ -1,47 +1,63 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN" "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!ENTITY % general-entities SYSTEM "../general.ent">
%general-entities;
]>
<sect1 id="ch-tools-bzip2" role="wrap">
<title>Bzip2-&bzip2-version;</title>
<?dbhtml filename="bzip2.html"?>
<?dbhtml filename="bzip2.html"?>
<indexterm zone="ch-tools-bzip2">
<primary sortas="a-Bzip2">Bzip2</primary>
<secondary>tools</secondary></indexterm>
<title>Bzip2-&bzip2-version;</title>
<sect2 role="package"><title/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/bzip2.xml" xpointer="xpointer(/sect1/sect2[1]/para[1])"/>
<indexterm zone="ch-tools-bzip2">
<primary sortas="a-Bzip2">Bzip2</primary>
<secondary>tools</secondary>
</indexterm>
<segmentedlist>
<segtitle>&buildtime;</segtitle>
<segtitle>&diskspace;</segtitle>
<seglistitem><seg>0.1 SBU</seg><seg>3.5 MB</seg></seglistitem>
</segmentedlist>
<sect2 role="package">
<title/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/bzip2.xml" xpointer="xpointer(/sect1/sect2[1]/segmentedlist[2])"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
href="../chapter06/bzip2.xml"
xpointer="xpointer(/sect1/sect2[1]/para[1])"/>
</sect2>
<segmentedlist>
<segtitle>&buildtime;</segtitle>
<segtitle>&diskspace;</segtitle>
<sect2 role="installation">
<title>Installation of Bzip2</title>
<seglistitem>
<seg>0.1 SBU</seg>
<seg>3.5 MB</seg>
</seglistitem>
</segmentedlist>
<para>The Bzip2 package does not contain a <command>configure</command>
script. Compile and test it with:</para>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude"
href="../chapter06/bzip2.xml"
xpointer="xpointer(/sect1/sect2[1]/segmentedlist[2])"/>
</sect2>
<sect2 role="installation">
<title>Installation of Bzip2</title>
<para>The Bzip2 package does not contain a <command>configure</command>
script. Compile and test it with:</para>
<screen><userinput>make</userinput></screen>
<para>Install the package:</para>
<para>Install the package:</para>
<screen><userinput>make PREFIX=/tools install</userinput></screen>
</sect2>
</sect2>
<sect2 role="content"><title/>
<para>Details on this package are located in <xref
linkend="contents-bzip2" role="."/></para>
</sect2>
<sect2 role="content">
<title/>
<para>Details on this package are located in
<xref linkend="contents-bzip2" role="."/></para>
</sect2>
</sect1>

View File

@ -1,45 +1,48 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN" "http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
<!ENTITY % general-entities SYSTEM "../general.ent">
%general-entities;
]>
<chapter id="chapter-temporary-tools" xreflabel="Chapter 5">
<?dbhtml dir="chapter05"?>
<title>Constructing a Temporary System</title>
<?dbhtml filename="chapter05.html"?>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="introduction.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="toolchaintechnotes.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="binutils-pass1.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="gcc-pass1.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="linux-libc-headers.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="glibc.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="adjusting.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="tcl.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="expect.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="dejagnu.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="gcc-pass2.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="binutils-pass2.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="gawk.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="coreutils.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="bzip2.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="gzip.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="diffutils.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="findutils.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="make.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="grep.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="sed.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="gettext.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="ncurses.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="patch.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="tar.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="texinfo.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="bash.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="m4.xml"/>
<!--<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="bison.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="flex.xml"/>-->
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="util-linux.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="perl.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="stripping.xml"/>
<chapter id="chapter-temporary-tools" xreflabel="Chapter 5">
<?dbhtml dir="chapter05"?>
<?dbhtml filename="chapter05.html"?>
<title>Constructing a Temporary System</title>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="introduction.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="toolchaintechnotes.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="binutils-pass1.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="gcc-pass1.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="linux-libc-headers.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="glibc.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="adjusting.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="tcl.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="expect.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="dejagnu.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="gcc-pass2.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="binutils-pass2.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="gawk.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="coreutils.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="bzip2.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="gzip.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="diffutils.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="findutils.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="make.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="grep.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="sed.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="gettext.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="ncurses.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="patch.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="tar.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="texinfo.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="bash.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="m4.xml"/>
<!--<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="bison.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="flex.xml"/>-->
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="util-linux.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="perl.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="stripping.xml"/>
</chapter>

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!ENTITY version "SVN-20060115">
<!ENTITY releasedate "January 15, 2006">
<!ENTITY version "SVN-20060117">
<!ENTITY releasedate "January 17, 2006">
<!ENTITY milestone "6.2">
<!ENTITY generic-version "development"> <!-- Use "development", "testing", or "x.y[-pre{x}]" -->