Tweaked English idiom / clarified directiions in chapters 4.3 and 4.4.

This commit is contained in:
David Bryant 2022-09-27 13:07:58 -05:00
parent 2646c571d7
commit ec7b046623
2 changed files with 19 additions and 18 deletions

View File

@ -14,9 +14,9 @@
making a single mistake can damage or destroy a system. Therefore,
the packages in the next two chapters are built as an unprivileged user.
You could use your own user name, but to make it easier to set up a clean
working environment, create a new user called <systemitem
working environment, we will create a new user called <systemitem
class="username">lfs</systemitem> as a member of a new group (also named
<systemitem class="groupname">lfs</systemitem>) and use this user during
<systemitem class="groupname">lfs</systemitem>) and log in as this user during
the installation process. As <systemitem class="username">root</systemitem>,
issue the following commands to add the new user:</para>
@ -24,7 +24,7 @@
useradd -s /bin/bash -g lfs -m -k /dev/null lfs</userinput></screen>
<variablelist>
<title>The meaning of the command line options:</title>
<title>This is what the command line options mean:</title>
<varlistentry>
<term><parameter>-s /bin/bash</parameter></term>
@ -54,7 +54,7 @@ useradd -s /bin/bash -g lfs -m -k /dev/null lfs</userinput></screen>
<term><parameter>-k /dev/null</parameter></term>
<listitem>
<para>This parameter prevents possible copying of files from a skeleton
directory (default is <filename class="directory">/etc/skel</filename>)
directory (the default is <filename class="directory">/etc/skel</filename>)
by changing the input location to the special null device.</para>
</listitem>
</varlistentry>
@ -68,7 +68,7 @@ useradd -s /bin/bash -g lfs -m -k /dev/null lfs</userinput></screen>
</variablelist>
<para>To log in as <systemitem class="username">lfs</systemitem> (as opposed
<para>To enable logging in as <systemitem class="username">lfs</systemitem> (as opposed
to switching to user <systemitem class="username">lfs</systemitem> when logged
in as <systemitem class="username">root</systemitem>, which does not require
the <systemitem class="username">lfs</systemitem> user to have a password),
@ -77,16 +77,16 @@ useradd -s /bin/bash -g lfs -m -k /dev/null lfs</userinput></screen>
<screen role="nodump"><userinput>passwd lfs</userinput></screen>
<para>Grant <systemitem class="username">lfs</systemitem> full access to
all directories under <filename class="directory">$LFS</filename> by making
<systemitem class="username">lfs</systemitem> the directory owner:</para>
all the directories under <filename class="directory">$LFS</filename> by making
<systemitem class="username">lfs</systemitem> the owner:</para>
<screen><userinput>chown -v lfs $LFS/{usr{,/*},lib,var,etc,bin,sbin,tools}
case $(uname -m) in
x86_64) chown -v lfs $LFS/lib64 ;;
esac</userinput></screen>
<note><para>In some host systems, the following command does not complete
properly and suspends the login to the &lfs-user; user to the background.
<note><para>In some host systems, the following <command>su</command> command does not complete
properly and suspends the login for the &lfs-user; user to the background.
If the prompt "lfs:~$" does not appear immediately, entering the
<command>fg</command> command will fix the issue.</para></note>
@ -98,7 +98,7 @@ esac</userinput></screen>
<para>The <quote><parameter>-</parameter></quote> instructs
<command>su</command> to start a login shell as opposed to a non-login shell.
The difference between these two types of shells can be found in detail in
The difference between these two types of shells is described in detail in
<filename>bash(1)</filename> and <command>info bash</command>.</para>
</sect1>

View File

@ -32,7 +32,7 @@ EOF</userinput></screen>
ensuring a clean environment.</para>
<para>The new instance of the shell is a <emphasis>non-login</emphasis>
shell, which does not read, and execute, the contents of <filename>/etc/profile</filename> or
shell, which does not read, and execute, the contents of the <filename>/etc/profile</filename> or
<filename>.bash_profile</filename> files, but rather reads, and executes, the
<filename>.bashrc</filename> file instead. Create the
<filename>.bashrc</filename> file now:</para>
@ -59,10 +59,10 @@ EOF</userinput></screen>
<para>The <command>set +h</command> command turns off
<command>bash</command>'s hash function. Hashing is ordinarily a useful
feature&mdash;<command>bash</command> uses a hash table to remember the
full path of executable files to avoid searching the <envar>PATH</envar>
full path to executable files to avoid searching the <envar>PATH</envar>
time and again to find the same executable. However, the new tools should
be used as soon as they are installed. By switching off the hash function,
the shell will always search the <envar>PATH</envar> when a program is to
be used as soon as they are installed. Switching off the hash function forces
the shell to search the <envar>PATH</envar> whenever a program is to
be run. As such, the shell will find the newly compiled tools in
<filename class="directory">$LFS/tools/bin</filename> as soon as they are
available without remembering a previous version of the same program
@ -115,10 +115,10 @@ EOF</userinput></screen>
<varlistentry>
<term><parameter>PATH=/usr/bin</parameter></term>
<listitem>
<para>Many modern linux distributions have merged <filename
<para>Many modern Linux distributions have merged <filename
class="directory">/bin</filename> and <filename
class="directory">/usr/bin</filename>. When this is the case, the standard
<envar>PATH</envar> variable needs just to be set to <filename
<envar>PATH</envar> variable should be set to <filename
class="directory">/usr/bin/</filename> for the <xref
linkend="chapter-temporary-tools"/> environment. When this is not the
case, the following line adds <filename class="directory">/bin</filename>
@ -141,7 +141,7 @@ EOF</userinput></screen>
standard <envar>PATH</envar>, the cross-compiler installed at the beginning
of <xref linkend="chapter-cross-tools"/> is picked up by the shell
immediately after its installation. This, combined with turning off hashing,
limits the risk that the compiler from the host be used instead of the
limits the risk that the compiler from the host is used instead of the
cross-compiler.</para>
</listitem>
</varlistentry>
@ -195,7 +195,8 @@ EOF</userinput></screen>
</important>
<para>Finally, to have the environment fully prepared for building the
temporary tools, source the just-created user profile:</para>
temporary tools, force the <command>bash</command> shell to read
the new user profile:</para>
<screen><userinput>source ~/.bash_profile</userinput></screen>