Text changes:

Move about LFS to Chapter 2.
  Add intor to Chapter 4.
  Explain why specific symlinks are needed in Chapter 6.
  Remove obsolete reference to old glibc version.



git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@10575 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689
This commit is contained in:
Bruce Dubbs 2014-06-11 04:57:05 +00:00
parent 4ae2e7a4b2
commit 448e2261fb
10 changed files with 174 additions and 9 deletions

View File

@ -38,6 +38,16 @@
<listitem>
<para>2014-06-11</para>
<itemizedlist>
<listitem>
<para>[bdubbs] - Several text changes. Thanks to Chris
Staub for the patches. Fixes
<ulink url="&lfs-ticket-root;3600">#3600</ulink>,
<ulink url="&lfs-ticket-root;3601">#3601</ulink>,
<ulink url="&lfs-ticket-root;3602">#3602</ulink>,
<ulink url="&lfs-ticket-root;3603">#3603</ulink>, and
<ulink url="&lfs-ticket-root;3604">#3604</ulink>,
</para>
</listitem>
<listitem>
<para>[bdubbs] - Update to iproute2-3.15.0. Fixes
<ulink url="&lfs-ticket-root;3608">#3608</ulink>.</para>

View File

@ -11,7 +11,7 @@
<title>How to Build an LFS System</title>
<para>The LFS system will be built by using an already installed
Linux distribution (such as Debian, Mandriva, Red Hat, or SUSE). This
Linux distribution (such as Debian, OpenMandriva, Fedora, or openSUSE). This
existing Linux system (the host) will be used as a starting point to
provide necessary programs, including a compiler, linker, and shell,
to build the new system. Select the <quote>development</quote> option

50
chapter02/aboutlfs.xml Normal file
View File

@ -0,0 +1,50 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
<!ENTITY % general-entities SYSTEM "../general.ent">
%general-entities;
]>
<sect1 id="ch-partitioning-aboutlfs">
<?dbhtml filename="aboutlfs.html"?>
<title>Setting The $LFS Variable</title>
<para>Throughout this book, the environment variable <envar>LFS</envar> will
be used several times. You should ensure that this variable is always defined
throughout the LFS build process. It should be set to the name of the
directory where you will be building your LFS system - we will use
<filename class="directory">/mnt/lfs</filename> as an example, but the
directory choice is up to you. If you are building LFS on a separate
partition, this directory will be the mount point for the partition.
Choose a directory location and set the variable with the
following command:</para>
<screen role="nodump"><userinput>export LFS=<replaceable>/mnt/lfs</replaceable></userinput></screen>
<para>Having this variable set is beneficial in that commands such as
<command>mkdir -v $LFS/tools</command> can be typed literally. The shell
will automatically replace <quote>$LFS</quote> with
<quote>/mnt/lfs</quote> (or whatever the variable was set to) when it
processes the command line.</para>
<para>Do not forget to check that <envar>LFS</envar> is set whenever
you leave and reenter the current working environment (such as when doing a
<command>su</command> to <systemitem class="username">root</systemitem> or
another user). Check that the <envar>LFS</envar> variable is set up
properly with:</para>
<screen role="nodump"><userinput>echo $LFS</userinput></screen>
<para>Make sure the output shows the path to your LFS system's build
location, which is <filename class="directory">/mnt/lfs</filename> if the
provided example was followed. If the output is incorrect, use the command
given earlier on this page to set <envar>$LFS</envar> to the correct
directory name.</para>
<note><para>One way to ensure that the <envar>LFS</envar> variable is always
set is to edit the <filename>.bash_profile</filename> file in both your
personal home directory and in <filename>/root/.bash_profile</filename> and
enter the export command above. </para></note>
</sect1>

View File

@ -15,5 +15,6 @@
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="creatingpartition.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="creatingfilesystem.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="mounting.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="aboutlfs.xml"/>
</chapter>

View File

@ -11,7 +11,8 @@
<title>Final Preparations</title>
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="aboutlfs.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="introduction.xml"/>
<!--<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="aboutlfs.xml"/>-->
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="creatingtoolsdir.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="addinguser.xml"/>
<xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="settingenviron.xml"/>

View File

@ -0,0 +1,22 @@
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
"http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
<!ENTITY % general-entities SYSTEM "../general.ent">
%general-entities;
]>
<sect1 id="prepare-introduction">
<?dbhtml filename="introduction.html"?>
<title>Introduction</title>
<para>In this chapter, we will perform a few additional tasks to prepare
for building the temporary system. We will create a directory in
<filename class="directory">$LFS</filename> for the installation of the
temporary tools, add an unprivileged user to reduce risk,
and create an appropriate build environment for that user. We will also
explain the unit of time we use to measure how long LFS packages take to
build, or <quote>SBUs</quote>, and give some information about package
test suites.</para>
</sect1>

