mirror of
https://git.linuxfromscratch.org/lfs.git
synced 2025-03-05 22:04:48 +00:00
Removed text in chapter 05 - first round.
git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@4431 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689
This commit is contained in:
parent
faf3398093
commit
6790655516
@ -7,37 +7,12 @@
|
||||
<title>Adjusting the toolchain</title>
|
||||
<?dbhtml filename="adjusting.html"?>
|
||||
|
||||
<para>Now that the temporary C libraries have been installed, all
|
||||
the 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 adjsted.</para>
|
||||
|
||||
<para> Some people would say that there is <emphasis><quote>black magic juju
|
||||
below this line</quote></emphasis>, but it is really very simple.</para>
|
||||
|
||||
<para>First, the linker, adjusted at the end of the first pass of Binutils, is
|
||||
installed by running the following command from within
|
||||
<para>Run 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 <emphasis>only</emphasis>
|
||||
against the libraries in <filename class="directory">/tools/lib</filename>.</para>
|
||||
|
||||
<note><para>If you missed the earlier warning to retain the Binutils
|
||||
source and build directories from the first pass, dont worry - all is not lost.
|
||||
Just ignore the above command. This results in a small chance of the subsequent
|
||||
testing programs linking against libraries on the host. This is not ideal, but
|
||||
it's not a major problem. The situation is corrected when the second pass of
|
||||
Binutils is installed later on.</para></note>
|
||||
|
||||
<para>Now that the adjusted linker is installed, the Binutils build and source
|
||||
directories should be <emphasis>removed</emphasis>.</para>
|
||||
|
||||
<para>The next task is to amend our GCC specs file so that it points
|
||||
to the new dynamic linker. A simple sed script will accomplish this:</para>
|
||||
|
||||
<!-- Ampersands are needed to allow cut and paste -->
|
||||
<para>Amend the GCC specs file:</para>
|
||||
|
||||
<screen><userinput>SPECFILE=`gcc --print-file specs` &&
|
||||
sed 's@ /lib/ld-linux.so.2@ /tools/lib/ld-linux.so.2@g' \
|
||||
@ -45,65 +20,17 @@ sed 's@ /lib/ld-linux.so.2@ /tools/lib/ld-linux.so.2@g' \
|
||||
mv -f tempspecfile $SPECFILE &&
|
||||
unset SPECFILE</userinput></screen>
|
||||
|
||||
<para>It is recommended that the above command be cut-and-pasted in order to
|
||||
ensure correctness - Alternatively, the specs file can be edited by hand. This
|
||||
is done simply 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>
|
||||
|
||||
<important><para>If you are working on a platform where the name of the dynamic
|
||||
linker is something other than <filename>ld-linux.so.2</filename>, you
|
||||
<emphasis>must</emphasis> replace <filename>ld-linux.so.2</filename> with the
|
||||
name of your platform's dynamic linker in the above commands. Refer back to
|
||||
<xref linkend="ch-tools-toolchaintechnotes"/> if necessary.</para></important>
|
||||
|
||||
<para>Lastly, there is a possibility that some include files from the host
|
||||
system have found their way into GCC's private include dir. This can happen
|
||||
as a result of of GCC's <quote>fixincludes</quote> process which runs as part
|
||||
of the GCC build. We'll explain more about this further on in this chapter.
|
||||
Run the following commands to eliminate this possibility:</para>
|
||||
|
||||
<screen><userinput>rm -f /tools/lib/gcc/*/*/include/{pthread.h,bits/sigthread.h}</userinput></screen>
|
||||
|
||||
|
||||
<caution><para>It is imperative at this point to stop and ensure that the basic
|
||||
functions (compiling and linking) of the new toolchain are working as expected.
|
||||
To perform a simple sanity check, run the following commands:</para>
|
||||
|
||||
<screen><userinput>echo 'main(){}' > 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>The output of the last command will be of the form:</para>
|
||||
|
||||
<blockquote><screen><computeroutput>[Requesting program interpreter: /tools/lib/ld-linux.so.2]</computeroutput></screen></blockquote>
|
||||
|
||||
<para>Note especially that <filename class="directory">/tools/lib</filename>
|
||||
appears as the prefix of our dynamic linker.</para>
|
||||
|
||||
<para>If the output is not
|
||||
as shown above, or there was no output at all, then something is seriously
|
||||
wrong. You will need to investigate and retrace your steps to find out where the
|
||||
problem is and correct it. There is no point in continuing until this is done.
|
||||
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"/> and install the symlink. Second, ensure your PATH
|
||||
is correct. You can check this by running <userinput>echo $PATH</userinput> and
|
||||
verifying that <filename class="directory">/tools/bin</filename> is at the head
|
||||
of the list. If the PATH is wrong it could mean you're not logged in as user
|
||||
<emphasis>lfs</emphasis> or something went wrong back in
|
||||
<xref linkend="ch-tools-settingenviron"/>. Third, something may have gone wrong with
|
||||
the specs file amendment above. In this case redo the specs file amendment
|
||||
being careful to cut-and-paste the commands.</para>
|
||||
|
||||
<para>Once you are satisfied that all is well, clean up the test files:</para>
|
||||
<screen><computeroutput>[Requesting program interpreter: /tools/lib/ld-linux.so.2]</computeroutput></screen>
|
||||
|
||||
<screen><userinput>rm dummy.c a.out</userinput></screen>
|
||||
</caution>
|
||||
|
||||
|
||||
</sect1>
|
||||
|
@ -12,7 +12,6 @@
|
||||
<secondary>tools</secondary></indexterm>
|
||||
|
||||
<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])"/>
|
||||
|
||||
<segmentedlist>
|
||||
<segtitle>&buildtime;</segtitle>
|
||||
@ -20,16 +19,11 @@
|
||||
<seglistitem><seg>1.2 SBU</seg><seg>27 MB</seg></seglistitem>
|
||||
</segmentedlist>
|
||||
|
||||
<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>Bash has a problem when compiled against newer versions of glibc, causing
|
||||
it to hang inappropriately. This patch fixes the problem:</para>
|
||||
|
||||
<screen><userinput>patch -Np1 -i ../bash-&bash-version;-avoid_WCONTINUED-1.patch</userinput></screen>
|
||||
|
||||
<para>Prepare Bash for compilation:</para>
|
||||
@ -40,22 +34,15 @@ it to hang inappropriately. This patch fixes the problem:</para>
|
||||
|
||||
<screen><userinput>make</userinput></screen>
|
||||
|
||||
<para>(If you want to test the results, then issue:
|
||||
<userinput>make tests</userinput>.)</para>
|
||||
<para>To test the results, issue:
|
||||
<userinput>make test</userinput>.</para>
|
||||
|
||||
<para>Then install it and its documentation:</para>
|
||||
<para>Then install it :</para>
|
||||
|
||||
<screen><userinput>make install</userinput></screen>
|
||||
|
||||
<para>And make a link for the programs that use <command>sh</command>
|
||||
for a shell:</para>
|
||||
|
||||
<screen><userinput>ln -s bash /tools/bin/sh</userinput></screen>
|
||||
|
||||
</sect2>
|
||||
|
||||
<sect2 role="content"><title/>
|
||||
<para>The details on this package are found in <xref linkend="contents-bash"/>.</para>
|
||||
</sect2>
|
||||
|
||||
</sect1>
|
||||
|
@ -12,7 +12,6 @@
|
||||
<secondary>tools, pass 1</secondary></indexterm>
|
||||
|
||||
<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])"/>
|
||||
|
||||
<segmentedlist>
|
||||
<segtitle>&buildtime;</segtitle>
|
||||
@ -20,93 +19,34 @@
|
||||
<seglistitem><seg>1.0 SBU</seg><seg>194 MB</seg></seglistitem>
|
||||
</segmentedlist>
|
||||
|
||||
<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>Installation of Binutils</title>
|
||||
|
||||
<para>It is important that Binutils be the first package to get 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>This package is known to behave badly when you change its default
|
||||
optimization flags (including the <parameter>-march</parameter> and
|
||||
<parameter>-mcpu</parameter> options). Therefore, if you have defined any
|
||||
environment variables that override default optimizations, such as CFLAGS and
|
||||
CXXFLAGS, we recommend un-setting them when building Binutils.</para>
|
||||
|
||||
<para>The current version of Binutils in use has a bug that causes strip to
|
||||
remove necessary information from certain library files. This patch fixes
|
||||
the problem:</para>
|
||||
|
||||
<screen><userinput>patch -Np1 -i ../binutils-&binutils-version;-fix_strip-1.patch</userinput></screen>
|
||||
|
||||
<para>The Binutils documentation recommends building Binutils outside of the
|
||||
source directory in a dedicated build directory:</para>
|
||||
|
||||
<screen><userinput>mkdir ../binutils-build
|
||||
cd ../binutils-build</userinput></screen>
|
||||
|
||||
<note><para>If you want the SBU values listed in the rest of the book to be of
|
||||
any use, you will have to measure the time it takes to build this package --
|
||||
from the configuration up to and including the first install. To achieve this
|
||||
easily, you could wrap the four commands in a <command>time</command> command
|
||||
like this: <userinput>time { ./configure ... && ... && ...
|
||||
<note><para>If you want the SBU values you could wrap the four commands in a
|
||||
<command>time</command> command like this:
|
||||
<userinput>time { ./configure ... && ... && ...
|
||||
&& make install; }</userinput>.</para></note>
|
||||
|
||||
<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>
|
||||
<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 (a word often shortened to
|
||||
i18n). We don't need this for our static programs and <emphasis>nls</emphasis>
|
||||
often causes problems when linking statically.</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 the subdirectories to be configured immediately.
|
||||
A statically linked build will fail without it. We therefore 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 the 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>
|
||||
|
||||
<para>Compilation is complete. Normally 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. And there would be little point in running the tests anyhow,
|
||||
since the programs from this first pass will soon be replaced by those from the
|
||||
second.</para>
|
||||
|
||||
<para>Now install the package:</para>
|
||||
|
||||
<screen><userinput>make install</userinput></screen>
|
||||
@ -116,37 +56,10 @@ second.</para>
|
||||
<screen><userinput>make -C ld clean
|
||||
make -C ld LDFLAGS="-all-static" LIB_PATH=/tools/lib</userinput></screen>
|
||||
|
||||
<para>The meaning of the make parameters:</para>
|
||||
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<term><parameter>-C ld clean</parameter></term>
|
||||
<listitem><para>This tells the make program to remove all the compiled files
|
||||
in the <filename class="directory">ld</filename> subdirectory.</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><parameter>-C ld LDFLAGS="-all-static"
|
||||
LIB_PATH=/tools/lib</parameter></term>
|
||||
<listitem><para>This option rebuilds everything in the
|
||||
<filename class="directory">ld</filename> subdirectory. Specifying the LIB_PATH
|
||||
makefile variable on the command line allows us to override the default value
|
||||
and have it point to our temporary tools location. The value of this variable
|
||||
specifies the linker's default library search path. You will see how this
|
||||
preparation is used later on in the chapter.</para></listitem>
|
||||
</varlistentry>
|
||||
</variablelist>
|
||||
|
||||
|
||||
<warning><para><emphasis>Do not yet remove</emphasis> the Binutils build and
|
||||
source directories. You will need them again in their current state a bit
|
||||
further on in this chapter.</para></warning>
|
||||
|
||||
|
||||
</sect2>
|
||||
|
||||
<sect2 role="content"><title/>
|
||||
<para>The details on this package are found in <xref linkend="contents-binutils"/>.</para>
|
||||
</sect2>
|
||||
|
||||
</sect1>
|
||||
|
@ -40,29 +40,10 @@ cd ../binutils-build</userinput></screen>
|
||||
<screen><userinput>../binutils-&binutils-version;/configure --prefix=/tools \
|
||||
--enable-shared --with-lib-path=/tools/lib</userinput></screen>
|
||||
|
||||
<para>The meaning of the new configure option:</para>
|
||||
|
||||
<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 <parameter>/tools/lib</parameter>
|
||||
to be passed to the linker. This prevents the linker from searching through library
|
||||
directories on the host.</para></listitem>
|
||||
</varlistentry>
|
||||
</variablelist>
|
||||
|
||||
<para>Before starting to build Binutils, remember to unset any environment
|
||||
variables that override the default optimization flags.</para>
|
||||
|
||||
<para>Compile the package:</para>
|
||||
|
||||
<screen><userinput>make</userinput></screen>
|
||||
|
||||
<para>Compilation is now complete. As discussed earlier, running the test suite
|
||||
isn't mandatory for the temporary tools here in this chapter. If you do want to
|
||||
run the Binutils test suite though, the following command will do so:</para>
|
||||
|
||||
<screen><userinput>make -k check</userinput></screen>
|
||||
|
||||
<para>Except for a few known failures, the binutils tests should all pass. The
|
||||
@ -72,17 +53,6 @@ exceptions to this rule are as follows:</para>
|
||||
* 1 FAIL for selective4
|
||||
* 1 FAIL for selective5</computeroutput></screen>
|
||||
|
||||
<!--
|
||||
|
||||
<para>There should be no unexpected failures here, expected failures are fine.
|
||||
Unfortunately, there is no easy way to view the test results summary like there
|
||||
was for the GCC package. However, if a failure occurs here, it should be easy
|
||||
to spot. The output shown will contain something like:</para>
|
||||
|
||||
<blockquote><screen><computeroutput>make[1]: *** [check-binutils] Error 2</computeroutput></screen></blockquote>
|
||||
|
||||
-->
|
||||
|
||||
<para>And install the package:</para>
|
||||
|
||||
<screen><userinput>make install</userinput></screen>
|
||||
@ -98,11 +68,6 @@ make -C ld LIB_PATH=/usr/lib:/lib</userinput></screen>
|
||||
build directories. You will need these directories again in the next chapter
|
||||
in the state they are in now.</para></warning>
|
||||
|
||||
|
||||
</sect2>
|
||||
|
||||
<sect2 role="content"><title/>
|
||||
<para>The details on this package are found in <xref linkend="contents-binutils"/>.</para>
|
||||
</sect2>
|
||||
|
||||
</sect1>
|
||||
|
@ -12,7 +12,6 @@
|
||||
<secondary>tools</secondary></indexterm>
|
||||
|
||||
<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])"/>
|
||||
|
||||
<segmentedlist>
|
||||
<segtitle>&buildtime;</segtitle>
|
||||
@ -20,8 +19,6 @@
|
||||
<seglistitem><seg>0.6 SBU</seg><seg>10.6 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">
|
||||
@ -44,8 +41,4 @@
|
||||
|
||||
</sect2>
|
||||
|
||||
<sect2 role="content"><title/>
|
||||
<para>The details on this package are found in <xref linkend="contents-bison"/>.</para>
|
||||
</sect2>
|
||||
|
||||
</sect1>
|
||||
|
@ -12,7 +12,6 @@
|
||||
<secondary>tools</secondary></indexterm>
|
||||
|
||||
<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])"/>
|
||||
|
||||
<segmentedlist>
|
||||
<segtitle>&buildtime;</segtitle>
|
||||
@ -20,8 +19,6 @@
|
||||
<seglistitem><seg>0.1 SBU</seg><seg>2.5 MB</seg></seglistitem>
|
||||
</segmentedlist>
|
||||
|
||||
<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">
|
||||
@ -38,8 +35,4 @@ script. Compile it with a straightforward:</para>
|
||||
|
||||
</sect2>
|
||||
|
||||
<sect2 role="content"><title/>
|
||||
<para>The details on this package are found in <xref linkend="contents-bzip2"/>.</para>
|
||||
</sect2>
|
||||
|
||||
</sect1>
|
||||
|
@ -12,7 +12,6 @@
|
||||
<secondary>tools</secondary></indexterm>
|
||||
|
||||
<sect2 role="package"><title/>
|
||||
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/coreutils.xml" xpointer="xpointer(/sect1/sect2[1]/para[1])"/>
|
||||
|
||||
<segmentedlist>
|
||||
<segtitle>&buildtime;</segtitle>
|
||||
@ -20,8 +19,6 @@
|
||||
<seglistitem><seg>0.9 SBU</seg><seg>69 MB</seg></seglistitem>
|
||||
</segmentedlist>
|
||||
|
||||
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/coreutils.xml" xpointer="xpointer(/sect1/sect2[1]/segmentedlist[2])"/>
|
||||
|
||||
</sect2>
|
||||
|
||||
<sect2 role="installation">
|
||||
@ -31,30 +28,12 @@
|
||||
|
||||
<screen><userinput>DEFAULT_POSIX2_VERSION=199209 ./configure --prefix=/tools</userinput></screen>
|
||||
|
||||
<para>This package has an issue when compiled against versions of Glibc
|
||||
later than 2.3.2. Some of the Coreutils utilities (such as
|
||||
<command>head</command>, <command>tail</command> and <command>sort</command>)
|
||||
will reject their traditional syntax, a syntax that has been in use for
|
||||
approximately 30 years. This old syntax is so pervasive that compatibility
|
||||
should be preserved until the many places where it is used can be
|
||||
updated. Backwards compatibility is achieved by setting the
|
||||
DEFAULT_POSIX2_VERSION environment variable to <quote>199209</quote> in the above
|
||||
command. If you don't want coreutils to be backwards compatible
|
||||
with the traditional syntax, then simply omit setting the DEFAULT_POSIX2_VERSION
|
||||
environment variable. Realise though, that doing so will mean you'll have
|
||||
to deal with the consequences yourself: patch the many packages that still use
|
||||
the old syntax. We therefore recommend using the instructions exactly as given
|
||||
above.</para>
|
||||
|
||||
<para>Compile the package:</para>
|
||||
|
||||
<screen><userinput>make</userinput></screen>
|
||||
|
||||
<para>(If you want to test the results, then issue:
|
||||
<userinput>make RUN_EXPENSIVE_TESTS=yes check</userinput>. The
|
||||
<parameter>RUN_EXPENSIVE_TESTS=yes</parameter> parameter tells the test suite to
|
||||
run several additional tests that are considered relatively expensive on some
|
||||
platforms but generally are not a problem on Linux.)</para>
|
||||
<para>To test the result, issue:
|
||||
<userinput>make RUN_EXPENSIVE_TESTS=yes check</userinput></para>
|
||||
|
||||
<para>And install the package:</para>
|
||||
|
||||
@ -62,8 +41,4 @@ platforms but generally are not a problem on Linux.)</para>
|
||||
|
||||
</sect2>
|
||||
|
||||
<sect2 role="content"><title/>
|
||||
<para>The details on this package are found in <xref linkend="contents-coreutils"/>.</para>
|
||||
</sect2>
|
||||
|
||||
</sect1>
|
||||
|
@ -10,7 +10,6 @@
|
||||
<indexterm zone="ch-tools-dejagnu"><primary sortas="a-DejaGNU">DejaGNU</primary></indexterm>
|
||||
|
||||
<sect2 role="package"><title/>
|
||||
<para>The DejaGNU package contains a framework for testing other programs.</para>
|
||||
|
||||
<segmentedlist>
|
||||
<segtitle>&buildtime;</segtitle>
|
||||
@ -18,11 +17,6 @@
|
||||
<seglistitem><seg>0.1 SBU</seg><seg>8.6 MB</seg></seglistitem>
|
||||
</segmentedlist>
|
||||
|
||||
<segmentedlist>
|
||||
<segtitle>DejaGNU installation depends on</segtitle>
|
||||
<seglistitem><seg>Bash, Binutils, Coreutils, Diffutils,
|
||||
GCC, Glibc, Grep, Make, Sed</seg></seglistitem>
|
||||
</segmentedlist>
|
||||
</sect2>
|
||||
|
||||
<sect2 role="installation">
|
||||
@ -38,25 +32,9 @@ GCC, Glibc, Grep, Make, Sed</seg></seglistitem>
|
||||
|
||||
</sect2>
|
||||
|
||||
|
||||
<sect2 id="contents-dejagnu" role="content"><title>Contents of DejaGNU</title>
|
||||
|
||||
<segmentedlist>
|
||||
<segtitle>Installed program</segtitle>
|
||||
<seglistitem><seg>runtest</seg></seglistitem>
|
||||
</segmentedlist>
|
||||
|
||||
<variablelist><title>Short description</title>
|
||||
|
||||
<varlistentry id="runtest">
|
||||
<term><command>runtest</command></term>
|
||||
<listitem>
|
||||
<indexterm zone="ch-tools-dejagnu runtest"><primary sortas="b-runtest">runtest</primary></indexterm>
|
||||
<para>is the wrapper script that finds the proper
|
||||
<command>expect</command> shell and then runs DejaGNU.</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
</variablelist>
|
||||
<para>See testing</para>
|
||||
|
||||
</sect2>
|
||||
|
||||
|
@ -12,7 +12,6 @@
|
||||
<secondary>tools</secondary></indexterm>
|
||||
|
||||
<sect2 role="package"><title/>
|
||||
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/diffutils.xml" xpointer="xpointer(/sect1/sect2[1]/para[1])"/>
|
||||
|
||||
<segmentedlist>
|
||||
<segtitle>&buildtime;</segtitle>
|
||||
@ -20,8 +19,6 @@
|
||||
<seglistitem><seg>0.1 SBU</seg><seg>7.5 MB</seg></seglistitem>
|
||||
</segmentedlist>
|
||||
|
||||
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/diffutils.xml" xpointer="xpointer(/sect1/sect2[1]/segmentedlist[2])"/>
|
||||
|
||||
</sect2>
|
||||
|
||||
<sect2 role="installation">
|
||||
@ -41,8 +38,4 @@
|
||||
|
||||
</sect2>
|
||||
|
||||
<sect2 role="content"><title/>
|
||||
<para>The details on this package are found in <xref linkend="contents-diffutils"/>.</para>
|
||||
</sect2>
|
||||
|
||||
</sect1>
|
||||
|
@ -10,8 +10,6 @@
|
||||
<indexterm zone="ch-tools-expect"><primary sortas="a-Expect">Expect</primary></indexterm>
|
||||
|
||||
<sect2 role="package"><title/>
|
||||
<para>The Expect package contains a program for carrying out scripted dialogues
|
||||
with other interactive programs.</para>
|
||||
|
||||
<segmentedlist>
|
||||
<segtitle>&buildtime;</segtitle>
|
||||
@ -19,102 +17,35 @@ with other interactive programs.</para>
|
||||
<seglistitem><seg>0.1 SBU</seg><seg>3.9 MB</seg></seglistitem>
|
||||
</segmentedlist>
|
||||
|
||||
<segmentedlist>
|
||||
<segtitle>Expect installation depends on</segtitle>
|
||||
<seglistitem><seg>Bash, Binutils, Coreutils, Diffutils,
|
||||
GCC, Glibc, Grep, Make, Sed, Tcl</seg></seglistitem>
|
||||
</segmentedlist>
|
||||
</sect2>
|
||||
|
||||
<sect2 role="installation">
|
||||
<title>Installation of Expect</title>
|
||||
|
||||
<para>First fix a bug that can result in bogus failures during the GCC test
|
||||
suite run:</para>
|
||||
|
||||
<screen><userinput>patch -Np1 -i ../expect-&expect-version;-spawn-1.patch</userinput></screen>
|
||||
|
||||
<para>Now prepare Expect for compilation:</para>
|
||||
|
||||
<screen><userinput>./configure --prefix=/tools --with-tcl=/tools/lib --with-x=no</userinput></screen>
|
||||
|
||||
<para>The meaning of the configure options:</para>
|
||||
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<term><parameter>--with-tcl=/tools/lib</parameter></term>
|
||||
<listitem><para>This ensures that
|
||||
the configure script finds the Tcl installation in our temporary tools location.
|
||||
We don't want it to find an existing one that may possibly reside on the host
|
||||
system.</para></listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry>
|
||||
<term><parameter>--with-x=no</parameter></term>
|
||||
<listitem><para>This tells the configure
|
||||
script not to search for Tk (the Tcl GUI component) or the X Window System
|
||||
libraries, both of which may possibly reside on the host system.</para></listitem>
|
||||
</varlistentry>
|
||||
</variablelist>
|
||||
|
||||
<para>Build the package:</para>
|
||||
|
||||
<screen><userinput>make</userinput></screen>
|
||||
|
||||
<para>(If you want to test the results, then issue:
|
||||
<userinput>make test</userinput>. However, the Expect test suite is known to
|
||||
experience failures under certain host conditions that are not within our
|
||||
control. Therefore, test suite failures here are not surprising, and are not
|
||||
considered critical.)</para>
|
||||
<para>To test the results, issue:
|
||||
<userinput>make test</userinput></para>
|
||||
|
||||
<para>And install it:</para>
|
||||
|
||||
<screen><userinput>make SCRIPTS="" install</userinput></screen>
|
||||
|
||||
<para>The meaning of the make parameter:</para>
|
||||
|
||||
<variablelist>
|
||||
<varlistentry>
|
||||
<term><parameter>SCRIPTS=""</parameter></term>
|
||||
<listitem><para>This prevents installation
|
||||
of the supplementary expect scripts which are not needed.</para></listitem>
|
||||
</varlistentry>
|
||||
</variablelist>
|
||||
|
||||
<para>You can now remove the source directories of both Tcl and Expect.</para>
|
||||
|
||||
</sect2>
|
||||
|
||||
|
||||
<sect2 id="contents-expect" role="content"><title>Contents of Expect</title>
|
||||
|
||||
<segmentedlist>
|
||||
<segtitle>Installed program</segtitle>
|
||||
<segtitle>Installed library</segtitle>
|
||||
<seglistitem><seg>expect</seg><seg>libexpect-5.42.a</seg></seglistitem>
|
||||
</segmentedlist>
|
||||
|
||||
<variablelist><title>Short description</title>
|
||||
|
||||
<varlistentry id="expect">
|
||||
<term><command>expect</command></term>
|
||||
<listitem>
|
||||
<indexterm zone="ch-tools-expect expect"><primary sortas="b-expect">expect</primary></indexterm>
|
||||
<para><quote>talks</quote> to other interactive
|
||||
programs according to a script.</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry id="libexpect">
|
||||
<term><filename class="libraryfile">libexpect-5.42.a</filename></term>
|
||||
<listitem>
|
||||
<para>contains functions that allow Expect to be used as a Tcl extension or to
|
||||
be used directly from C or C++ (without Tcl)."</para>
|
||||
<indexterm zone="ch-tools-expect libexpect"><primary
|
||||
sortas="c-libexpect-5.42">libexpect-5.42</primary></indexterm>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
</variablelist>
|
||||
<para>See testing</para>
|
||||
|
||||
</sect2>
|
||||
|
||||
|
@ -12,7 +12,6 @@
|
||||
<secondary>tools</secondary></indexterm>
|
||||
|
||||
<sect2 role="package"><title/>
|
||||
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/findutils.xml" xpointer="xpointer(/sect1/sect2[1]/para[1])"/>
|
||||
|
||||
<segmentedlist>
|
||||
<segtitle>&buildtime;</segtitle>
|
||||
@ -20,8 +19,6 @@
|
||||
<seglistitem><seg>0.2 SBU</seg><seg>7.6 MB</seg></seglistitem>
|
||||
</segmentedlist>
|
||||
|
||||
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/findutils.xml" xpointer="xpointer(/sect1/sect2[1]/segmentedlist[2])"/>
|
||||
|
||||
</sect2>
|
||||
|
||||
<sect2 role="installation">
|
||||
@ -35,8 +32,8 @@
|
||||
|
||||
<screen><userinput>make</userinput></screen>
|
||||
|
||||
<para>(If you want to test the results, then issue:
|
||||
<userinput>make check</userinput>.)</para>
|
||||
<para>To test the results, issue:
|
||||
<userinput>make check</userinput></para>
|
||||
|
||||
<para>And install the package:</para>
|
||||
|
||||
@ -44,8 +41,4 @@
|
||||
|
||||
</sect2>
|
||||
|
||||
<sect2 role="content"><title/>
|
||||
<para>The details on this package are found in <xref linkend="contents-findutils"/>.</para>
|
||||
</sect2>
|
||||
|
||||
</sect1>
|
||||
|
@ -12,7 +12,6 @@
|
||||
<secondary>tools</secondary></indexterm>
|
||||
|
||||
<sect2 role="package"><title/>
|
||||
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/flex.xml" xpointer="xpointer(/sect1/sect2[1]/para[1])"/>
|
||||
|
||||
<segmentedlist>
|
||||
<segtitle>&buildtime;</segtitle>
|
||||
@ -20,22 +19,13 @@
|
||||
<seglistitem><seg>0.6 SBU</seg><seg>10.6 MB</seg></seglistitem>
|
||||
</segmentedlist>
|
||||
|
||||
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/flex.xml" xpointer="xpointer(/sect1/sect2[1]/segmentedlist[2])"/>
|
||||
|
||||
</sect2>
|
||||
|
||||
<sect2 role="installation">
|
||||
<title>Installation of Flex</title>
|
||||
|
||||
<para>Flex contains several known bugs. Fix these with the following patch:</para>
|
||||
|
||||
<screen><userinput>patch -Np1 -i ../flex-&flex-version;-debian_fixes-2.patch</userinput></screen>
|
||||
|
||||
<para>The GNU autotools detects that the Flex source code has been modified by
|
||||
the previous patch, and tries to update the manual page accordingly, but this
|
||||
breaks on many systems, and the default page is fine, so make sure it doesn't
|
||||
get regenerated:</para>
|
||||
|
||||
<screen><userinput>touch doc/flex.1</userinput></screen>
|
||||
|
||||
<para>Now prepare Flex for compilation:</para>
|
||||
@ -55,8 +45,4 @@ get regenerated:</para>
|
||||
|
||||
</sect2>
|
||||
|
||||
<sect2 role="content"><title/>
|
||||
<para>The details on this package are found in <xref linkend="contents-flex"/>.</para>
|
||||
</sect2>
|
||||
|
||||
</sect1>
|
||||
|
@ -12,7 +12,6 @@
|
||||
<secondary>tools</secondary></indexterm>
|
||||
|
||||
<sect2 role="package"><title/>
|
||||
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/gawk.xml" xpointer="xpointer(/sect1/sect2[1]/para[1])"/>
|
||||
|
||||
<segmentedlist>
|
||||
<segtitle>&buildtime;</segtitle>
|
||||
@ -20,8 +19,6 @@
|
||||
<seglistitem><seg>0.2 SBU</seg><seg>17 MB</seg></seglistitem>
|
||||
</segmentedlist>
|
||||
|
||||
<xi:include xmlns:xi="http://www.w3.org/2003/XInclude" href="../chapter06/gawk.xml" xpointer="xpointer(/sect1/sect2[1]/segmentedlist[2])"/>
|
||||
|
||||
</sect2>
|
||||
|
||||
<sect2 role="installation">
|
||||
@ -35,8 +32,8 @@
|
||||
|
||||
<screen><userinput>make</userinput></screen>
|
||||
|
||||
<para>(If you want to test the results, then issue:
|
||||
<userinput>make check</userinput>.)</para>
|
||||
<para>To test the results, issue:
|
||||
<userinput>make check</userinput></para>
|
||||
|
||||
<para>And install it:</para>
|
||||
|
||||
@ -44,8 +41,4 @@
|
||||
|
||||
</sect2>
|
||||
|
||||
<sect2 role="content"><title/>
|
||||
<para>The details on this package are found in <xref linkend="contents-gawk"/>.</para>
|
||||
</sect2>
|
||||
|
||||
</sect1>
|
||||
|
Loading…
Reference in New Issue
Block a user