本書では、特定の表記を用いて分かりやすく説明を行っていきます。 利用する表記にはいくつかあります。以下にその例を示します。
./configure --prefix=/usr
この表記は特に説明がない限りは、そのまま入力するテキストを示しています。 またコマンドの説明を行うために用いる場合もあります。
install-info: unknown option
`--dir-file=/mnt/lfs/usr/info/dir'
上の表記は固定幅フォントで示されており、たいていはコマンド入力の結果として出力される端末メッセージを示しています。 あるいは
/boot/grub/grub.conf
といったファイル名を示すのに利用する場合もあります。
Emphasis
上の表記は様々な意図で用いています。 特に重要なポイントや入力サンプルなどを表わします。
https://www.linuxfromscratch.org/
この表記は 外部サイトへのハイパーリンクを示します。 そこには「ハウツー」やダウンロードサイトやウェブサイトなどが含まれます。
この表記は本書内の別のページへのリンクを表わします。 別のパッケージを説明している別セクションなどです。
cat > $LFS/etc/group << "EOF"
root:x:0:
bin:x:1:
......
EOF
この表記は設定ファイル類を生成する場合などにおいて示します。 1行目のコマンドは太字で表記され
$LFS/etc/group
というファイルを生成することを指示しています。 そのファイルへは2行目以降 EOF が記述されるまでのテキストが出力されます。 したがってこの表記は通常そのままタイプ入力します。 コピーしてペーストするだけですぐに使えます。
<REPLACED TEXT>
上の表記は入力するテキストを仮に表現したものです。 したがって修正が必要なものであるため、そのまま入力したり、コピー、ペースト操作で貼り付けないでください。 山カッコも含めて適切なものに置き換えてください。
root
この表記は、特定のシステムユーザーやグループを表わすものです。
When new packages are created, the software's authors depend on prior work. In order to build a package in BLFS, these dependencies must be built before the desired package can be compiled. For each package, prerequisites are listed in one or more separate sections: Required, Recommended, and Optional.
These dependencies are the bare minimum needed to build the package. Packages in LFS, and the required dependencies of these required packages, are omitted from this list. Always remember to check for nested dependencies. If a dependency is said to be 「runtime」, then it is not needed for building the package, but only to use it after installation.
These are dependencies the BLFS editors have determined are important to give the package reasonable capabilities. If a recommended dependency is not said to be 「runtime」, package installation instructions assume it is installed. If it is not installed, the instructions may require modification, to accommodate the missing package. A recommended 「runtime」 dependency does not need to be installed before building the package, but must be built afterwards for running the package with reasonable capabilities.
These are dependencies the package may use. Integration of optional dependencies may be automatic by the package, or additional steps not presented by BLFS may be necessary. Optional dependencies are sometimes listed without explicit BLFS instructions. In this case you must determine how to perform the installation yourself.
Some packages require specific kernel configuration options. The general layout for these looks like this:
Master section ---> Subsection ---> [*] Required parameter [REQU_PAR] <*> Required parameter (not as module) [REQU_PAR_NMOD] <*/M> Required parameter (could be a module) [REQU_PAR_MOD] <M> Required parameter (as a module) [REQU_PAR_MOD_ONLY] < /*/M> Optional parameter [OPT_PAR] < /M> Optional parameter (as a module if enabled) [OPT_PAR_MOD_ONLY] [ ] Incompatible parameter [INCOMP_PAR] < > Incompatible parameter (even as module) [INCOMP_PAR_MOD]
[...] on the right gives the symbolic name of the option, so you
can easily check whether it is set in your .config
file. Note that the .config
file contains a CONFIG_
prefix before all symbolic names. The
meaning of the various entries is:
Master section top level menu item Subsection submenu item Required parameter the option can either be built-in, or not selected: it must be selected Required parameter (not as module) the option can be built-in, a module, or not selected (tri-state): it must be selected as built-in Required parameter (could be a module) the option can be built-in, a module, or not selected: it must be selected, either as built-in or as a module Required parameter (as a module) the option can be built-in, a module, or not selected: it must be selected as a module; selecting it as built-in may cause unwanted effects Optional parameter the option can be built-in, a module, or not selected: it may be selected as a module or built-in if you need it for driving the hardware or optional kernel features Optional parameter the option can be built-in, a module, or not selected: it may be selected as a module if you need it for driving the hardware or optional kernel features, but selecting it as built-in may cause unwanted effects Incompatible parameter the option can either be built-in or not selected: it must not be selected Incompatible parameter (even as module) the option can be built-in, a module, or not selected: it must not be selected
Note that, depending on other selections, the angle brackets (<>) in the configuration menu may appear as braces ({}) if the option cannot be unselected, or even as dashes (-*- or -M-), when the choice is imposed. The help text describing the option specifies the other selections on which this option relies, and how those other selections are set.
The letter in blue is the hotkey for this option. If you are running make menuconfig, you can press a key to quickly traverse all the options with this key as the hotkey on the screen.
As in LFS, each package in BLFS has a build time listed in Standard Build Units (SBUs). These times are relative to the time it took to build binutils in LFS, and are intended to provide some insight into how long it will take to build a package. Most times listed are for a single processor or core to build the package. In some cases, large, long running builds tested on multi-core systems have SBU times listed with comments such as '(parallelism=4)'. These values indicate testing was done using multiple cores. Note that while this speeds up the build on systems with the appropriate hardware, the speedup is not linear and to some extent depends on the individual package and the specific hardware used.
For packages which use ninja (i.e., anything using meson) or rust, by default all cores are used; similar comments will be seen on such packages even when the build time is minimal.
Where even a parallel build takes more than 15 SBU, on certain machines the time may be considerably greater even when the build does not use swap. In particular, different micro-architectures will build some files at different relative speeds, and this can introduce delays when certain make targets wait for another file to be created. Where a large build uses a lot of C++ files, processors with Simultaneous Multi Threading will share the Floating Point Unit and can take 45% longer than when using four 'prime' cores (measured on an intel i7 using taskset and keeping the other cores idle).
Some packages do not support parallel builds; for these, the make command must specify -j1. Packages that are known to impose such limits are so marked in the text.