[6370fa6] | 1 | <sect2>
|
---|
| 2 | <title>Installation of Glibc</title>
|
---|
| 3 |
|
---|
[ea57e1b] | 4 | <para>Before starting to install glibc, you must cd into the
|
---|
| 5 | glibc-&glibc-version; directory and unpack glibc-linuxthreads inside
|
---|
[be2942c] | 6 | the glibc-&glibc-version; directory, not in /usr/src as you normally
|
---|
[b822811] | 7 | would do.</para>
|
---|
[6370fa6] | 8 |
|
---|
[28360cb] | 9 | <para>This package is known to behave badly when you have changed its default
|
---|
[b43aab1] | 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 |
|
---|
[b822811] | 15 | <para>Install Glibc by running the following commands:</para>
|
---|
[6370fa6] | 16 |
|
---|
[ea57e1b] | 17 | <para><screen><userinput>mknod -m 0666 /dev/null c 1 3 &&</userinput>
|
---|
[3229c6b] | 18 | <userinput>touch /etc/ld.so.conf &&</userinput>
|
---|
[3acb38f] | 19 | <userinput>cp malloc/Makefile malloc/Makefile.backup &&</userinput>
|
---|
[99f6103] | 20 | <userinput>sed 's%\$(PERL)%/usr/bin/perl%' malloc/Makefile > tmp~ &&</userinput>
|
---|
[c3feda7] | 21 | <userinput>mv tmp~ malloc/Makefile &&</userinput>
|
---|
[3acb38f] | 22 | <userinput>cp login/Makefile login/Makefile.backup &&</userinput>
|
---|
[2fbf709] | 23 | <userinput>sed 's/root/0/' login/Makefile > tmp~ &&</userinput>
|
---|
[c3feda7] | 24 | <userinput>mv tmp~ login/Makefile &&</userinput>
|
---|
[be2942c] | 25 | <userinput>mkdir ../glibc-build &&</userinput>
|
---|
| 26 | <userinput>cd ../glibc-build &&</userinput>
|
---|
[99f6103] | 27 | <userinput>../glibc-&glibc-version;/configure --prefix=/usr \</userinput>
|
---|
[166f15a] | 28 | <userinput> --enable-add-ons --libexecdir=/usr/bin &&</userinput>
|
---|
[3acb38f] | 29 | <userinput>cp config.make config.make.backup &&</userinput>
|
---|
[8f5efb62] | 30 | <userinput>sed 's/cross-compiling = yes/cross-compiling = no/' \</userinput>
|
---|
[0cb331d] | 31 | <userinput> config.make > tmp~ &&</userinput>
|
---|
[c3feda7] | 32 | <userinput>mv tmp~ config.make &&</userinput>
|
---|
[3229c6b] | 33 | <userinput>make &&</userinput>
|
---|
| 34 | <userinput>make install &&</userinput>
|
---|
[463e888] | 35 | <userinput>make localedata/install-locales &&</userinput>
|
---|
[e5dc2d9] | 36 | <userinput>exec /bin/bash --login</userinput></screen></para>
|
---|
[6370fa6] | 37 |
|
---|
[951a2f5] | 38 | <para>An alternative to running <userinput>make
|
---|
[32f052f] | 39 | localedata/install-locales</userinput> is to only install those locales
|
---|
[951a2f5] | 40 | which you need or want. This can be achieved using the localedef
|
---|
| 41 | command. Information on this can be found in the INSTALL
|
---|
| 42 | file in the glibc-&glibc-version; tree.</para>
|
---|
| 43 |
|
---|
[b822811] | 44 | <para>During the configure stage you will see the following warning:</para>
|
---|
[0e347034] | 45 |
|
---|
[b822811] | 46 | <blockquote><screen>configure: warning:
|
---|
[2b1174be] | 47 | *** These auxiliary programs are missing or too old: msgfmt
|
---|
[0e347034] | 48 | *** some features will be disabled.
|
---|
[b822811] | 49 | *** Check the INSTALL file for required versions.</screen></blockquote>
|
---|
[0e347034] | 50 |
|
---|
[2b1174be] | 51 | <para>The missing msgfmt (from the gettext package which we will install
|
---|
| 52 | later in this chapter) is not fatal. The files msgfmt would create are
|
---|
| 53 | already pre-built, so you won't be missing out on anything. You would
|
---|
| 54 | only need it if you make changes to the Glibc manual files. Since we
|
---|
| 55 | don't do this by default, we can safely ignore it.</para>
|
---|
[0e347034] | 56 |
|
---|
[6370fa6] | 57 | </sect2>
|
---|
| 58 |
|
---|