Changeset 79524a0


Ignore:
Timestamp:
06/09/2020 11:10:16 PM (4 years ago)
Author:
Bruce Dubbs <bdubbs@…>
Branches:
10.0, 10.0-rc1, 10.1, 10.1-rc1, 11.0, 11.0-rc1, 11.0-rc2, 11.0-rc3, 11.1, 11.1-rc1, 11.2, 11.2-rc1, 11.3, 11.3-rc1, 12.0, 12.0-rc1, 12.1, 12.1-rc1, arm, bdubbs/gcc13, ml-11.0, multilib, renodr/libudev-from-systemd, s6-init, trunk, xry111/arm64, xry111/arm64-12.0, xry111/clfs-ng, xry111/lfs-next, xry111/loongarch, xry111/loongarch-12.0, xry111/loongarch-12.1, xry111/mips64el, xry111/pip3, xry111/rust-wip-20221008, xry111/update-glibc
Children:
ccff95b
Parents:
ee714d3
Message:

Text updates for cross2 Chapter 5

git-svn-id: http://svn.linuxfromscratch.org/LFS/branches/cross2@11914 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689

Files:
8 edited

Legend:

Unmodified
Added
Removed
  • chapter04/aboutsbus.xml

    ree714d3 r79524a0  
    4242    make" by either setting an environment variable or telling the
    4343    <command>make</command> program how many processors are available.  For
    44     instance, an Intel i5-6500 COU can support four simultaneous processes with:</para>
     44    instance, an Intel i5-6500 CPU can support four simultaneous processes with:</para>
    4545
    4646    <screen role="nodump"><userinput>export MAKEFLAGS='-j4'</userinput></screen>
  • chapter05/binutils-pass1.xml

    ree714d3 r79524a0  
    6464      the configuration, up to and including the first install. To achieve
    6565      this easily, wrap the commands in a <command>time</command>
    66       command like this: <userinput>time { ./configure ... &amp;&amp; ...
     66      command like this: <userinput>time { ./configure ... &amp;&amp; make
    6767      &amp;&amp; make install; }</userinput>.</para>
    6868    </note>
    69 <!--
    70     <note><para>The approximate build SBU values and required disk space
    71     in Chapter&nbsp;5 does not include test suite data.</para></note>
    72 -->
     69
    7370    <para>Now prepare Binutils for compilation:</para>
    7471
     
    8683        <listitem>
    8784          <para>This tells the configure script to prepare to install the
    88           Binutils programs in the <filename
     85          binutils programs in the <filename
    8986          class="directory">$LFS/tools</filename> directory.</para>
    9087        </listitem>
     
    9895        </listitem>
    9996      </varlistentry>
    100  <!--
    101       <varlistentry>
    102         <term><parameter>- -with-lib-path=/tools/lib</parameter></term>
    103         <listitem>
    104           <para>This specifies which library path the linker should be
    105           configured to use.</para>
    106         </listitem>
    107       </varlistentry>
    108   -->
     97
    10998      <varlistentry>
    11099        <term><envar>--target=$LFS_TGT</envar></term>
     
    113102          variable is slightly different than the value returned by the
    114103          <command>config.guess</command> script, this switch will tell the
    115           <command>configure</command> script to adjust Binutil's build system
     104          <command>configure</command> script to adjust binutil's build system
    116105          for building a cross linker.  </para>
    117106        </listitem>
  • chapter05/gcc-pass1.xml

    ree714d3 r79524a0  
    133133
    134134      <varlistentry>
     135        <term><parameter>--enable-initfini-array</parameter></term>
     136        <listitem>
     137          <para>This switch forces the use of some internal data structures
     138          that are needed but cannot be detected when building a cross
     139          compiler.</para>
     140        </listitem>
     141      </varlistentry>
     142
     143      <varlistentry>
    135144        <term><parameter>--disable-shared</parameter></term>
    136145        <listitem>
    137146          <para>This switch forces GCC to link its internal libraries
    138           statically. We need this because the shared libraries require glibc,
    139           which is not yet installed on the target system.</para>
     147          statically. We need this because the shared libraries require glibc,
     148          which is not yet installed on the target system.</para>
     149        </listitem>
     150      </varlistentry>
     151
     152      <varlistentry>
     153        <term><parameter>--disable-multilib</parameter></term>
     154        <listitem>
     155          <para>On x86_64, LFS does not support a multilib configuration.
     156          This switch is harmless for x86.</para>
    140157        </listitem>
    141158      </varlistentry>
     
    143160      <varlistentry>
    144161        <term><parameter>--disable-decimal-float, --disable-threads,
    145               --disable-libatomic, --disable-libgomp, <!--- -disable-libmpx,-->
     162              --disable-libatomic, --disable-libgomp,
    146163        --disable-libquadmath, --disable-libssp, --disable-libvtv,
    147164        --disable-libstdcxx</parameter></term>
    148165        <listitem>
    149166          <para>These switches disable support for the decimal floating point
    150           extension, threading, libatomic, libgomp, <!--libmpx, --> libquadmath, libssp,
     167          extension, threading, libatomic, libgomp, libquadmath, libssp,
    151168          libvtv, and the C++ standard library respectively. These features
    152169          will fail to compile when building a cross-compiler and are not
    153170          necessary for the task of cross-compiling the temporary libc.</para>
    154         </listitem>
    155       </varlistentry>
    156 
    157       <varlistentry>
    158         <term><parameter>--disable-multilib</parameter></term>
    159         <listitem>
    160           <para>On x86_64, LFS does not yet support a multilib configuration.
    161           This switch is harmless for x86.</para>
    162171        </listitem>
    163172      </varlistentry>
  • chapter05/generalinstructions.xml

    ree714d3 r79524a0  
    1919    <para>Several of the packages are patched before compilation, but only when
    2020    the patch is needed to circumvent a problem. A patch is often needed in
    21     both this and the next chapter, but sometimes in only one or the other.
     21    both this and the following chapters, but sometimes in only one location.
    2222    Therefore, do not be concerned if instructions for a downloaded patch seem
    2323    to be missing.  Warning messages about <emphasis>offset</emphasis> or
     
    9494            <listitem>
    9595              <para>Using the <command>tar</command> program, extract the package
    96               to be built.  In Chapter&nbsp;5, ensure you are the <emphasis>lfs</emphasis>
    97               user when extracting the package.</para>
     96              to be built.  In Chapters 5 and 6, ensure you are
     97              the <emphasis>lfs</emphasis> user when extracting the package.</para>
    9898            </listitem>
    9999            <listitem>
  • chapter05/glibc.xml

    ree714d3 r79524a0  
    212212    </caution>
    213213
    214     <note><para>Building packages in the next sections will serve as an
     214    <note><para>Building packages in the next chapter will serve as an
    215215    additional check that the toolchain has been built properly. If some
    216216    package, especially binutils-pass2 or gcc-pass2, fails to build, it is
     
    219219
    220220    <para>Now that our cross-toolchain is complete, finalize the installation
    221     of the limits.h header. For doing so, run an utility provided by the GCC
     221    of the limits.h header. For doing so, run a utility provided by the GCC
    222222    developers:</para>
    223223
  • chapter05/libstdc++.xml

    ree714d3 r79524a0  
    5454    </note>
    5555
    56     <para>Create a separate build directory for Libstdc++ and enter it:</para>
     56    <para>Create a separate build directory for libstdc++ and enter it:</para>
    5757
    5858<screen><userinput remap="pre">mkdir -v build
    5959cd       build</userinput></screen>
    6060
    61     <para>Prepare Libstdc++ for compilation:</para>
     61    <para>Prepare libstdc++ for compilation:</para>
    6262
    6363<screen><userinput remap="configure">../libstdc++-v3/configure           \
     
    7676        <term><parameter>--host=...</parameter></term>
    7777        <listitem>
    78           <para>Indicates to use the cross compiler we have just built
     78          <para>Specifies the use the cross compiler we have just built
    7979          instead of the one in <filename>/usr/bin</filename>.</para>
    8080        </listitem>
     
    9292        <term><parameter>--with-gxx-include-dir=/tools/$LFS_TGT/include/c++/&gcc-version;</parameter></term>
    9393        <listitem>
    94           <para>This is the location where the standard include files are
    95           searched by the C++ compiler. In a normal build, this information
    96           is automatically passed to the Libstdc++ <command>configure</command>
     94          <para>This is the location where the C++ compiler should search for the
     95          standard include files. In a normal build, this information
     96          is automatically passed to the libstdc++ <command>configure</command>
    9797          options from the top level directory. In our case, this information
    9898          must be explicitly given.</para>
  • chapter05/toolchaintechnotes.xml

    ree714d3 r79524a0  
    1717  to at any time during the process.</para>
    1818
    19   <para>The overall goal of <xref linkend="chapter-temporary-tools"/> is to
    20   produce a temporary area that contains a known-good set of tools that can be
    21   isolated from the host system. By using <command>chroot</command>, the
    22   commands in the remaining chapters will be contained within that environment,
    23   ensuring a clean, trouble-free build of the target LFS system. The build
    24   process has been designed to minimize the risks for new readers and to provide
    25   the most educational value at the same time.</para>
     19  <para>The overall goal of this chapter and <xref
     20  linkend="chapter-temporary-tools"/> is to produce a temporary area that
     21  contains a known-good set of tools that can be isolated from the host system.
     22  By using <command>chroot</command>, the commands in the remaining chapters
     23  will be contained within that environment, ensuring a clean, trouble-free
     24  build of the target LFS system. The build process has been designed to
     25  minimize the risks for new readers and to provide the most educational value
     26  at the same time.</para>
    2627
    2728  <para>The build process is based on the process of
     
    144145      remained. A simple way to determine your machine triplet is to run
    145146      the <command>config.guess</command>
    146       script that comes with the source for many packages. Unpack the Binutils
     147      script that comes with the source for many packages. Unpack the binutils
    147148      sources and run the script: <userinput>./config.guess</userinput> and note
    148149      the output. For example, for a 32-bit Intel processor the
     
    152153      <para>Also be aware of the name of the platform's dynamic linker, often
    153154      referred to as the dynamic loader (not to be confused with the standard
    154       linker <command>ld</command> that is part of Binutils). The dynamic linker
     155      linker <command>ld</command> that is part of binutils). The dynamic linker
    155156      provided by Glibc finds and loads the shared libraries needed by a
    156157      program, prepares the program to run, and then runs it. The name of the
     
    169170    is slightly adjusted by changing the &quot;vendor&quot; field in the
    170171    <envar>LFS_TGT</envar> variable. We also use the
    171     <parameter>--with-sysroot</parameter> when building the cross linker and
    172     cross compiler, to tell them where to find the needed host files. This
    173     ensures none of the other programs built in <xref
     172    <parameter>--with-sysroot</parameter> option when building the cross linker and
     173    cross compiler to tell them where to find the needed host files. This
     174    ensures that none of the other programs built in <xref
    174175    linkend="chapter-temporary-tools"/> can link to libraries on the build
    175176    machine. Only two stages are mandatory, and one more for tests:</para>
     
    216217    library to be fully functional! Furthermore, the standard library for
    217218    C++ (libstdc++) also needs being linked to glibc. The solution
    218     to this chicken and egg problem is to first build a degraded cc1+libgcc,
     219    to this chicken and egg problem is to first build a degraded cc1 based libgcc,
    219220    lacking some fuctionalities such as threads and exception handling, then
    220221    build glibc using this degraded compiler (glibc itself is not
     
    226227    this is the only compiler available for building the C/C++ libraries
    227228    during stage 2! Of course, the compiler built during stage 2, cc-lfs,
    228     would be able to build those libraries, but (i) the build system of
    229     gcc does not know that it is usable on pc, and (ii) using it on pc
     229    would be able to build those libraries, but (1) the build system of
     230    gcc does not know that it is usable on pc, and (2) using it on pc
    230231    would be at risk of linking to the pc libraries, since cc-lfs is a native
    231232    compiler. So we have to build libstdc++ later, in chroot.</para>
     
    307308    and generally does not rely on toolchain defaults.</para>
    308309
    309     <para>As said above, the standard C++ library is compiled next, followed
    310     by all the programs that need themselves to be built. The install step
    311     uses the <envar>DESTDIR</envar> variable to have the programs land into
    312     the LFS filesystem.</para>
    313 
    314     <para>Then the native lfs compiler is built. First Binutils Pass 2, with
    315     the same <envar>DESTDIR</envar> install as the other programs, then the
    316     second pass of GCC, omitting libstdc++ and other non-important libraries.
    317     Due to some weird logic in GCC's configure script,
    318     <envar>CC_FOR_TARGET</envar> ends up as <command>cc</command> when host
    319     is the same as target, but is different from build. This is why
     310    <para>As said above, the standard C++ library is compiled next, followed in
     311    Chapter 6 by all the programs that need themselves to be built. The install
     312    step of libstdc++ uses the <envar>DESTDIR</envar> variable to have the
     313    programs land into the LFS filesystem.</para>
     314
     315    <para>In Chapter 7 the native lfs compiler is built. First binutils-pass2,
     316    with the same <envar>DESTDIR</envar> install as the other programs is
     317    built, and then the second pass of GCC is constructed, omitting libstdc++
     318    and other non-important libraries.  Due to some weird logic in GCC's
     319    configure script, <envar>CC_FOR_TARGET</envar> ends up as
     320    <command>cc</command> when the host is the same as the target, but is
     321    different from the build system. This is why
    320322    <parameter>CC_FOR_TARGET=$LFS_TGT-gcc</parameter> is put explicitely into
    321323    the configure options.</para>
  • stylesheets/lfs-xsl/lfs.css

    ree714d3 r79524a0  
    343343}
    344344
    345 .table table {
     345.table table, .informaltable {
    346346  margin-left: auto;
    347347  margin-right: auto;
Note: See TracChangeset for help on using the changeset viewer.