aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlex Gronenwoud <alex@linuxfromscratch.org>2004-03-09 19:08:33 +0000
committerAlex Gronenwoud <alex@linuxfromscratch.org>2004-03-09 19:08:33 +0000
commit5b7293ab71a253046b37850efe349b15692ad4fd (patch)
tree8d6e4e7934428ddd0f75cadff9f5f2d18bfdf355
parentc6b5ddb7a6bd11d84c183cd3c3fd3c507f797978 (diff)
Removing HOME and --login from the chroot commands.
git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@3285 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689
-rw-r--r--chapter01/changelog.xml6
-rw-r--r--chapter06/bash.xml2
-rw-r--r--chapter06/chapter06.xml22
-rw-r--r--chapter06/coreutils.xml15
-rw-r--r--chapter06/make.xml3
5 files changed, 26 insertions, 22 deletions
diff --git a/chapter01/changelog.xml b/chapter01/changelog.xml
index a00d1c1a9..a704656bb 100644
--- a/chapter01/changelog.xml
+++ b/chapter01/changelog.xml
@@ -36,6 +36,12 @@ first a summary, then a detailed log.</para>
</itemizedlist>
</listitem>
+<listitem><para>March 9th, 2004 [alex]: Chapter 6 - Removed HOME and --login
+from the chroot commands.</para></listitem>
+
+<listitem><para>March 6th, 2004 [alex]: Rotated the contents of chapters 2, 3
+and 4.</para></listitem>
+
<listitem><para>February 27th, 2004 [jeremy]: Upgraded to
Procps-3.2.0.</para></listitem>
diff --git a/chapter06/bash.xml b/chapter06/bash.xml
index f0c2e1b57..aa38ef855 100644
--- a/chapter06/bash.xml
+++ b/chapter06/bash.xml
@@ -38,7 +38,7 @@ patch:</para>
<para>And reload the newly compiled <command>bash</command> program:</para>
-<screen><userinput>exec /bin/bash --login +h</userinput></screen>
+<screen><userinput>exec /bin/bash +h</userinput></screen>
</sect2>
diff --git a/chapter06/chapter06.xml b/chapter06/chapter06.xml
index b8ab3f3a9..da1ae8126 100644
--- a/chapter06/chapter06.xml
+++ b/chapter06/chapter06.xml
@@ -129,18 +129,18 @@ the following command to enter the small world that is, at the moment,
populated with only the temporary tools:</para>
<screen><userinput>chroot $LFS /tools/bin/env -i \
-&nbsp;&nbsp;&nbsp;&nbsp;HOME=/root TERM=$TERM PS1='\u:\w\$ ' \
+&nbsp;&nbsp;&nbsp;&nbsp;TERM=$TERM PS1='\u:\w\$ ' \
&nbsp;&nbsp;&nbsp;&nbsp;PATH=/bin:/usr/bin:/sbin:/usr/sbin:/tools/bin \
-&nbsp;&nbsp;&nbsp;&nbsp;/tools/bin/bash --login +h</userinput></screen>
+&nbsp;&nbsp;&nbsp;&nbsp;/tools/bin/bash +h</userinput></screen>
<para>The <emphasis>-i</emphasis> option given to the
<command>env</command> command will clear all variables of the chroot
-environment. After that, only the HOME, TERM, PS1 and PATH variables are
+environment. After that, only the TERM, PS1 and PATH variables are
set again. The TERM=$TERM construct will set the TERM variable inside chroot
to the same value as outside chroot; this variable is needed for programs
-like <command>vim</command> and <command>less</command> to operate
-properly. If you need other variables present, such as CFLAGS or CXXFLAGS,
-this is a good place to set them again.</para>
+like <command>less</command> and <command>vim</command> to operate
+properly. If you need other variables present, such as CFLAGS, CXXFLAGS or
+HOME, this is a good place to set them.</para>
<para>From this point on there's no need to use the LFS variable anymore,
because everything you do will be restricted to the LFS file system -- since
@@ -328,7 +328,7 @@ and have just created the <filename>/etc/passwd</filename> and
<filename>/etc/group</filename> files, user name and group name resolution
will now work.</para>
-<screen><userinput>exec /tools/bin/bash --login +h</userinput></screen>
+<screen><userinput>exec /tools/bin/bash +h</userinput></screen>
<para>Note the use of the <emphasis>+h</emphasis> directive. This tells
<command>bash</command> not to use its internal path hashing. Without this
@@ -580,9 +580,9 @@ If you're not sure whether you entered chroot with the command given in
<para>Then reenter it with:</para>
<screen><userinput>chroot $LFS /tools/bin/env -i \
-&nbsp;&nbsp;&nbsp;&nbsp;HOME=/root TERM=$TERM PS1='\u:\w\$ ' \
+&nbsp;&nbsp;&nbsp;&nbsp;TERM=$TERM PS1='\u:\w\$ ' \
&nbsp;&nbsp;&nbsp;&nbsp;PATH=/bin:/usr/bin:/sbin:/usr/sbin \
-&nbsp;&nbsp;&nbsp;&nbsp;/tools/bin/bash --login</userinput></screen>
+&nbsp;&nbsp;&nbsp;&nbsp;/tools/bin/bash</userinput></screen>
<para>Now you can safely strip the binaries and libraries:</para>
@@ -610,9 +610,9 @@ destroyed.</para>
it, you should use the following modified chroot command:</para>
<screen><userinput>chroot $LFS /usr/bin/env -i \
-&nbsp;&nbsp;&nbsp;&nbsp;HOME=/root TERM=$TERM PS1='\u:\w\$ ' \
+&nbsp;&nbsp;&nbsp;&nbsp;TERM=$TERM PS1='\u:\w\$ ' \
&nbsp;&nbsp;&nbsp;&nbsp;PATH=/bin:/usr/bin:/sbin:/usr/sbin \
-&nbsp;&nbsp;&nbsp;&nbsp;/bin/bash --login</userinput></screen>
+&nbsp;&nbsp;&nbsp;&nbsp;/bin/bash</userinput></screen>
<para>The reason for this is that, since the programs in <filename
class="directory">/tools</filename> are no longer needed, you may want to
diff --git a/chapter06/coreutils.xml b/chapter06/coreutils.xml
index 1562d0598..24e7733e9 100644
--- a/chapter06/coreutils.xml
+++ b/chapter06/coreutils.xml
@@ -45,14 +45,7 @@ of files and users that aren't valid yet this early in the LFS build. We will
therefore have to set up a few things before being able to run the tests. If
you choose not to run these tests, skip down to "Install the package".</para>
-<para>To be able to run the full test suite, the <command>su</command> program
-needs to be installed. We didn't bother to install this little program in
-<xref linkend="chapter-temporary-tools"/> because it requires root privileges,
-so do it now:</para>
-
-<screen><userinput>make install-root</userinput></screen>
-
-<para>Create a 'table of mounted filesystems' file with:</para>
+<para>First create a 'table of mounted filesystems' file with:</para>
<screen><userinput>touch /etc/mtab</userinput></screen>
@@ -70,7 +63,11 @@ are meant to be run as <emphasis>root</emphasis>:</para>
<para>Then run the remainder of the tests as the <emphasis>dummy</emphasis>
user:</para>
-<screen><userinput>su dummy -c "make RUN_EXPENSIVE_TESTS=yes check"</userinput></screen>
+<screen><userinput>src/su dummy -c "make RUN_EXPENSIVE_TESTS=yes check"</userinput></screen>
+
+<para>The above command uses the newly compiled <command>src/su</command>
+program, since in <xref linkend="chapter-temporary-tools"/> we didn't bother to
+install it, because installing it requires root privileges.</para>
<para>When you're done testing, remove the dummy user and groups:</para>
diff --git a/chapter06/make.xml b/chapter06/make.xml
index ed3542427..e3d034f30 100644
--- a/chapter06/make.xml
+++ b/chapter06/make.xml
@@ -24,7 +24,8 @@
<screen><userinput>make</userinput></screen>
<para>To have the results tested, issue:
-<userinput>make check</userinput>.</para>
+<userinput>make HOME=/root check</userinput>. The HOME environment variable
+needs to be set to prevent one of the tests from failing.</para>
<para>And install the package:</para>