View File

@ -70,12 +70,9 @@ EOF</userinput></screen>
<para>The <envar>LC_ALL</envar> variable controls the localization of certain
programs, making their messages follow the conventions of a specified country.
If the host system uses a version of Glibc older than 2.2.4, having
<envar>LC_ALL</envar> set to something other than <quote>POSIX</quote> or
<quote>C</quote> (during this chapter) may cause issues if you exit the chroot
environment and wish to return later. Setting <envar>LC_ALL</envar> to
<quote>POSIX</quote> or <quote>C</quote> (the two are equivalent) ensures that
everything will work as expected in the chroot environment.</para>
Setting <envar>LC_ALL</envar> to <quote>POSIX</quote> or <quote>C</quote>
(the two are equivalent) ensures that everything will work as expected in
the chroot environment.</para>
<para>The <envar>LFS_TGT</envar> variable sets a non-default, but compatible machine
description for use when building our cross compiler and linker and when cross

View File

@ -18,6 +18,7 @@
<indexterm zone="ch-tools-util-linux">
<primary sortas="a-Util-linux">Util-linux</primary>
<secondary>tools</secondary>
</indexterm>
<sect2 role="package">

View File

@ -46,6 +46,89 @@ ln -sv /tools/lib/libstdc++.so{,.6} /usr/lib
sed 's/tools/usr/' /tools/lib/libstdc++.la > /usr/lib/libstdc++.la
ln -sv bash /bin/sh</userinput></screen>
<variablelist>
<title>The purpose of each link:</title>
<varlistentry>
<term><parameter><filename>/bin/bash</filename></parameter></term>
<listitem>
<para>Many <command>bash</command> scripts specify
<filename>/bin/bash</filename>.</para>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter><filename>/bin/cat</filename></parameter></term>
<listitem>
<para>This pathname is hard-coded into Glibc's configure script.</para>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter><filename>/bin/echo</filename></parameter></term>
<listitem>
<para>This is to satisfy one of the tests in Glibc's test suite, which
expects <filename>/bin/echo</filename>.</para>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter><filename>/bin/pwd</filename></parameter></term>
<listitem>
<para>Some <command>configure</command> scripts, particularly Glibc's,
have this pathname hard-coded.</para>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter><filename>/bin/stty</filename></parameter></term>
<listitem>
<para>This pathname is hard-coded into Expect, therefore it is needed
for Binutils and GCC test suites to pass.</para>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter><filename>/usr/bin/perl</filename></parameter></term>
<listitem>
<para>Many Perl scripts hard-code this path to the
<command>perl</command> program.</para>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter><filename>/usr/lib/libgcc_s.so{,.1}</filename></parameter></term>
<listitem>
<para>Glibc needs this for the pthreads library to work.</para>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter><filename>/usr/lib/libstdc++{,.6}</filename></parameter></term>
<listitem>
<para>This is needed by several tests in Glibc's test suite, as well as
for C++ support in GMP.</para>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter><filename>/usr/lib/libstdc++.la</filename></parameter></term>
<listitem>
<para>This prevents a <filename class="directory">/tools</filename>
reference that would otherwise be in
<filename>/usr/lib/libstdc++.la</filename> after GCC is installed.</para>
</listitem>
</varlistentry>
<varlistentry>
<term><parameter><filename>/bin/sh</filename></parameter></term>
<listitem>
<para>Many shell scripts hard-code <filename>/bin/sh</filename>.</para>
</listitem>
</varlistentry>
</variablelist>
<para>Historically, Linux maintains a list of the mounted file systems in the
file <filename>/etc/mtab</filename>. Modern kernels maintain this list
internally and exposes it to the user via the <filename

View File

@ -318,7 +318,7 @@
<!ENTITY iana-etc-size "201 KB">
<!ENTITY iana-etc-url "&anduin-sources;iana-etc/iana-etc-&iana-etc-version;.tar.bz2">
<!ENTITY iana-etc-md5 "3ba3afb1d1b261383d247f46cb135ee8">
<!ENTITY iana-etc-home "http://freshmeat.net/projects/iana-etc/">
<!ENTITY iana-etc-home "http://freecode.com/projects/iana-etc">
<!ENTITY iana-etc-ch6-du "2.2 MB">
<!ENTITY iana-etc-ch6-sbu "less than 0.1 SBU">