diff --git a/chapter01/changelog.xml b/chapter01/changelog.xml index 283d73073..d6d330f6a 100644 --- a/chapter01/changelog.xml +++ b/chapter01/changelog.xml @@ -52,6 +52,14 @@ +September 1st, 2002 [timothy]: Chapter 06 - About +debugging symbols: Removed info. about stripping /static. Man: Added sed +statement to prevent groff from using SGR escape sequences. + +September 1st, 2002 [timothy]: Chapter 05 - Install all +software as an unprivileged user: Added $CC='gcc -s' to omit the +compilation of symbols in static packages. + August 30th, 2002 [timothy]: Chapter 06 - Makedev: Put rm /bin/bash after device creation. Perl: Removed information about the old patch. diff --git a/chapter05/installasuser.xml b/chapter05/installasuser.xml index a914e6a50..2001ca18d 100644 --- a/chapter05/installasuser.xml +++ b/chapter05/installasuser.xml @@ -32,15 +32,16 @@ umask 022 LFS=/mnt/lfs LC_ALL=POSIX -export LFS LC_ALL +CC='gcc -s' +export LFS LC_ALL CC EOF source ~/.bash_profile This profile makes sure the umask is set to 022 so newly created files and directories will have the correct permissions. It is advisable -to keep this setting throughout your LFS installation. Also, the $LFS -and $LC_ALL environment variables are set. $LFS has been explained in -previous chapters already. $LC_ALL is a variable that is used for +to keep this setting throughout your LFS installation. Also, the $LFS, +$LC_ALL, and $CC environment variables are set. $LFS has been explained +in previous chapters already. $LC_ALL is a variable that is used for internationalization. When your host distribution uses a glibc version older than 2.2.4, @@ -50,5 +51,10 @@ of chapter 6 and try to return to it. By setting this to "POSIX" ("C" is an alias for "POSIX") we ensure that everything will work as expected in the chroot environment. +$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 the build time. + diff --git a/chapter06/aboutdebug.xml b/chapter06/aboutdebug.xml index 2d9d904fc..a4ffefc52 100644 --- a/chapter06/aboutdebug.xml +++ b/chapter06/aboutdebug.xml @@ -37,17 +37,14 @@ similar if you compare programs with and without debugging symbols. To remove debugging symbols from a binary (must be an a.out or ELF binary) run strip --strip-debug filename. Wildcards can be used to strip debugging symbols from multiple files (use something -like strip --strip-debug $LFS/usr/bin/*). -Most people will probably never use a debugger on software, so by -removing those symbols a lot of disk space can be regained. +like strip --strip-debug $LFS/usr/bin/*). Most +people will probably never use a debugger on software, so by removing +those symbols a lot of disk space can be regained. For your convenience, chapter 9 includes one simple command to strip -all debugging symbols from all programs and libraries on your -system. If you are short on diskspace you can start with stripping -all the files under $LFS/static - -You might find additional information in the optimization hint which can -be found at . +all debugging symbols from the programs and libraries on your system. You +might find additional information in the optimization hint which can be +found at . diff --git a/chapter06/man-exp.xml b/chapter06/man-exp.xml index 5c70e18c3..00c41e2ae 100644 --- a/chapter06/man-exp.xml +++ b/chapter06/man-exp.xml @@ -8,5 +8,9 @@ where a program is found. By appending /usr/bin:/bin to PATH for the ./configure command, we make sure that man doesn't use the /static versions of our programs. +sed -e '/^NROFF/s/-mandoc/-c -mandoc/': +This prevents groff from using SGR (Set Graphics Rendition) escape +sequences on our man pages. + diff --git a/chapter06/man-inst.xml b/chapter06/man-inst.xml index 0e8fff874..38fdcd8e4 100644 --- a/chapter06/man-inst.xml +++ b/chapter06/man-inst.xml @@ -4,8 +4,11 @@ Run the following commands to install man: PATH=$PATH:/usr/bin:/bin \ -    ./configure -default -confdir=/etc && +    ./configure -default -confdir=/etc && make && +cp src/man.conf{,.backup} && +sed -e '/^NROFF/s/-mandoc/-c -mandoc/' \ +    src/man.conf.backup > src/man.conf && make install You may want to take a look at the man hint diff --git a/index.xml b/index.xml index dfd20a0fc..11303450a 100644 --- a/index.xml +++ b/index.xml @@ -4,8 +4,8 @@ - - + +