[6370fa6] | 1 | <sect2>
|
---|
| 2 | <title>Command explanations</title>
|
---|
| 3 |
|
---|
[b822811] | 4 | <para><userinput>mknod -m 0666 /dev/null c 1 3:</userinput> Glibc needs a
|
---|
[1242889] | 5 | null device to compile properly. All other devices will be created in the
|
---|
[b822811] | 6 | next section.</para>
|
---|
[1242889] | 7 |
|
---|
[9960acd] | 8 | <para><userinput>touch /etc/ld.so.conf</userinput> One of the final steps
|
---|
| 9 | of the Glibc installation is running ldconfig to update the dynamic loader
|
---|
| 10 | cache. If this file doesn't exist, the installation will abort with an error
|
---|
| 11 | that it can't read the file, so we simply create an empty file (the empty file
|
---|
[2b1174be] | 12 | will have Glibc default to using /lib and /usr/lib which is fine).</para>
|
---|
[4c70684] | 13 |
|
---|
[bccc288] | 14 | <para><userinput>sed 's%\$(PERL)%/usr/bin/perl%'
|
---|
[8c5e7152] | 15 | malloc/Makefile.backup > malloc/Makefile:</userinput> This sed command
|
---|
| 16 | searches through <filename>malloc/Makefile.backup</filename> and
|
---|
[51c0c603] | 17 | converts all occurrences of <filename>$(PERL)</filename> to
|
---|
[8c5e7152] | 18 | <filename>/usr/bin/perl</filename>. The output is then written to the
|
---|
| 19 | original <filename>malloc/Makefile.in</filename> which is used during
|
---|
| 20 | configuration. This is done because Glibc can't autodetect perl since
|
---|
| 21 | it hasn't been installed yet.</para>
|
---|
| 22 |
|
---|
| 23 | <para><userinput>sed 's/root/0' login/Makefile.backup >
|
---|
| 24 | login/Makefile:</userinput> This sed command replaces all occurences of
|
---|
| 25 | <filename>root</filename> in <filename>login/Makefile.backup</filename>
|
---|
| 26 | with 0. This is because we don't have glibc on the LFS system yet, so
|
---|
| 27 | usernames can't be resolved to their user id's. Therefore, we replace
|
---|
| 28 | the username root with user id 0.</para>
|
---|
[671561b] | 29 |
|
---|
[b822811] | 30 | <para><userinput>--enable-add-ons:</userinput> This enables the add-on that
|
---|
| 31 | we install with Glibc: linuxthreads</para>
|
---|
[6370fa6] | 32 |
|
---|
[166f15a] | 33 | <para><userinput>--libexecdir=/usr/bin:</userinput> This will cause the
|
---|
| 34 | pt_chown program to be installed in the /usr/bin directory.</para>
|
---|
| 35 |
|
---|
[94cb4444] | 36 | <para><userinput>echo "cross-compiling = no" > configparms:</userinput>
|
---|
| 37 | We do this because we are only building for our own system. Cross-compiling
|
---|
| 38 | is used, for instance, to build a package for an Apple Power PC on an
|
---|
| 39 | Intel system. The reason Glibc thinks we're cross-compiling is that it
|
---|
| 40 | can't compile a test program to determine this, so it automatically defaults
|
---|
| 41 | to a cross-compiler. Compiling the test program failes because Glibc hasn't
|
---|
| 42 | been installed yet.</para>
|
---|
[671561b] | 43 |
|
---|
[76a3d6d] | 44 | <para><userinput>exec /bin/bash:</userinput>This command will
|
---|
| 45 | start a new bash shell which will replace the current shell. This is
|
---|
| 46 | done to get rid of the "I have no name!" message in the command
|
---|
| 47 | prompt, which was caused by bash's inability to resolve a userid to
|
---|
| 48 | a username (which in turn was caused by the missing Glibc
|
---|
| 49 | installation).</para>
|
---|
| 50 |
|
---|
[6370fa6] | 51 | </sect2>
|
---|
| 52 |
|
---|