source: chapter01/how.xml@ 53579a5

10.0 10.0-rc1 10.1 10.1-rc1 11.0 11.0-rc1 11.0-rc2 11.0-rc3 11.1 11.1-rc1 11.2 11.2-rc1 11.3 11.3-rc1 12.0 12.0-rc1 12.1 12.1-rc1 6.4 6.5 6.6 6.7 6.8 7.0 7.1 7.2 7.3 7.4 7.5 7.5-systemd 7.6 7.6-systemd 7.7 7.7-systemd 7.8 7.8-systemd 7.9 7.9-systemd 8.0 8.1 8.2 8.3 8.4 9.0 9.1 arm bdubbs/gcc13 ml-11.0 multilib renodr/libudev-from-systemd s6-init trunk xry111/arm64 xry111/arm64-12.0 xry111/clfs-ng xry111/lfs-next xry111/loongarch xry111/loongarch-12.0 xry111/loongarch-12.1 xry111/mips64el xry111/pip3 xry111/rust-wip-20221008 xry111/update-glibc
Last change on this file since 53579a5 was 10bd240, checked in by Bruce Dubbs <bdubbs@…>, 16 years ago

Updated the discussion in Chapter 1 explaining that the LiveCD is out of date.

Added a paragraph to the note in the packages page explaining that bandwidth
can be saved when making multiple updates within a minor kernel release by
downloading a base version and patches.

git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@8675 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689

  • Property mode set to 100644
File size: 5.1 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../general.ent">
5 %general-entities;
6]>
7
8<sect1 id="ch-intro-how">
9 <?dbhtml filename="how.html"?>
10
11 <title>How to Build an LFS System</title>
12
13 <para>The LFS system will be built by using a previously installed
14 Linux distribution (such as Debian, Mandriva, Red Hat, or SUSE). This
15 existing Linux system (the host) will be used as a starting point to
16 provide necessary programs, including a compiler, linker, and shell,
17 to build the new system. Select the <quote>development</quote> option
18 during the distribution installation to be able to access these
19 tools.</para>
20
21 <para>As an alternative to installing a separate distribution onto your
22 machine, you may wish to use the Linux From Scratch LiveCD or a LiveCD from a
23 commercial distribution. The LFS LiveCD works well as a host system,
24 providing all the tools you need to successfully follow the instructions in
25 this book. Unfortunately, development of the LiveCD has not progressed
26 recently and it only contains older versions of the source packages and
27 patches (for those ISOs not labels -nosrc or -min), and this book. For more
28 information about the LFS LiveCD or to download a copy, visit <ulink
29 url="&livecd-root;"/>.</para>
30
31 <note>
32 <para>The LFS LiveCD might not work on newer hardware configurations,
33 failing to boot or failing to detect some devices, some like SATA hard
34 drives.</para>
35 </note>
36
37 <para><xref linkend="chapter-partitioning"/> of this book describes how
38 to create a new Linux native partition and file system, the place
39 where the new LFS system will be compiled and installed. <xref
40 linkend="chapter-getting-materials"/> explains which packages and
41 patches need to be downloaded to build an LFS system and how to store
42 them on the new file system. <xref linkend="chapter-final-preps"/>
43 discusses the setup of an appropriate working environment. Please read
44 <xref linkend="chapter-final-preps"/> carefully as it explains several
45 important issues the reader should be aware of before beginning to
46 work through <xref linkend="chapter-temporary-tools"/> and beyond.</para>
47
48 <para><xref linkend="chapter-temporary-tools"/> explains the
49 installation of a number of packages that will form the basic
50 development suite (or toolchain) which is used to build the actual
51 system in <xref linkend="chapter-building-system"/>. Some of these
52 packages are needed to resolve circular dependencies&mdash;for example,
53 to compile a compiler, you need a compiler.</para>
54
55 <para><xref linkend="chapter-temporary-tools"/> also shows the user how to
56 build a first pass of the toolchain, including Binutils and GCC (first pass
57 basically means these two core packages will be reinstalled).
58 The next step is to build Glibc, the C library. Glibc will be compiled by
59 the toolchain programs built in the first pass. Then, a second pass of the
60 toolchain will be built. This time, the toolchain will be dynamically linked
61 against the newly built Glibc. The remaining <xref
62 linkend="chapter-temporary-tools"/> packages are built using this second
63 pass toolchain. When this is done, the LFS installation process will no
64 longer depend on the host distribution, with the exception of the running
65 kernel. </para>
66
67 <para>This effort to isolate the new system from the host distribution may
68 seem excessive, but a full technical explanation is provided in
69 <xref linkend="ch-tools-toolchaintechnotes"/>.</para>
70
71 <para>In <xref linkend="chapter-building-system"/>, the full LFS system is
72 built. The <command>chroot</command> (change root) program is used to enter
73 a virtual environment and start a new shell whose root directory will be
74 set to the LFS partition. This is very similar to rebooting and instructing
75 the kernel to mount the LFS partition as the root partition. The system
76 does not actually reboot, but instead <command>chroot</command>'s because
77 creating a bootable system requires additional work which is not necessary
78 just yet. The major advantage is that <quote>chrooting</quote> allows the
79 builder to continue using the host while LFS is being built. While waiting
80 for package compilation to complete, a user can switch to a different
81 virtual console (VC) or X desktop and continue using the computer as
82 normal.</para>
83
84 <para>To finish the installation, the LFS-Bootscripts are set up in
85 <xref linkend="chapter-bootscripts"/>, and the kernel and boot loader are set
86 up in <xref linkend="chapter-bootable"/>. <xref linkend="chapter-finalizing"/>
87 contains information on furthering the LFS experience beyond this book.
88 After the steps in this book have been implemented, the computer will be
89 ready to reboot into the new LFS system.</para>
90
91 <para>This is the process in a nutshell. Detailed information on each
92 step is discussed in the following chapters and package descriptions.
93 Items that may seem complicated will be clarified, and everything will
94 fall into place as the reader embarks on the LFS adventure.</para>
95
96</sect1>
Note: See TracBrowser for help on using the repository browser.