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-boot-createfiles">
|
---|
9 | <?dbhtml filename="createfiles.html"?>
|
---|
10 |
|
---|
11 | <title>Creating Essential Symlinks</title>
|
---|
12 |
|
---|
13 | <para os="a">Some programs use hard-wired paths to programs which do not exist
|
---|
14 | yet. In order to satisfy these programs, create a number of symbolic
|
---|
15 | links which will be replaced by real files throughout the course of
|
---|
16 | the next chapter after the software has been installed.</para>
|
---|
17 |
|
---|
18 | <screen os="b"><userinput>ln -sv /tools/bin/{bash,cat,echo,grep,login,pwd,stty} ${CLFS}/bin
|
---|
19 | ln -sv /tools/bin/file ${CLFS}/usr/bin
|
---|
20 | ln -sv /tools/lib/libgcc_s.so{,.1} ${CLFS}/usr/lib
|
---|
21 | ln -sv /tools/lib/libstdc++.so{.6,} ${CLFS}/usr/lib
|
---|
22 | sed -e 's/tools/usr/' /tools/lib/libstdc++.la > ${CLFS}/usr/lib/libstdc++.la
|
---|
23 | ln -sv bash ${CLFS}/bin/sh
|
---|
24 | ln -sv ../run ${CLFS}/var/run
|
---|
25 | ln -sv /tools/sbin/{fsck.ext2,fsck.ext3,fsck.ext4,e2fsck} ${CLFS}/sbin
|
---|
26 | ln -sv /tools/sbin/init ${CLFS}/sbin
|
---|
27 | ln -sv /tools/etc/{login.{access,defs},limits} ${CLFS}/etc</userinput></screen>
|
---|
28 |
|
---|
29 | <para os="c">Historically, Linux maintains a list of the mounted file systems
|
---|
30 | in the file <filename>/etc/mtab</filename>. Modern kernels maintain this list
|
---|
31 | internally and expose it to the user via the
|
---|
32 | <filename class="directory">/proc</filename> filesystem. To satisfy utilities
|
---|
33 | that expect the presence of <filename>/etc/mtab</filename>, create the
|
---|
34 | following symbolic link:</para>
|
---|
35 |
|
---|
36 | <screen os="d"><userinput>ln -sv /proc/self/mounts ${CLFS}/etc/mtab</userinput></screen>
|
---|
37 |
|
---|
38 | </sect1>
|
---|