1 | <sect2>
|
---|
2 | <title>Installation of Glibc</title>
|
---|
3 |
|
---|
4 | <para>Before starting to install glibc, you must cd into the
|
---|
5 | glibc-&glibc-version; directory and unpack glibc-linuxthreads inside
|
---|
6 | the glibc-&glibc-version; directory, not in /usr/src as you normally
|
---|
7 | would do.</para>
|
---|
8 |
|
---|
9 | <para>This package is known to behave badly when you have changed its default
|
---|
10 | optimization flags (including the -march and -mcpu options). Glibc is
|
---|
11 | best left alone, so we recommend you unsetting CFLAGS, CXXFLAGS and other
|
---|
12 | such variables/settings that would change the default optimization that
|
---|
13 | it comes with.</para>
|
---|
14 |
|
---|
15 | <para>Install Glibc by running the following commands:</para>
|
---|
16 |
|
---|
17 | <para><screen><userinput>mknod -m 0666 /dev/null c 1 3 &&
|
---|
18 | touch /etc/ld.so.conf &&
|
---|
19 | cp malloc/Makefile malloc/Makefile.backup &&
|
---|
20 | sed 's%\$(PERL)%/usr/bin/perl%' malloc/Makefile.backup > malloc/Makefile &&
|
---|
21 | cp login/Makefile login/Makefile.backup &&
|
---|
22 | sed 's/root/0/' login/Makefile.backup > login/Makefile &&
|
---|
23 | mkdir ../glibc-build &&
|
---|
24 | cd ../glibc-build &&
|
---|
25 | ../glibc-&glibc-version;/configure --prefix=/usr \
|
---|
26 | --enable-add-ons --libexecdir=/usr/bin &&
|
---|
27 | cp config.make config.make.backup &&
|
---|
28 | sed 's/cross-compiling = yes/cross-compiling = no/' \
|
---|
29 | config.make.backup > config.make &&
|
---|
30 | make &&
|
---|
31 | make install &&
|
---|
32 | make localedata/install-locales &&
|
---|
33 | exec /bin/bash --login</userinput></screen></para>
|
---|
34 |
|
---|
35 | <para>An alternative to running <userinput>make
|
---|
36 | localedata/install-locales</userinput> is to only install those locales
|
---|
37 | which you need or want. This can be achieved using the localedef
|
---|
38 | command. Information on this can be found in the INSTALL
|
---|
39 | file in the glibc-&glibc-version; tree.</para>
|
---|
40 |
|
---|
41 | <para>During the configure stage you will see the following warning:</para>
|
---|
42 |
|
---|
43 | <blockquote><screen>configure: warning:
|
---|
44 | *** These auxiliary programs are missing or too old: msgfmt
|
---|
45 | *** some features will be disabled.
|
---|
46 | *** Check the INSTALL file for required versions.</screen></blockquote>
|
---|
47 |
|
---|
48 | <para>The missing msgfmt (from the gettext package which we will install
|
---|
49 | later in this chapter) is not fatal. The files msgfmt would create are
|
---|
50 | already pre-built, so you won't be missing out on anything. You would
|
---|
51 | only need it if you make changes to the Glibc manual files. Since we
|
---|
52 | don't do this by default, we can safely ignore it.</para>
|
---|
53 |
|
---|
54 | </sect2>
|
---|
55 |
|
---|