Linux From Scratch

Version 5.0-pre2

Gerard Beekmans

This book describes the process of creating a Linux system from scratch, using nothing but the sources of the required software.


Dedication

This book is dedicated to my loving and supportive wife Beverly Beekmans.

Table of Contents
Preface
Foreword
Audience
Who would want to read this book
Who would not want to read this book
Prerequisites
Structure
Part I - Introduction
Part II - Preparing for the build
Part III - Building the LFS system
Part IV - Appendices
I. Part I - Introduction
1. Introduction
How things are going to be done
Conventions used in this book
Book version
Changelog
Resources
Acknowledgments
2. Important information
About $LFS
About SBUs
About the test suites
How to ask for help
II. Part II - Preparing for the build
3. Preparing a new partition
Introduction
Creating a new partition
Creating a file system on the new partition
Mounting the new partition
4. The materials: packages and patches
Introduction
All the packages
Needed patches
5. Preparing the LFS system
Introduction
Why we use static linking
Creating the $LFS/tools directory
Adding the user lfs
Setting up the environment
Installing Binutils-2.14 - Pass 1
Installing GCC-3.3.1 - Pass 1
Installing Linux-2.4.22 headers
Installing Glibc-2.3.2
"Locking in" Glibc
Installing Tcl-8.4.4
Installing Expect-5.39.0
Installing DejaGnu-1.4.3
Installing GCC-3.3.1 - Pass 2
Installing Binutils-2.14 - Pass 2
Installing Gawk-3.1.3
Installing Coreutils-5.0
Installing Bzip2-1.0.2
Installing Gzip-1.3.5
Installing Diffutils-2.8.1
Installing Findutils-4.1.20
Installing Make-3.80
Installing Grep-2.5.1
Installing Sed-4.0.7
Installing Gettext-0.12.1
Installing Ncurses-5.3
Installing Patch-2.5.4
Installing Tar-1.13.25
Installing Texinfo-4.6
Installing Bash-2.05b
Installing Util-linux-2.12
Installing Perl-5.8.0
Stripping
III. Part III - Building the LFS system
6. Installing basic system software
Introduction
About debugging symbols
Entering the chroot environment
Changing ownership
Creating directories
Mounting the proc and devpts file systems
Creating essential symlinks
Creating the passwd and group files
Creating devices (Makedev-1.7)
Installing Linux-2.4.22 headers
Installing Man-pages-1.60
Installing Glibc-2.3.2
Re-adjusting the toolchain
Installing Binutils-2.14
Installing GCC-3.3.1
Installing Coreutils-5.0
Installing Zlib-1.1.4
Installing Lfs-Utils-0.3
Installing Findutils-4.1.20
Installing Gawk-3.1.3
Installing Ncurses-5.3
Installing Vim-6.2
Installing M4-1.4
Installing Bison-1.875
Installing Less-381
Installing Groff-1.19
Installing Sed-4.0.7
Installing Flex-2.5.4a
Installing Gettext-0.12.1
Installing Net-tools-1.60
Installing Inetutils-1.4.2
Setting up Basic Networking
Installing Perl-5.8.0
Installing Texinfo-4.6
Installing Autoconf-2.57
Installing Automake-1.7.6
Installing Bash-2.05b
Installing File-4.04
Installing Libtool-1.5
Installing Bzip2-1.0.2
Installing Diffutils-2.8.1
Installing Ed-0.2
Installing Kbd-1.08
Installing E2fsprogs-1.34
Installing Grep-2.5.1
Installing Grub-0.93
Installing Gzip-1.3.5
Installing Man-1.5m2
Installing Make-3.80
Installing Modutils-2.4.25
Installing Patch-2.5.4
Installing Procinfo-18
Installing Procps-3.1.11
Installing Psmisc-21.3
Installing Shadow-4.0.3
Installing Sysklogd-1.4.1
Installing Sysvinit-2.85
Installing Tar-1.13.25
Installing Util-linux-2.12
Installing GCC-2.95.3
Revised chroot command
Installing LFS-Bootscripts-1.11
Configuring system components
7. Setting up system boot scripts
Introduction
How does the booting process with these scripts work?
Configuring the setclock script
Do I need the loadkeys script?
Configuring the sysklogd script
Configuring the localnet script
Creating the /etc/hosts file
Configuring the network script
8. Making the LFS system bootable
Introduction
Creating the /etc/fstab file
Installing Linux-2.4.22
Making the LFS system bootable
9. The End
The End
Get Counted
Rebooting the system
What now?
IV. Part IV - Appendices
A. Package descriptions and dependencies
Introduction
Autoconf
Automake
Bash
Binutils
Bison
Bzip2
Coreutils
DejaGnu
Diffutils
E2fsprogs
Ed
Expect
File
Findutils
Flex
Gawk
GCC
Gettext
Glibc
Grep
Groff
Grub
Gzip
Inetutils
Kbd
Less
LFS-Bootscripts
Lfs-Utils
Libtool
Linux (the kernel)
M4
Make
MAKEDEV
Man
Man-pages
Modutils
Ncurses
Net-tools
Patch
Perl
Procinfo
Procps
Psmisc
Sed
Shadow
Sysklogd
Sysvinit
Tar
Tcl
Texinfo
Util-linux
Vim
Zlib
B. Index of programs and library files