cvs commit: LFS/BOOK/entities chapter05.ent

timothy at linuxfromscratch.org timothy at linuxfromscratch.org
Sun Jan 5 08:19:00 PST 2003


timothy     03/01/05 11:19:00

  Modified:    BOOK     index.xml
               BOOK/chapter01 changelog.xml
               BOOK/chapter05 chapter05.xml
               BOOK/entities chapter05.ent
  Added:       BOOK/chapter05 adding-user.xml setting-environment.xml
  Removed:     BOOK/chapter05 installasuser.xml
  Log:
  Applied a modified version of Alex's patch to split the  in two.
  
  Revision  Changes    Path
  1.531     +2 -2      LFS/BOOK/index.xml
  
  Index: index.xml
  ===================================================================
  RCS file: /home/cvsroot/LFS/BOOK/index.xml,v
  retrieving revision 1.530
  retrieving revision 1.531
  diff -u -r1.530 -r1.531
  --- index.xml	4 Jan 2003 02:33:59 -0000	1.530
  +++ index.xml	5 Jan 2003 16:19:00 -0000	1.531
  @@ -4,8 +4,8 @@
   
   <!ENTITY book SYSTEM "book/book.xml">
   
  -<!ENTITY version "20030103">
  -<!ENTITY releasedate "January 3rd, 2003">
  +<!ENTITY version "20030105">
  +<!ENTITY releasedate "January 5th, 2003">
   
   <!ENTITY ftp-root "ftp://ftp.linuxfromscratch.org">
   <!ENTITY http-root "http://ftp.linuxfromscratch.org">
  
  
  
  1.427     +7 -2      LFS/BOOK/chapter01/changelog.xml
  
  Index: changelog.xml
  ===================================================================
  RCS file: /home/cvsroot/LFS/BOOK/chapter01/changelog.xml,v
  retrieving revision 1.426
  retrieving revision 1.427
  diff -u -r1.426 -r1.427
  --- changelog.xml	3 Jan 2003 03:55:07 -0000	1.426
  +++ changelog.xml	5 Jan 2003 16:19:00 -0000	1.427
  @@ -57,7 +57,12 @@
   </itemizedlist>
   </para></listitem>
   
  -<listitem><para>January 2nd, 2003 [geard]: Chapter 05 - All packages whose
  +<listitem><para>January 5th, 2003 [timothy]: Chapter 05 - Applied Alex's
  +patch to split the <emphasis>Install all software as an unprivileged
  +user</emphasis> page into two pages: <emphasis>Adding the user lfs</emphasis>
  +and <emphasis>Setting up the environment</emphasis>.</para></listitem>
  +
  +<listitem><para>January 2nd, 2003 [gerard]: Chapter 05 - All packages whose
   configure script supports the LDFLAGS environment variable now use it
   rather than passing the variable down to
   <userinput>make</userinput>.</para></listitem>
  @@ -77,7 +82,7 @@
   man-1.5k-manpath.patch and man-1.5k-pager.patch).</para></listitem>
   
   <listitem><para>January 1st, 2003 [gerard]: Chapter 06 - Glibc Second Pass:
  -Fixec typo in linuxthreads man pages installation.</para></listitem>
  +Fixed typo in linuxthreads man pages installation.</para></listitem>
   
   <listitem><para>January 1st, 2003 [gerard]: Chapter 06 - Linux Kernel: The
   man pages can't be installed here because it requires Perl. Moved to end of
  
  
  
  1.16      +2 -1      LFS/BOOK/chapter05/chapter05.xml
  
  Index: chapter05.xml
  ===================================================================
  RCS file: /home/cvsroot/LFS/BOOK/chapter05/chapter05.xml,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -r1.15 -r1.16
  --- chapter05.xml	25 May 2002 00:19:46 -0000	1.15
  +++ chapter05.xml	5 Jan 2003 16:19:00 -0000	1.16
  @@ -5,7 +5,8 @@
   &c5-introduction;
   &c5-whystatic;
   &c5-creatingstaticdir;
  -&c5-installasuser;
  +&c5-addinguser;
  +&c5-settingenviron;
   &c5-bash;
   &c5-binutils;
   &c5-bzip2;
  
  
  
  1.1                  LFS/BOOK/chapter05/adding-user.xml
  
  Index: adding-user.xml
  ===================================================================
  <sect1 id="ch05-addinguser">
  <title>Adding the user lfs</title>
  <?dbhtml filename="addinguser.html" dir="chapter05"?>
  
  <para>If you are logged in as <emphasis>root</emphasis> during Chapter 5,
  your host system can be damaged by a single mistake. We recommend that
  you build the packages in Chapter 5 as an unprivileged user. You could use
  your own user name, but to ensure a clean build environment, we'll create a
  new user: <emphasis>lfs</emphasis>. As <emphasis>root</emphasis>, issue
  the following commands to add the new user:</para>
  
  <para><screen><userinput>useradd -s /bin/bash -m lfs
  passwd lfs</userinput></screen></para>
  
  <para>In order to grant the user <emphasis>lfs</emphasis> the proper permissions
  to the <filename>$LFS/static</filename> directory, issue the following
  command:</para>
  
  <para><screen><userinput>chown -R lfs $LFS/static</userinput></screen></para>
  
  <para>Next, login as user <emphasis>lfs</emphasis>. This can be accomplished
  via a virtual console, display manager or with the substitute user
  command:</para>
  
  <para><screen><userinput>su - lfs</userinput></screen></para>
  
  <para>The "<userinput>-</userinput>" instructs <userinput>su</userinput> to
  start a new, clean shell.</para>
  
  </sect1>
  
  
  
  1.1                  LFS/BOOK/chapter05/setting-environment.xml
  
  Index: setting-environment.xml
  ===================================================================
  <sect1 id="ch05-settingenviron">
  <title>Setting up the environment</title>
  <?dbhtml filename="settingenviron.html" dir="chapter05"?>
  
  <para>While logged in as user <emphasis>lfs</emphasis>, issue the
  following commands to set up a good work environment:</para>
  
  <para><screen><userinput>cat > ~/.bash_profile << "EOF"
  umask 022
  LFS=/mnt/lfs
  LC_ALL=POSIX
  CC="gcc -s"
  export LFS LC_ALL CC
  EOF
  source ~/.bash_profile</userinput></screen></para>
  
  <para>This profile sets the umask to 022, so newly created files will and
  directories will have the correct permissions. To be more specific, only
  the file owner will have write permission to new files and directories.
  Other users of the system will be have read permission, and executable
  permission to directories. It is advisable to keep this setting throughout
  your LFS installation.</para>
  
  <para>The LFS, LC_ALL, and CC environment variables are also set. The LFS
  variable has been explained in previous chapters. LC_ALL is a variable used
  for internationalization.</para>
  
  <para>The LC_ALL variable controls the localization of certain programs,
  making their messages follow the conventions of a specified country. If your
  host system uses a version of <emphasis>glibc</emphasis> older than 2.2.4,
  having LC_ALL set to something other than "C" or "POSIX" during Chapter 5
  may cause trouble if you exit the chroot environment and wish to return later.
  By setting LC_ALL to "POSIX" ("C" is an alias for "POSIX") we ensure that
  everything will work as expected in the chroot environment.</para>
  
  <para>CC is a variable we set in order to prevent debugging symbols from
  being compiled into our static packages. By omitting these symbols during
  the linking stage of compilation, we save hard drive space and decrease our
  build time.</para>
  
  <para>We are now prepared to begin building the temporary tools which will
  support us in later chapters.</para>
  
  </sect1>
  
  
  
  
  1.5       +2 -1      LFS/BOOK/entities/chapter05.ent
  
  Index: chapter05.ent
  ===================================================================
  RCS file: /home/cvsroot/LFS/BOOK/entities/chapter05.ent,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- chapter05.ent	25 May 2002 00:19:47 -0000	1.4
  +++ chapter05.ent	5 Jan 2003 16:19:00 -0000	1.5
  @@ -2,4 +2,5 @@
   <!ENTITY c5-introduction SYSTEM "../chapter05/introduction.xml">
   <!ENTITY c5-whystatic SYSTEM "../chapter05/whystatic.xml">
   <!ENTITY c5-creatingstaticdir SYSTEM "../chapter05/creatingstaticdir.xml">
  -<!ENTITY c5-installasuser SYSTEM "../chapter05/installasuser.xml">
  +<!ENTITY c5-addinguser SYSTEM "../chapter05/adding-user.xml">
  +<!ENTITY c5-settingenviron SYSTEM "../chapter05/setting-environment.xml">
  
  
  
-- 
Unsubscribe: send email to listar at linuxfromscratch.org
and put 'unsubscribe lfs-book' in the subject header of the message



More information about the lfs-book mailing list