From 81fd230419b0cfd052b08fc1ed352bb7d49975df Mon Sep 17 00:00:00 2001 From: Gerard Beekmans Date: Sat, 19 Feb 2005 22:16:42 +0000 Subject: Trunk is now identical to Testing git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@4648 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689 --- chapter01/how.xml | 74 ++++++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 73 insertions(+), 1 deletion(-) (limited to 'chapter01/how.xml') diff --git a/chapter01/how.xml b/chapter01/how.xml index 98828fc8a..b2390fb48 100644 --- a/chapter01/how.xml +++ b/chapter01/how.xml @@ -7,6 +7,78 @@ How to Build an LFS System -See testing +The LFS system will be built by using a previously installed +Linux distribution (such as Debian, Mandrake, Red Hat, or SuSE). This +existing Linux system (the host) will be used as a starting point to +provide necessary programs, including a compiler, linker, and shell, +to build the new system. Select the development option +during the distribution installation to be able to access these +tools. + + of this book describes how +to create a new Linux native partition and file system, the place +where the new LFS system will be compiled and installed. explains which packages and +patches need to be downloaded to build an LFS system and how to store +them on the new file system. +discusses the setup for an appropriate work environment. Please read + carefully as it explains several +important issues the developer should be aware of before beginning to +work through and +beyond. + + explains the +installation of a number of packages that will form the basic +development suite (or toolchain) which is used to build the actual +system in . Some of these +packages are needed to resolve circular dependencies—for example, +to compile a compiler, you need a compiler. + + also shows the user how +to build a first pass of the toolchain, including Binutils and GCC +(first pass basically means these two core packages will be +re-installed a second time). The programs from these packages will be +linked statically in order to be used independently of the host +system. The next step is to build Glibc, the C library. Glibc will be +compiled by the toolchain programs built in the first pass. Then, a +second pass of the toolchain will be built. This time, the toolchain +will be dynamically linked against the newly built Glibc. The +remaining packages are built +using this second pass toolchain. When this is done, the LFS +installation process will no longer depend on the host distribution, +with the exception of the running kernel. + +While this may initially seem like a lot of work to get away +from a host distribution, a full technical explanation is provided at +the beginning of , +including notes on the differences between +statically and dynamically-linked programs. + +In , the full LFS system is +built. The chroot (change root) program is used to enter a virtual +environment and start a new shell whose root directory will be set to +the LFS partition. This is very similar to rebooting and instructing +the kernel to mount the LFS partition as the root partition. The +system does not actually reboot, but instead chroots because creating a +bootable system requires additional work which is not necessary just +yet. The major advantage is that chrooting allows the +builder to continue using the host while LFS is being built. While +waiting for package compilation to complete, a user can switch to a +different virtual console (VC) or X desktop and continue using the +computer as normal. + +To finish the installation, the bootscripts are set up in , and the kernel and boot loader are set +up in . contains information on furthering the +LFS experience beyond this book. After the steps in this book have +been implemented, the computer will be ready to reboot into the new +LFS system. + +This is the process in a nutshell. Detailed information on each +step is discussed in the following chapters and package descriptions. +Items that may seem complicated will be clarified, and everything will +fall into place as the developer embarks on the LFS adventure. + -- cgit v1.2.3-54-g00ecf