[7152faa] | 1 | <?xml version="1.0" encoding="UTF-8"?>
|
---|
[b06ca36] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
[673b0d8] | 4 | <!ENTITY % general-entities SYSTEM "../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 | ]>
|
---|
[6a82dd9] | 7 |
|
---|
[81fd230] | 8 | <sect1 id="ch-system-glibc" role="wrap">
|
---|
[6a82dd9] | 9 | <?dbhtml filename="glibc.html"?>
|
---|
| 10 |
|
---|
[e747759] | 11 | <sect1info condition="script">
|
---|
| 12 | <productname>glibc</productname>
|
---|
| 13 | <productnumber>&glibc-version;</productnumber>
|
---|
| 14 | <address>&glibc-url;</address>
|
---|
| 15 | </sect1info>
|
---|
| 16 |
|
---|
[6a82dd9] | 17 | <title>Glibc-&glibc-version;</title>
|
---|
| 18 |
|
---|
| 19 | <indexterm zone="ch-system-glibc">
|
---|
| 20 | <primary sortas="a-Glibc">Glibc</primary>
|
---|
| 21 | </indexterm>
|
---|
| 22 |
|
---|
| 23 | <sect2 role="package">
|
---|
| 24 | <title/>
|
---|
| 25 |
|
---|
| 26 | <para>The Glibc package contains the main C library. This library provides
|
---|
| 27 | the basic routines for allocating memory, searching directories, opening and
|
---|
| 28 | closing files, reading and writing files, string handling, pattern matching,
|
---|
| 29 | arithmetic, and so on.</para>
|
---|
| 30 |
|
---|
| 31 | <segmentedlist>
|
---|
| 32 | <segtitle>&buildtime;</segtitle>
|
---|
| 33 | <segtitle>&diskspace;</segtitle>
|
---|
| 34 |
|
---|
| 35 | <seglistitem>
|
---|
[6dfcfecc] | 36 | <seg>&glibc-fin-sbu;</seg>
|
---|
| 37 | <seg>&glibc-fin-du;</seg>
|
---|
[6a82dd9] | 38 | </seglistitem>
|
---|
| 39 | </segmentedlist>
|
---|
| 40 |
|
---|
| 41 | </sect2>
|
---|
| 42 |
|
---|
| 43 | <sect2 role="installation">
|
---|
| 44 | <title>Installation of Glibc</title>
|
---|
[12836f5] | 45 |
|
---|
[725ef3b] | 46 | <para>Some of the Glibc programs use the non-FHS compliant
|
---|
[4028929] | 47 | <filename class="directory">/var/db</filename> directory to store
|
---|
| 48 | their runtime data. Apply the following patch to make such programs
|
---|
| 49 | store their runtime data in the FHS-compliant locations:</para>
|
---|
| 50 |
|
---|
| 51 | <screen><userinput remap="pre">patch -Np1 -i ../&glibc-fhs-patch;</userinput></screen>
|
---|
[092b86a] | 52 | <!--
|
---|
[efd1113] | 53 | <para>Now fix two security vulnerabilities and a regression causing the
|
---|
| 54 | posix_memalign() function very slow in some conditions:</para>
|
---|
[f7d3b6e] | 55 |
|
---|
[efd1113] | 56 | <screen><userinput remap="pre">patch -Np1 -i ../&glibc-upstream-fixes-patch;</userinput></screen>
|
---|
[092b86a] | 57 | -->
|
---|
[d672ab7] | 58 | <para>The Glibc documentation recommends building Glibc
|
---|
[f1dd547] | 59 | in a dedicated build directory:</para>
|
---|
[73aedd1d] | 60 |
|
---|
[f1dd547] | 61 | <screen><userinput remap="pre">mkdir -v build
|
---|
| 62 | cd build</userinput></screen>
|
---|
[c906b7e] | 63 |
|
---|
[4eee9cc] | 64 | <para>Ensure that the <command>ldconfig</command> and <command>sln</command>
|
---|
[bcb20b4] | 65 | utilities will be installed into
|
---|
[4eee9cc] | 66 | <filename class="directory">/usr/sbin</filename>:</para>
|
---|
| 67 |
|
---|
| 68 | <screen><userinput remap="pre">echo "rootsbindir=/usr/sbin" > configparms</userinput></screen>
|
---|
| 69 |
|
---|
[6a82dd9] | 70 | <para>Prepare Glibc for compilation:</para>
|
---|
[73aedd1d] | 71 |
|
---|
[6dfcfecc] | 72 | <screen arch="default"><userinput remap="configure">../configure --prefix=/usr \
|
---|
| 73 | --disable-werror \
|
---|
[0f18f2b] | 74 | --enable-kernel=&min-kernel; \
|
---|
[6dfcfecc] | 75 | --enable-stack-protector=strong \
|
---|
[25b3c0f] | 76 | --disable-nscd \
|
---|
[d4b5218] | 77 | libc_cv_slibdir=/usr/lib</userinput></screen>
|
---|
[6dfcfecc] | 78 | <screen arch="ml_32,ml_x32,ml_all"><userinput remap="configure">../configure --prefix=/usr \
|
---|
| 79 | --disable-werror \
|
---|
| 80 | --enable-kernel=&min-kernel; \
|
---|
| 81 | --enable-stack-protector=strong \
|
---|
| 82 | --with-headers=/usr/include \
|
---|
| 83 | --enable-multi-arch \
|
---|
[d4b5218] | 84 | libc_cv_slibdir=/usr/lib</userinput></screen>
|
---|
[73aedd1d] | 85 |
|
---|
[6dfcfecc] | 86 | <variablelist>
|
---|
| 87 | <title>The meaning of the configure options:</title>
|
---|
[0967c90] | 88 |
|
---|
| 89 | <varlistentry>
|
---|
[6dfcfecc] | 90 | <term><parameter>--disable-werror</parameter></term>
|
---|
[0967c90] | 91 | <listitem>
|
---|
[d672ab7] | 92 | <para>This option disables the -Werror option passed to
|
---|
[6dfcfecc] | 93 | GCC. This is necessary for running the test suite.</para>
|
---|
[0967c90] | 94 | </listitem>
|
---|
| 95 | </varlistentry>
|
---|
[5897639] | 96 |
|
---|
| 97 | <varlistentry>
|
---|
[6dfcfecc] | 98 | <term><parameter>--enable-kernel=&min-kernel;</parameter></term>
|
---|
[5897639] | 99 | <listitem>
|
---|
[091d624d] | 100 | <para>This option tells the build system that this Glibc may
|
---|
[6dfcfecc] | 101 | be used with kernels as old as &min-kernel;. This means generating
|
---|
| 102 | workarounds in case a system call introduced in a later version
|
---|
| 103 | cannot be used.</para>
|
---|
[5897639] | 104 | </listitem>
|
---|
| 105 | </varlistentry>
|
---|
| 106 |
|
---|
| 107 | <varlistentry>
|
---|
| 108 | <term><parameter>--enable-stack-protector=strong</parameter></term>
|
---|
| 109 | <listitem>
|
---|
[d672ab7] | 110 | <para>This option increases system security by adding
|
---|
[0d84af1] | 111 | extra code to check for buffer overflows, such as stack
|
---|
[bed3894] | 112 | smashing attacks. Note that Glibc always explicitly overrides
|
---|
| 113 | the default of GCC, so this option is still needed even though
|
---|
| 114 | we've already specified <option>--enable-default-ssp</option> for
|
---|
| 115 | GCC.</para>
|
---|
[6702623] | 116 | </listitem>
|
---|
| 117 | </varlistentry>
|
---|
| 118 |
|
---|
[25b3c0f] | 119 | <varlistentry>
|
---|
| 120 | <term><parameter>--disable-nscd</parameter></term>
|
---|
| 121 | <listitem>
|
---|
| 122 | <para>Do not build the name service cache daemon which is no
|
---|
| 123 | longer used.</para>
|
---|
| 124 | </listitem>
|
---|
| 125 | </varlistentry>
|
---|
| 126 |
|
---|
[5897639] | 127 | <varlistentry>
|
---|
[d7a9421] | 128 | <term><parameter>libc_cv_slibdir=/usr/lib</parameter></term>
|
---|
[5897639] | 129 | <listitem>
|
---|
| 130 | <para>This variable sets the correct library for all
|
---|
| 131 | systems. We do not want lib64 to be used.</para>
|
---|
| 132 | </listitem>
|
---|
| 133 | </varlistentry>
|
---|
| 134 |
|
---|
| 135 | </variablelist>
|
---|
| 136 |
|
---|
[6a82dd9] | 137 | <para>Compile the package:</para>
|
---|
[73aedd1d] | 138 |
|
---|
[0445a3d] | 139 | <screen><userinput remap="make">make</userinput></screen>
|
---|
[73aedd1d] | 140 |
|
---|
[6a82dd9] | 141 | <important>
|
---|
| 142 | <para>In this section, the test suite for Glibc is considered critical.
|
---|
| 143 | Do not skip it under any circumstance.</para>
|
---|
| 144 | </important>
|
---|
[81fd230] | 145 |
|
---|
[0d84af1] | 146 | <para>Generally a few tests do not pass. The test failures listed below
|
---|
| 147 | are usually safe to ignore.</para>
|
---|
[d9c836bb] | 148 |
|
---|
[082bbce] | 149 | <!-- Use remap="make" here to work around a jhalfs issue. -->
|
---|
[9da9d014] | 150 | <!--<screen><userinput remap="make">case $(uname -m) in
|
---|
[1b3fac7] | 151 | i?86) ln -sfnv $PWD/elf/ld-linux.so.2 /lib ;;
|
---|
| 152 | x86_64) ln -sfnv $PWD/elf/ld-linux-x86-64.so.2 /lib ;;
|
---|
[082bbce] | 153 | esac</userinput></screen>
|
---|
[2e02c35] | 154 |
|
---|
[70b235f4] | 155 | <note><para>The symbolic link above is needed to run the tests at this
|
---|
[d7f58cc] | 156 | stage of building in the chroot environment. It will be overwritten
|
---|
[70b235f4] | 157 | in the install phase below.</para></note>
|
---|
[9da9d014] | 158 | -->
|
---|
[082bbce] | 159 | <screen><userinput remap="test">make check</userinput></screen>
|
---|
| 160 |
|
---|
[58ccce5] | 161 | <para>You may see some test failures. The Glibc test suite is
|
---|
| 162 | somewhat dependent on the host system. A few failures out of
|
---|
[3bac16dc] | 163 | over 5000 tests can generally be ignored. This is a list of the
|
---|
[58ccce5] | 164 | most common issues seen for recent versions of LFS:</para>
|
---|
[6a82dd9] | 165 |
|
---|
| 166 | <itemizedlist>
|
---|
[5d1f0157] | 167 |
|
---|
[032dc4e8] | 168 | <listitem>
|
---|
[d672ab7] | 169 | <para><emphasis>io/tst-lchmod</emphasis>
|
---|
[032dc4e8] | 170 | is known to fail in the LFS chroot environment.</para>
|
---|
| 171 | </listitem>
|
---|
| 172 |
|
---|
[582da16] | 173 | <listitem>
|
---|
[0c0b882] | 174 | <para>Some tests, for example
|
---|
[0800455] | 175 | <emphasis>nss/tst-nss-files-hosts-multi</emphasis> and
|
---|
| 176 | <emphasis>nptl/tst-thread-affinity*</emphasis>
|
---|
| 177 | are known to fail due to a timeout (especially when the system is
|
---|
| 178 | relatively slow and/or running the test suite with multiple
|
---|
| 179 | parallel make jobs). These tests can be identified with:</para>
|
---|
| 180 |
|
---|
| 181 | <!-- TODO: Using nodump for freeze. Change it to role="test" after
|
---|
| 182 | 12.1 release so jhalfs can list these in the log. -->
|
---|
| 183 | <screen role="nodump"><userinput>grep "Timed out" -l $(find -name \*.out)</userinput></screen>
|
---|
| 184 |
|
---|
| 185 | <para>It's possible to re-run a single test with enlarged timeout
|
---|
| 186 | with
|
---|
| 187 | <command>TIMEOUTFACTOR=<replaceable><factor></replaceable>
|
---|
| 188 | make test t=<replaceable><test name></replaceable></command>.
|
---|
| 189 | For example, <command>TIMEOUTFACTOR=10 make test
|
---|
| 190 | t=nss/tst-nss-files-hosts-multi</command> will re-run
|
---|
| 191 | <emphasis>nss/tst-nss-files-hosts-multi</emphasis> with ten times
|
---|
| 192 | the original timeout.</para>
|
---|
[de6905d] | 193 | </listitem>
|
---|
[c500323] | 194 |
|
---|
[d9c836bb] | 195 | <listitem>
|
---|
[8287b51] | 196 | <para>Additionally, some tests may fail with a relatively old CPU
|
---|
[0800455] | 197 | model (for example
|
---|
| 198 | <emphasis>elf/tst-cpu-features-cpuinfo</emphasis>) or host kernel
|
---|
| 199 | version (for example
|
---|
| 200 | <emphasis>stdlib/tst-arc4random-thread</emphasis>).</para>
|
---|
[6a82dd9] | 201 | </listitem>
|
---|
| 202 | </itemizedlist>
|
---|
| 203 |
|
---|
| 204 | <para>Though it is a harmless message, the install stage of Glibc will
|
---|
| 205 | complain about the absence of <filename>/etc/ld.so.conf</filename>.
|
---|
| 206 | Prevent this warning with:</para>
|
---|
[1caa48e] | 207 |
|
---|
[0445a3d] | 208 | <screen><userinput remap="install">touch /etc/ld.so.conf</userinput></screen>
|
---|
[1caa48e] | 209 |
|
---|
[a3bd4689] | 210 | <!-- https://sourceware.org/bugzilla/show_bug.cgi?id=21911 -->
|
---|
| 211 | <para>Fix the Makefile to skip an outdated sanity check
|
---|
| 212 | that fails with a modern Glibc configuration:</para>
|
---|
[ffbeb5f] | 213 |
|
---|
| 214 | <screen><userinput remap="install">sed '/test-installation/s@$(PERL)@echo not running@' -i ../Makefile</userinput></screen>
|
---|
| 215 |
|
---|
[343ab13] | 216 | <important>
|
---|
| 217 | <para>
|
---|
| 218 | If upgrading Glibc to a new minor version (for example, from
|
---|
| 219 | Glibc-2.36 to Glibc-&glibc-version;) on a running LFS system, you
|
---|
| 220 | need to take some extra precautions to avoid breaking the system:
|
---|
| 221 | </para>
|
---|
| 222 |
|
---|
| 223 | <itemizedlist>
|
---|
| 224 | <listitem>
|
---|
| 225 | <!-- There are two reasons we don't support this:
|
---|
| 226 | 1. Upgrading on a system with separate /lib and /usr/lib is
|
---|
| 227 | tricky.
|
---|
| 228 | 2. With Glibc prior to 2.34 libc.so.6 etc. are symlinks to
|
---|
| 229 | libc-2.33.so etc., again causing the upgradation tricky.
|
---|
| 230 | The Glibc NEWS file explicit states they no longer use
|
---|
| 231 | symlinks for the ABI names to avoid upgradation
|
---|
| 232 | issues. -->
|
---|
| 233 | <para>
|
---|
| 234 | Upgrading Glibc on a LFS system prior to 11.0 (exclusive) is
|
---|
| 235 | not supported. Rebuild LFS if you are running such an old LFS
|
---|
| 236 | system but you need a newer Glibc.
|
---|
| 237 | </para>
|
---|
| 238 | </listitem>
|
---|
| 239 |
|
---|
| 240 | <!-- https://sourceware.org/pipermail/libc-alpha/2024-January/154095.html -->
|
---|
| 241 | <listitem>
|
---|
| 242 | <para>
|
---|
| 243 | If upgrading on a LFS system prior to 12.0 (exclusive), install
|
---|
| 244 | <application>Libxcrypt</application> following
|
---|
| 245 | <xref role='.' linkend='ch-system-libxcrypt'/> In addition to
|
---|
| 246 | a normal <application>Libxcrypt</application> installation,
|
---|
| 247 | <emphasis role='bold'>you MUST follow the note in Libxcrypt
|
---|
| 248 | section to install
|
---|
| 249 | <filename class='libraryfile'>libcrypt.so.1*</filename>
|
---|
| 250 | (overwritting
|
---|
| 251 | <filename class='libraryfile'>libcrypt.so.1</filename> from the
|
---|
| 252 | prior Glibc installation)</emphasis>.
|
---|
| 253 | </para>
|
---|
| 254 | </listitem>
|
---|
| 255 |
|
---|
| 256 | <!-- Otherwise on lfs-systemd nscd will fail to start on boot,
|
---|
| 257 | and on both lfs-sysv and lfs-systemd useradd etc. will try
|
---|
| 258 | to start nscd, then nscd will fail to start as well and
|
---|
| 259 | produce some spurious error message. -->
|
---|
| 260 | <listitem>
|
---|
| 261 | <para>
|
---|
| 262 | If upgrading on a LFS system prior to 12.1 (exclusive),
|
---|
| 263 | remove the <command>nscd</command> program:
|
---|
| 264 | </para>
|
---|
| 265 |
|
---|
| 266 | <screen role='nodump'><userinput>rm -f /usr/sbin/nscd</userinput></screen>
|
---|
| 267 |
|
---|
| 268 | <para>
|
---|
| 269 | If this system (prior to LFS 12.1, exclusive) is based on
|
---|
| 270 | Systemd, it's also needed to disable and stop the
|
---|
| 271 | <command>nscd</command> service now:
|
---|
| 272 | </para>
|
---|
| 273 |
|
---|
| 274 | <screen revision='systemd' role='nodump'><userinput>systemctl disable --now nscd</userinput></screen>
|
---|
| 275 | </listitem>
|
---|
| 276 |
|
---|
| 277 | <listitem>
|
---|
| 278 | <para>
|
---|
| 279 | Upgrade the kernel and reboot if it's older than &min-kernel;
|
---|
| 280 | (check the current version with <command>uname -r</command>)
|
---|
| 281 | or if you want to upgrade it anyway, following
|
---|
| 282 | <xref linkend='ch-bootable-kernel' role='.'/>
|
---|
| 283 | </para>
|
---|
| 284 | </listitem>
|
---|
| 285 |
|
---|
| 286 | <listitem>
|
---|
| 287 | <para>
|
---|
| 288 | Upgrade the kernel API headers if it's older than &min-kernel;
|
---|
| 289 | (check the current version with
|
---|
| 290 | <command>cat /usr/include/linux/version.h</command>)
|
---|
| 291 | or if you want to upgrade it anyway, following
|
---|
| 292 | <xref linkend='ch-tools-linux-headers'/> (but removing
|
---|
| 293 | <envar>$LFS</envar> from the <command>cp</command> command).
|
---|
| 294 | </para>
|
---|
| 295 | </listitem>
|
---|
| 296 |
|
---|
| 297 | <!-- This is to ensure we don't start a process at the time point
|
---|
| 298 | where some Glibc shared libraries are updated but the others
|
---|
| 299 | are not. Such mismatches can cause programs crash on startup,
|
---|
| 300 | esp. a mismatch between ld-linux-x86-64.so.2 and
|
---|
| 301 | libc.so.6. Note that a crash in the installation process
|
---|
| 302 | will leave the system in a state with the mismatch forever,
|
---|
| 303 | unrecoverable without the help of another distro. -->
|
---|
| 304 | <listitem>
|
---|
| 305 | <para>
|
---|
| 306 | Perform a <envar>DESTDIR</envar> installation and upgrade
|
---|
| 307 | the Glibc shared libraries on the system using one single
|
---|
| 308 | <command>install</command> command:
|
---|
| 309 | </para>
|
---|
| 310 |
|
---|
| 311 | <screen role='nodump'><userinput>make DESTDIR=$PWD/dest install
|
---|
| 312 | install -vm755 dest/usr/lib/*.so.* /usr/lib</userinput></screen>
|
---|
| 313 | </listitem>
|
---|
| 314 | </itemizedlist>
|
---|
| 315 |
|
---|
| 316 | <para>
|
---|
| 317 | It's imperative to strictly follow these steps above unless you
|
---|
| 318 | completely understand what you are doing.
|
---|
| 319 | <emphasis role='bold'>Any unexpected deviation may render the
|
---|
| 320 | system completely unusable. YOU ARE WARNED.</emphasis>
|
---|
| 321 | </para>
|
---|
| 322 |
|
---|
| 323 | <para>
|
---|
[677f795] | 324 | Then continue to run the <command>make install</command> command,
|
---|
| 325 | the <command>sed</command> command against
|
---|
| 326 | <filename>/usr/bin/ldd</filename>, and the commands to install
|
---|
| 327 | the locales. Once they are finished, reboot the system
|
---|
| 328 | immediately.
|
---|
[343ab13] | 329 | </para>
|
---|
| 330 | </important>
|
---|
| 331 |
|
---|
[6a82dd9] | 332 | <para>Install the package:</para>
|
---|
[73aedd1d] | 333 |
|
---|
[0445a3d] | 334 | <screen><userinput remap="install">make install</userinput></screen>
|
---|
[73aedd1d] | 335 |
|
---|
[091d624d] | 336 | <para>Fix a hardcoded path to the executable loader in the
|
---|
[0ebda11] | 337 | <command>ldd</command> script:</para>
|
---|
| 338 |
|
---|
| 339 | <screen><userinput remap="install">sed '/RTLDLIST=/s@/usr@@g' -i /usr/bin/ldd</userinput></screen>
|
---|
[25b3c0f] | 340 | <!--
|
---|
[4028929] | 341 | <para>Install the configuration file and runtime directory for
|
---|
| 342 | <command>nscd</command>:</para>
|
---|
| 343 |
|
---|
[f1dd547] | 344 | <screen><userinput remap="install">cp -v ../nscd/nscd.conf /etc/nscd.conf
|
---|
[4028929] | 345 | mkdir -pv /var/cache/nscd</userinput></screen>
|
---|
| 346 |
|
---|
[d672ab7] | 347 | <para revision="systemd">Install the systemd support files for
|
---|
[1118b17] | 348 | <command>nscd</command>:</para>
|
---|
| 349 |
|
---|
| 350 | <screen revision="systemd"><userinput remap="install">install -v -Dm644 ../nscd/nscd.tmpfiles /usr/lib/tmpfiles.d/nscd.conf
|
---|
[d7a9421] | 351 | install -v -Dm644 ../nscd/nscd.service /usr/lib/systemd/system/nscd.service</userinput></screen>
|
---|
[25b3c0f] | 352 | -->
|
---|
[d730742] | 353 | <para>Next, install the locales that can make the system respond in a
|
---|
[091d624d] | 354 | different language. None of these locales are required, but if some of them
|
---|
| 355 | are missing, the test suites of some packages will skip important
|
---|
| 356 | test cases.</para>
|
---|
[6a82dd9] | 357 |
|
---|
| 358 | <para>Individual locales can be installed using the
|
---|
[a5d31dd] | 359 | <command>localedef</command> program. E.g., the second
|
---|
[6a82dd9] | 360 | <command>localedef</command> command below combines the
|
---|
[fffccab] | 361 | <filename>/usr/share/i18n/locales/cs_CZ</filename>
|
---|
[6a82dd9] | 362 | charset-independent locale definition with the
|
---|
[fffccab] | 363 | <filename>/usr/share/i18n/charmaps/UTF-8.gz</filename>
|
---|
[6a82dd9] | 364 | charmap definition and appends the result to the
|
---|
| 365 | <filename>/usr/lib/locale/locale-archive</filename> file.
|
---|
| 366 | The following instructions will install the minimum set of
|
---|
| 367 | locales necessary for the optimal coverage of tests:</para>
|
---|
[3f0c882] | 368 |
|
---|
[0445a3d] | 369 | <screen role="nodump"><userinput remap="locale-test">mkdir -pv /usr/lib/locale
|
---|
[f1370e2] | 370 | localedef -i C -f UTF-8 C.UTF-8
|
---|
[1e77f0c] | 371 | localedef -i cs_CZ -f UTF-8 cs_CZ.UTF-8
|
---|
[73aedd1d] | 372 | localedef -i de_DE -f ISO-8859-1 de_DE
|
---|
| 373 | localedef -i de_DE@euro -f ISO-8859-15 de_DE@euro
|
---|
[1e77f0c] | 374 | localedef -i de_DE -f UTF-8 de_DE.UTF-8
|
---|
[75828c3] | 375 | localedef -i el_GR -f ISO-8859-7 el_GR
|
---|
[cefe505] | 376 | localedef -i en_GB -f ISO-8859-1 en_GB
|
---|
[e9aabce] | 377 | localedef -i en_GB -f UTF-8 en_GB.UTF-8
|
---|
[73aedd1d] | 378 | localedef -i en_HK -f ISO-8859-1 en_HK
|
---|
| 379 | localedef -i en_PH -f ISO-8859-1 en_PH
|
---|
| 380 | localedef -i en_US -f ISO-8859-1 en_US
|
---|
[3a35b11] | 381 | localedef -i en_US -f UTF-8 en_US.UTF-8
|
---|
[cefe505] | 382 | localedef -i es_ES -f ISO-8859-15 es_ES@euro
|
---|
[73aedd1d] | 383 | localedef -i es_MX -f ISO-8859-1 es_MX
|
---|
[673b0d8] | 384 | localedef -i fa_IR -f UTF-8 fa_IR
|
---|
[73aedd1d] | 385 | localedef -i fr_FR -f ISO-8859-1 fr_FR
|
---|
| 386 | localedef -i fr_FR@euro -f ISO-8859-15 fr_FR@euro
|
---|
[d93d1c90] | 387 | localedef -i fr_FR -f UTF-8 fr_FR.UTF-8
|
---|
[cefe505] | 388 | localedef -i is_IS -f ISO-8859-1 is_IS
|
---|
| 389 | localedef -i is_IS -f UTF-8 is_IS.UTF-8
|
---|
[73aedd1d] | 390 | localedef -i it_IT -f ISO-8859-1 it_IT
|
---|
[cefe505] | 391 | localedef -i it_IT -f ISO-8859-15 it_IT@euro
|
---|
[5b36d32] | 392 | localedef -i it_IT -f UTF-8 it_IT.UTF-8
|
---|
[1e77f0c] | 393 | localedef -i ja_JP -f EUC-JP ja_JP
|
---|
[8dd179b] | 394 | localedef -i ja_JP -f SHIFT_JIS ja_JP.SJIS 2> /dev/null || true
|
---|
[74f027f] | 395 | localedef -i ja_JP -f UTF-8 ja_JP.UTF-8
|
---|
[cefe505] | 396 | localedef -i nl_NL@euro -f ISO-8859-15 nl_NL@euro
|
---|
[5b36d32] | 397 | localedef -i ru_RU -f KOI8-R ru_RU.KOI8-R
|
---|
| 398 | localedef -i ru_RU -f UTF-8 ru_RU.UTF-8
|
---|
[cefe505] | 399 | localedef -i se_NO -f UTF-8 se_NO.UTF-8
|
---|
| 400 | localedef -i ta_IN -f UTF-8 ta_IN.UTF-8
|
---|
[fffccab] | 401 | localedef -i tr_TR -f UTF-8 tr_TR.UTF-8
|
---|
[75828c3] | 402 | localedef -i zh_CN -f GB18030 zh_CN.GB18030
|
---|
[cefe505] | 403 | localedef -i zh_HK -f BIG5-HKSCS zh_HK.BIG5-HKSCS
|
---|
| 404 | localedef -i zh_TW -f UTF-8 zh_TW.UTF-8</userinput></screen>
|
---|
[73aedd1d] | 405 |
|
---|
[6a82dd9] | 406 | <para>In addition, install the locale for your own country, language and
|
---|
| 407 | character set.</para>
|
---|
[fa21b3d] | 408 |
|
---|
[091d624d] | 409 | <para>Alternatively, install all the locales listed in the
|
---|
[6a82dd9] | 410 | <filename>glibc-&glibc-version;/localedata/SUPPORTED</filename> file
|
---|
| 411 | (it includes every locale listed above and many more) at once with the
|
---|
| 412 | following time-consuming command:</para>
|
---|
[fa21b3d] | 413 |
|
---|
[0445a3d] | 414 | <screen><userinput remap="locale-full">make localedata/install-locales</userinput></screen>
|
---|
[fa21b3d] | 415 |
|
---|
[6a82dd9] | 416 | <para>Then use the <command>localedef</command> command to create and
|
---|
| 417 | install locales not listed in the
|
---|
| 418 | <filename>glibc-&glibc-version;/localedata/SUPPORTED</filename> file
|
---|
[49e360b9] | 419 | when you need them. For instance, the following two locales are
|
---|
| 420 | needed for some tests later in this chapter:</para>
|
---|
[d672ab7] | 421 |
|
---|
[fecc287] | 422 | <screen role="nodump"><userinput remap="locale-full">localedef -i C -f UTF-8 C.UTF-8
|
---|
[8dd179b] | 423 | localedef -i ja_JP -f SHIFT_JIS ja_JP.SJIS 2> /dev/null || true</userinput></screen>
|
---|
[6a82dd9] | 424 |
|
---|
[d672ab7] | 425 | <note><para>Glibc now uses libidn2 when resolving internationalized
|
---|
[3b03219] | 426 | domain names. This is a run time dependency. If this capability
|
---|
[d672ab7] | 427 | is needed, the instructions for installing libidn2 are in the
|
---|
[3b03219] | 428 | <ulink url="&blfs-book;general/libidn2.html">BLFS libidn2 page</ulink>.
|
---|
| 429 | </para></note>
|
---|
| 430 |
|
---|
[6a82dd9] | 431 | </sect2>
|
---|
[94aa6621] | 432 |
|
---|
[6a82dd9] | 433 | <sect2 id="conf-glibc" role="configuration">
|
---|
| 434 | <title>Configuring Glibc</title>
|
---|
[5888299] | 435 |
|
---|
[6a82dd9] | 436 | <indexterm zone="conf-glibc">
|
---|
| 437 | <primary sortas="e-/etc/nsswitch.conf">/etc/nsswitch.conf</primary>
|
---|
| 438 | </indexterm>
|
---|
[81fd230] | 439 |
|
---|
[6a82dd9] | 440 | <indexterm zone="conf-glibc">
|
---|
| 441 | <primary sortas="e-/etc/localtime">/etc/localtime</primary>
|
---|
| 442 | </indexterm>
|
---|
[342b176] | 443 |
|
---|
[a72ca33] | 444 | <sect3>
|
---|
| 445 | <title>Adding nsswitch.conf</title>
|
---|
| 446 |
|
---|
[6a82dd9] | 447 | <para>The <filename>/etc/nsswitch.conf</filename> file needs to be created
|
---|
[a72ca33] | 448 | because the Glibc defaults do not work well in a networked environment.
|
---|
| 449 | </para>
|
---|
[6a82dd9] | 450 |
|
---|
| 451 | <para>Create a new file <filename>/etc/nsswitch.conf</filename> by running the
|
---|
| 452 | following:</para>
|
---|
[342b176] | 453 |
|
---|
[ba40e32] | 454 | <screen revision='sysv'><userinput>cat > /etc/nsswitch.conf << "EOF"
|
---|
[d72e04a] | 455 | <literal># Begin /etc/nsswitch.conf
|
---|
[342b176] | 456 |
|
---|
| 457 | passwd: files
|
---|
| 458 | group: files
|
---|
| 459 | shadow: files
|
---|
| 460 |
|
---|
| 461 | hosts: files dns
|
---|
| 462 | networks: files
|
---|
| 463 |
|
---|
[4a80bec] | 464 | protocols: files
|
---|
| 465 | services: files
|
---|
| 466 | ethers: files
|
---|
| 467 | rpc: files
|
---|
[342b176] | 468 |
|
---|
[ba40e32] | 469 | # End /etc/nsswitch.conf</literal>
|
---|
| 470 | EOF</userinput></screen>
|
---|
| 471 |
|
---|
| 472 | <screen revision='systemd'><userinput>cat > /etc/nsswitch.conf << "EOF"
|
---|
| 473 | <literal># Begin /etc/nsswitch.conf
|
---|
| 474 |
|
---|
| 475 | passwd: files systemd
|
---|
| 476 | group: files systemd
|
---|
| 477 | shadow: files systemd
|
---|
| 478 |
|
---|
| 479 | hosts: mymachines resolve [!UNAVAIL=return] files myhostname dns
|
---|
| 480 | networks: files
|
---|
| 481 |
|
---|
| 482 | protocols: files
|
---|
| 483 | services: files
|
---|
| 484 | ethers: files
|
---|
| 485 | rpc: files
|
---|
| 486 |
|
---|
[d72e04a] | 487 | # End /etc/nsswitch.conf</literal>
|
---|
[bb55064] | 488 | EOF</userinput></screen>
|
---|
[342b176] | 489 |
|
---|
[a72ca33] | 490 | </sect3>
|
---|
| 491 |
|
---|
| 492 | <sect3>
|
---|
[091d624d] | 493 | <title>Adding Time Zone Data</title>
|
---|
[a72ca33] | 494 |
|
---|
[edbeeb5] | 495 | <para>Install and set up the time zone data with the following:</para>
|
---|
[f1dd547] | 496 | <screen><userinput>tar -xf ../../tzdata&tzdata-version;.tar.gz
|
---|
[f1c177f] | 497 |
|
---|
[ea31e92] | 498 | ZONEINFO=/usr/share/zoneinfo
|
---|
[2ca8941] | 499 | mkdir -pv $ZONEINFO/{posix,right}
|
---|
[ea31e92] | 500 |
|
---|
| 501 | for tz in etcetera southamerica northamerica europe africa antarctica \
|
---|
[fb95c5c] | 502 | asia australasia backward; do
|
---|
[082bbce] | 503 | zic -L /dev/null -d $ZONEINFO ${tz}
|
---|
| 504 | zic -L /dev/null -d $ZONEINFO/posix ${tz}
|
---|
| 505 | zic -L leapseconds -d $ZONEINFO/right ${tz}
|
---|
[287a36b4] | 506 | done
|
---|
[f0f7ea0] | 507 |
|
---|
[f1d755b] | 508 | cp -v zone.tab zone1970.tab iso3166.tab $ZONEINFO
|
---|
[ea31e92] | 509 | zic -d $ZONEINFO -p America/New_York
|
---|
| 510 | unset ZONEINFO</userinput></screen>
|
---|
[f1c177f] | 511 |
|
---|
[7a6bcf9] | 512 | <variablelist>
|
---|
| 513 | <title>The meaning of the zic commands:</title>
|
---|
| 514 |
|
---|
| 515 | <varlistentry>
|
---|
| 516 | <term><parameter>zic -L /dev/null ...</parameter></term>
|
---|
| 517 | <listitem>
|
---|
[6dfcfecc] | 518 | <para>This creates posix time zones without any leap seconds. It is
|
---|
[7a6bcf9] | 519 | conventional to put these in both
|
---|
| 520 | <filename class="directory">zoneinfo</filename> and
|
---|
| 521 | <filename class="directory">zoneinfo/posix</filename>. It is
|
---|
[edbeeb5] | 522 | necessary to put the POSIX time zones in
|
---|
[7a6bcf9] | 523 | <filename class="directory">zoneinfo</filename>, otherwise various
|
---|
[3c5ecc9] | 524 | test suites will report errors. On an embedded system, where space is
|
---|
[edbeeb5] | 525 | tight and you do not intend to ever update the time zones, you could save
|
---|
[6dfcfecc] | 526 | 1.9 MB by not using the <filename class="directory">posix</filename>
|
---|
[3c5ecc9] | 527 | directory, but some applications or test suites might produce some
|
---|
[7bb9fda] | 528 | failures.</para>
|
---|
[7a6bcf9] | 529 | </listitem>
|
---|
| 530 | </varlistentry>
|
---|
| 531 | <varlistentry>
|
---|
| 532 | <term><parameter>zic -L leapseconds ...</parameter></term>
|
---|
| 533 | <listitem>
|
---|
[edbeeb5] | 534 | <para>This creates right time zones, including leap seconds. On an
|
---|
[7a6bcf9] | 535 | embedded system, where space is tight and you do not intend to
|
---|
[edbeeb5] | 536 | ever update the time zones, or care about the correct time, you could
|
---|
[7a6bcf9] | 537 | save 1.9MB by omitting the <filename class="directory">right</filename>
|
---|
| 538 | directory.</para>
|
---|
| 539 | </listitem>
|
---|
| 540 | </varlistentry>
|
---|
| 541 | <varlistentry>
|
---|
| 542 | <term><parameter>zic ... -p ...</parameter></term>
|
---|
| 543 | <listitem>
|
---|
[d7f2eb0] | 544 | <para>This creates the <filename>posixrules</filename> file. We use
|
---|
[cb02946] | 545 | New York because POSIX requires the daylight savings time rules
|
---|
[e7134f1] | 546 | to be in accordance with US rules.</para>
|
---|
[7a6bcf9] | 547 | </listitem>
|
---|
| 548 | </varlistentry>
|
---|
| 549 | </variablelist>
|
---|
| 550 |
|
---|
| 551 |
|
---|
| 552 | <para>One way to determine the local time zone is to run the following
|
---|
[e1060de] | 553 | script:</para>
|
---|
[342b176] | 554 |
|
---|
[be4be92] | 555 | <screen role="nodump"><userinput>tzselect</userinput></screen>
|
---|
[342b176] | 556 |
|
---|
[6a82dd9] | 557 | <para>After answering a few questions about the location, the script will
|
---|
[e1060de] | 558 | output the name of the time zone (e.g.,
|
---|
| 559 | <emphasis>America/Edmonton</emphasis>). There are also some other possible
|
---|
[edbeeb5] | 560 | time zones listed in <filename
|
---|
[e1060de] | 561 | class='directory'>/usr/share/zoneinfo</filename> such as
|
---|
| 562 | <emphasis>Canada/Eastern</emphasis> or <emphasis>EST5EDT</emphasis> that
|
---|
| 563 | are not identified by the script but can be used.</para>
|
---|
| 564 |
|
---|
| 565 | <para>Then create the <filename>/etc/localtime</filename> file by
|
---|
| 566 | running:</para>
|
---|
[342b176] | 567 |
|
---|
[1daca67] | 568 | <screen><userinput>ln -sfv /usr/share/zoneinfo/<replaceable><xxx></replaceable> /etc/localtime</userinput></screen>
|
---|
[342b176] | 569 |
|
---|
[e1060de] | 570 | <para>Replace <replaceable><xxx></replaceable> with the name of the
|
---|
| 571 | time zone selected (e.g., Canada/Eastern).</para>
|
---|
[6a82dd9] | 572 |
|
---|
[a72ca33] | 573 | </sect3>
|
---|
[6a82dd9] | 574 |
|
---|
[a72ca33] | 575 | <sect3 id="conf-ld" role="configuration">
|
---|
[6a82dd9] | 576 | <title>Configuring the Dynamic Loader</title>
|
---|
| 577 |
|
---|
| 578 | <indexterm zone="conf-ld">
|
---|
| 579 | <primary sortas="e-/etc/ld.so.conf">/etc/ld.so.conf</primary>
|
---|
| 580 | </indexterm>
|
---|
| 581 |
|
---|
| 582 | <para>By default, the dynamic loader (<filename
|
---|
| 583 | class="libraryfile">/lib/ld-linux.so.2</filename>) searches through
|
---|
[85cdcb09] | 584 | <filename class="directory">/usr/lib</filename> for dynamic libraries
|
---|
| 585 | that are needed by programs as they are run. However, if there are
|
---|
| 586 | libraries in directories other than
|
---|
[6a82dd9] | 587 | <filename class="directory">/usr/lib</filename>, these need to be added
|
---|
| 588 | to the <filename>/etc/ld.so.conf</filename> file in order for the
|
---|
| 589 | dynamic loader to find them. Two directories that are commonly known
|
---|
| 590 | to contain additional libraries are <filename
|
---|
| 591 | class="directory">/usr/local/lib</filename> and <filename
|
---|
| 592 | class="directory">/opt/lib</filename>, so add those directories to the
|
---|
| 593 | dynamic loader's search path.</para>
|
---|
| 594 |
|
---|
| 595 | <para>Create a new file <filename>/etc/ld.so.conf</filename> by running the
|
---|
| 596 | following:</para>
|
---|
[342b176] | 597 |
|
---|
[bb55064] | 598 | <screen><userinput>cat > /etc/ld.so.conf << "EOF"
|
---|
[d72e04a] | 599 | <literal># Begin /etc/ld.so.conf
|
---|
[342b176] | 600 | /usr/local/lib
|
---|
| 601 | /opt/lib
|
---|
[50f648b] | 602 | </literal>
|
---|
[bb55064] | 603 | EOF</userinput></screen>
|
---|
[342b176] | 604 |
|
---|
[6dfcfecc] | 605 | <para>If desired, the dynamic loader can also search a directory and
|
---|
[2ca8941] | 606 | include the contents of files found there. Generally the files in
|
---|
[50f648b] | 607 | this include directory are one line specifying the desired library path.
|
---|
| 608 | To add this capability run the following commands:</para>
|
---|
| 609 |
|
---|
[6dfcfecc] | 610 | <screen role="nodump"><userinput>cat >> /etc/ld.so.conf << "EOF"
|
---|
[50f648b] | 611 | <literal># Add an include directory
|
---|
| 612 | include /etc/ld.so.conf.d/*.conf
|
---|
| 613 | </literal>
|
---|
| 614 | EOF
|
---|
[3d086301] | 615 | mkdir -pv /etc/ld.so.conf.d</userinput></screen>
|
---|
[50f648b] | 616 |
|
---|
[a72ca33] | 617 | </sect3>
|
---|
[6a82dd9] | 618 | </sect2>
|
---|
| 619 |
|
---|
[6dfcfecc] | 620 | <!-- - - - - - - - - - -->
|
---|
| 621 | <!-- Multilib - 32bit -->
|
---|
| 622 | <!-- - - - - - - - - - -->
|
---|
| 623 | <sect2 arch="ml_32,ml_all">
|
---|
| 624 | <title>Building Glibc - 32bit</title>
|
---|
| 625 |
|
---|
| 626 | <para>Now recompile for m32. The extracted source can be
|
---|
[0ebda11] | 627 | reused but needs to be cleaned before installing the m32
|
---|
[6dfcfecc] | 628 | version of Glibc.</para>
|
---|
| 629 |
|
---|
| 630 | <para>Clear the build directory and remove artefacts from
|
---|
| 631 | previous build:</para>
|
---|
| 632 |
|
---|
| 633 | <screen><userinput remap="pre">rm -rf ./*
|
---|
| 634 | find .. -name "*.a" -delete</userinput></screen>
|
---|
| 635 |
|
---|
| 636 | <para>Configure Glibc for m32 with the following commands:</para>
|
---|
| 637 |
|
---|
| 638 | <screen><userinput remap="configure">CC="gcc -m32" CXX="g++ -m32" \
|
---|
| 639 | ../configure \
|
---|
| 640 | --prefix=/usr \
|
---|
| 641 | --host=i686-pc-linux-gnu \
|
---|
| 642 | --build=$(../scripts/config.guess) \
|
---|
| 643 | --enable-kernel=&min-kernel; \
|
---|
| 644 | --with-headers=/usr/include \
|
---|
| 645 | --enable-multi-arch \
|
---|
[0ebda11] | 646 | --libdir=/usr/lib32 \
|
---|
| 647 | --libexecdir=/usr/lib32 \
|
---|
[d4b5218] | 648 | libc_cv_slibdir=/usr/lib32</userinput></screen>
|
---|
[6dfcfecc] | 649 |
|
---|
| 650 | <para>Compile the package:</para>
|
---|
| 651 |
|
---|
| 652 | <screen><userinput remap="make">make</userinput></screen>
|
---|
| 653 |
|
---|
| 654 | <para>Install the package:</para>
|
---|
| 655 |
|
---|
| 656 | <screen><userinput remap="install">make DESTDIR=$PWD/DESTDIR install
|
---|
[0ebda11] | 657 | cp -a DESTDIR/usr/lib32/* /usr/lib32/
|
---|
[6dfcfecc] | 658 | install -vm644 DESTDIR/usr/include/gnu/{lib-names,stubs}-32.h \
|
---|
[0ebda11] | 659 | /usr/include/gnu/</userinput></screen>
|
---|
| 660 | <!-- no longer required as they are created in chap5
|
---|
| 661 | ln -svf ../lib32/ld-linux.so.2 /lib/ld-linux.so.2
|
---|
| 662 | -->
|
---|
[6dfcfecc] | 663 |
|
---|
| 664 | <para>Add the library name to the dynamic loader config:</para>
|
---|
| 665 |
|
---|
[0ebda11] | 666 | <screen role="install"><userinput>echo "/usr/lib32" >> /etc/ld.so.conf</userinput></screen>
|
---|
[6dfcfecc] | 667 |
|
---|
| 668 | <caution>
|
---|
| 669 | <para>At this point, it is imperative to stop and ensure that the basic
|
---|
| 670 | functions (compiling and linking) of the new toolchain are working as
|
---|
| 671 | expected. To perform a sanity check, run the following commands:</para>
|
---|
| 672 |
|
---|
| 673 | <screen><userinput>echo 'int main(){}' > dummy.c
|
---|
| 674 | gcc -m32 dummy.c
|
---|
| 675 | readelf -l a.out | grep '/ld-linux'</userinput></screen>
|
---|
| 676 |
|
---|
| 677 | <para>If everything is working correctly, there should be no errors,
|
---|
| 678 | and the output of the last command will be of the form:</para>
|
---|
| 679 |
|
---|
| 680 | <screen><computeroutput>[Requesting program interpreter: /lib/ld-linux.so.2]</computeroutput></screen>
|
---|
| 681 |
|
---|
| 682 | <para>If the output is not shown as above or there was no output at all,
|
---|
| 683 | then something is wrong. Investigate and retrace the steps to find out
|
---|
| 684 | where the problem is and correct it. This issue must be resolved before
|
---|
| 685 | continuing on.</para>
|
---|
| 686 |
|
---|
| 687 | <para>Once all is well, clean up the test files:</para>
|
---|
| 688 |
|
---|
| 689 | <screen><userinput>rm -v dummy.c a.out</userinput></screen>
|
---|
| 690 |
|
---|
| 691 | </caution>
|
---|
| 692 |
|
---|
| 693 | </sect2><!-- m32 -->
|
---|
| 694 |
|
---|
| 695 | <!-- - - - - - - - - - -->
|
---|
| 696 | <!-- Multilib - x32bit -->
|
---|
| 697 | <!-- - - - - - - - - - -->
|
---|
| 698 |
|
---|
| 699 | <sect2 arch="ml_x32,ml_all">
|
---|
| 700 | <title>Building Glibc - x32bit</title>
|
---|
| 701 |
|
---|
| 702 | <para>Now recompile for mx32. The extracted source can be
|
---|
[0ebda11] | 703 | reused but needs to be cleaned before installing the mx32
|
---|
[6dfcfecc] | 704 | version of Glibc.</para>
|
---|
| 705 |
|
---|
| 706 | <para>Clear the build directory and remove artefacts from
|
---|
| 707 | previous build:</para>
|
---|
| 708 |
|
---|
| 709 | <screen><userinput remap="pre">rm -rf ./*
|
---|
| 710 | find .. -name "*.a" -delete</userinput></screen>
|
---|
| 711 |
|
---|
| 712 | <para>Configure Glibc for mx32 with the following commands:</para>
|
---|
| 713 |
|
---|
| 714 | <screen><userinput remap="configure">CC="gcc -mx32" CXX="g++ -mx32" \
|
---|
| 715 | ../configure \
|
---|
| 716 | --prefix=/usr \
|
---|
| 717 | --host=x86_64-pc-linux-gnux32 \
|
---|
| 718 | --build=$(../scripts/config.guess) \
|
---|
| 719 | --enable-kernel=&min-kernel; \
|
---|
[0ebda11] | 720 | --with-headers=/usr/include \
|
---|
[6dfcfecc] | 721 | --enable-multi-arch \
|
---|
[0ebda11] | 722 | --libdir=/usr/libx32 \
|
---|
| 723 | --libexecdir=/usr/libx32 \
|
---|
[d4b5218] | 724 | libc_cv_slibdir=/usr/libx32</userinput></screen>
|
---|
[6dfcfecc] | 725 |
|
---|
| 726 | <para>Compile the package:</para>
|
---|
| 727 |
|
---|
| 728 | <screen><userinput remap="make">make</userinput></screen>
|
---|
| 729 |
|
---|
| 730 | <para>Install the package:</para>
|
---|
| 731 |
|
---|
| 732 | <screen><userinput remap="install">make DESTDIR=$PWD/DESTDIR install
|
---|
[0ebda11] | 733 | cp -a DESTDIR/usr/libx32/* /usr/libx32/
|
---|
[6dfcfecc] | 734 | install -vm644 DESTDIR/usr/include/gnu/{lib-names,stubs}-x32.h \
|
---|
[0ebda11] | 735 | /usr/include/gnu/</userinput></screen>
|
---|
| 736 | <!-- no longer required as they are created in chap5
|
---|
| 737 | ln -svf ../libx32/ld-linux-x32.so.2 /lib/ld-linux-x32.so.2
|
---|
| 738 | -->
|
---|
[6dfcfecc] | 739 | <para>Add the library name to the dynamic loader config:</para>
|
---|
| 740 |
|
---|
[0ebda11] | 741 | <screen role="install"><userinput>echo "/usr/libx32" >> /etc/ld.so.conf</userinput></screen>
|
---|
[6dfcfecc] | 742 |
|
---|
| 743 | <caution>
|
---|
| 744 | <para>At this point, it is imperative to stop and ensure that the basic
|
---|
| 745 | functions (compiling and linking) of the new toolchain are working as
|
---|
| 746 | expected. To perform a sanity check, run the following commands:</para>
|
---|
| 747 |
|
---|
| 748 | <screen><userinput>echo 'int main(){}' > dummy.c
|
---|
| 749 | gcc -mx32 dummy.c
|
---|
| 750 | readelf -l a.out | grep '/ld-linux-x32'</userinput></screen>
|
---|
| 751 |
|
---|
| 752 | <para>If everything is working correctly, there should be no errors,
|
---|
| 753 | and the output of the last command will be of the form:</para>
|
---|
| 754 |
|
---|
[d7e0db5] | 755 | <screen><computeroutput>[Requesting program interpreter: /libx32/ld-linux-x32.so.2]</computeroutput></screen>
|
---|
[6dfcfecc] | 756 |
|
---|
| 757 | <para>If the output is not shown as above or there was no output at all,
|
---|
| 758 | then something is wrong. Investigate and retrace the steps to find out
|
---|
| 759 | where the problem is and correct it. This issue must be resolved before
|
---|
| 760 | continuing on.</para>
|
---|
| 761 |
|
---|
| 762 | <para>Once all is well, clean up the test files:</para>
|
---|
| 763 |
|
---|
| 764 | <screen><userinput>rm -v dummy.c a.out</userinput></screen>
|
---|
| 765 |
|
---|
| 766 | </caution>
|
---|
| 767 |
|
---|
| 768 | </sect2><!-- mx32 -->
|
---|
| 769 |
|
---|
[6a82dd9] | 770 | <sect2 id="contents-glibc" role="content">
|
---|
| 771 | <title>Contents of Glibc</title>
|
---|
| 772 |
|
---|
| 773 | <segmentedlist>
|
---|
| 774 | <segtitle>Installed programs</segtitle>
|
---|
| 775 | <segtitle>Installed libraries</segtitle>
|
---|
[fe05b08] | 776 | <segtitle>Installed directories</segtitle>
|
---|
[6a82dd9] | 777 |
|
---|
| 778 | <seglistitem>
|
---|
[db3c501] | 779 | <seg>gencat, getconf, getent, iconv, iconvconfig, ldconfig,
|
---|
[81d3242] | 780 | ldd, lddlibc4,
|
---|
| 781 | ld.so (symlink to ld-linux-x86-64.so.2 or ld-linux.so.2),
|
---|
[09d148d] | 782 | locale, localedef, makedb, mtrace,
|
---|
[78cc3be] | 783 | pcprofiledump, pldd, sln, sotruss, sprof, tzselect, xtrace,
|
---|
[6a82dd9] | 784 | zdump, and zic</seg>
|
---|
[9c7598cc] | 785 | <seg>ld-linux-x86-64.so.2, ld-linux.so.2,
|
---|
[db3c501] | 786 | libBrokenLocale.{a,so}, libanl.{a,so},
|
---|
[b7daa52a] | 787 | libc.{a,so}, libc_nonshared.a, libc_malloc_debug.so,
|
---|
[bbfb090] | 788 | libdl.{a,so.2}, libg.a, libm.{a,so},
|
---|
[9c7598cc] | 789 | libmcheck.a, libmemusage.so, libmvec.{a,so}, libnsl.so.1,
|
---|
[78cc3be] | 790 | libnss_compat.so, libnss_dns.so, libnss_files.so, libnss_hesiod.so,
|
---|
[9c7598cc] | 791 | libpcprofile.so, libpthread.{a,so.0},
|
---|
| 792 | libresolv.{a,so}, librt.{a,so.1},
|
---|
| 793 | libthread_db.so, and libutil.{a,so.1}</seg>
|
---|
[fe05b08] | 794 | <seg>/usr/include/arpa, /usr/include/bits, /usr/include/gnu,
|
---|
| 795 | /usr/include/net, /usr/include/netash, /usr/include/netatalk,
|
---|
| 796 | /usr/include/netax25, /usr/include/neteconet, /usr/include/netinet,
|
---|
| 797 | /usr/include/netipx, /usr/include/netiucv, /usr/include/netpacket,
|
---|
| 798 | /usr/include/netrom, /usr/include/netrose, /usr/include/nfs,
|
---|
[78cc3be] | 799 | /usr/include/protocols, /usr/include/rpc,
|
---|
[4028929] | 800 | /usr/include/sys, /usr/lib/audit, /usr/lib/gconv, /usr/lib/locale,
|
---|
| 801 | /usr/libexec/getconf, /usr/share/i18n, /usr/share/zoneinfo,
|
---|
[09d148d] | 802 | and /var/lib/nss_db</seg>
|
---|
[6a82dd9] | 803 | </seglistitem>
|
---|
| 804 | </segmentedlist>
|
---|
| 805 |
|
---|
| 806 | <variablelist>
|
---|
| 807 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 808 | <?dbfo list-presentation="list"?>
|
---|
| 809 | <?dbhtml list-presentation="table"?>
|
---|
| 810 |
|
---|
| 811 | <varlistentry id="gencat">
|
---|
| 812 | <term><command>gencat</command></term>
|
---|
| 813 | <listitem>
|
---|
| 814 | <para>Generates message catalogues</para>
|
---|
| 815 | <indexterm zone="ch-system-glibc gencat">
|
---|
| 816 | <primary sortas="b-gencat">gencat</primary>
|
---|
| 817 | </indexterm>
|
---|
| 818 | </listitem>
|
---|
| 819 | </varlistentry>
|
---|
| 820 |
|
---|
| 821 | <varlistentry id="getconf">
|
---|
| 822 | <term><command>getconf</command></term>
|
---|
| 823 | <listitem>
|
---|
| 824 | <para>Displays the system configuration values for file system
|
---|
| 825 | specific variables</para>
|
---|
| 826 | <indexterm zone="ch-system-glibc getconf">
|
---|
| 827 | <primary sortas="b-getconf">getconf</primary>
|
---|
| 828 | </indexterm>
|
---|
| 829 | </listitem>
|
---|
| 830 | </varlistentry>
|
---|
| 831 |
|
---|
| 832 | <varlistentry id="getent">
|
---|
| 833 | <term><command>getent</command></term>
|
---|
| 834 | <listitem>
|
---|
| 835 | <para>Gets entries from an administrative database</para>
|
---|
| 836 | <indexterm zone="ch-system-glibc getent">
|
---|
| 837 | <primary sortas="b-getent">getent</primary>
|
---|
| 838 | </indexterm>
|
---|
| 839 | </listitem>
|
---|
| 840 | </varlistentry>
|
---|
| 841 |
|
---|
| 842 | <varlistentry id="iconv">
|
---|
| 843 | <term><command>iconv</command></term>
|
---|
| 844 | <listitem>
|
---|
| 845 | <para>Performs character set conversion</para>
|
---|
| 846 | <indexterm zone="ch-system-glibc iconv">
|
---|
| 847 | <primary sortas="b-iconv">iconv</primary>
|
---|
| 848 | </indexterm>
|
---|
| 849 | </listitem>
|
---|
| 850 | </varlistentry>
|
---|
| 851 |
|
---|
| 852 | <varlistentry id="iconvconfig">
|
---|
| 853 | <term><command>iconvconfig</command></term>
|
---|
| 854 | <listitem>
|
---|
| 855 | <para>Creates fastloading <command>iconv</command> module configuration
|
---|
| 856 | files</para>
|
---|
| 857 | <indexterm zone="ch-system-glibc iconvconfig">
|
---|
| 858 | <primary sortas="b-iconvconfig">iconvconfig</primary>
|
---|
| 859 | </indexterm>
|
---|
| 860 | </listitem>
|
---|
| 861 | </varlistentry>
|
---|
| 862 |
|
---|
| 863 | <varlistentry id="ldconfig">
|
---|
| 864 | <term><command>ldconfig</command></term>
|
---|
| 865 | <listitem>
|
---|
| 866 | <para>Configures the dynamic linker runtime bindings</para>
|
---|
| 867 | <indexterm zone="ch-system-glibc ldconfig">
|
---|
| 868 | <primary sortas="b-ldconfig">ldconfig</primary>
|
---|
| 869 | </indexterm>
|
---|
| 870 | </listitem>
|
---|
| 871 | </varlistentry>
|
---|
| 872 |
|
---|
| 873 | <varlistentry id="ldd">
|
---|
| 874 | <term><command>ldd</command></term>
|
---|
| 875 | <listitem>
|
---|
| 876 | <para>Reports which shared libraries are required
|
---|
| 877 | by each given program or shared library</para>
|
---|
| 878 | <indexterm zone="ch-system-glibc ldd">
|
---|
| 879 | <primary sortas="b-ldd">ldd</primary>
|
---|
| 880 | </indexterm>
|
---|
| 881 | </listitem>
|
---|
| 882 | </varlistentry>
|
---|
| 883 |
|
---|
| 884 | <varlistentry id="lddlibc4">
|
---|
| 885 | <term><command>lddlibc4</command></term>
|
---|
| 886 | <listitem>
|
---|
[db3c501] | 887 | <para>Assists <command>ldd</command> with object files.
|
---|
| 888 | It does not exist on newer architectures like x86_64</para>
|
---|
[6a82dd9] | 889 | <indexterm zone="ch-system-glibc lddlibc4">
|
---|
| 890 | <primary sortas="b-lddlibc4">lddlibc4</primary>
|
---|
| 891 | </indexterm>
|
---|
| 892 | </listitem>
|
---|
| 893 | </varlistentry>
|
---|
| 894 |
|
---|
| 895 | <varlistentry id="locale">
|
---|
| 896 | <term><command>locale</command></term>
|
---|
| 897 | <listitem>
|
---|
| 898 | <para>Prints various information about the current locale</para>
|
---|
| 899 | <indexterm zone="ch-system-glibc locale">
|
---|
| 900 | <primary sortas="b-locale">locale</primary>
|
---|
| 901 | </indexterm>
|
---|
| 902 | </listitem>
|
---|
| 903 | </varlistentry>
|
---|
| 904 |
|
---|
| 905 | <varlistentry id="localedef">
|
---|
| 906 | <term><command>localedef</command></term>
|
---|
| 907 | <listitem>
|
---|
| 908 | <para>Compiles locale specifications</para>
|
---|
| 909 | <indexterm zone="ch-system-glibc localedef">
|
---|
| 910 | <primary sortas="b-localedef">localedef</primary>
|
---|
| 911 | </indexterm>
|
---|
| 912 | </listitem>
|
---|
| 913 | </varlistentry>
|
---|
| 914 |
|
---|
[ca101ad] | 915 | <varlistentry id="makedb">
|
---|
| 916 | <term><command>makedb</command></term>
|
---|
| 917 | <listitem>
|
---|
| 918 | <para>Creates a simple database from textual input</para>
|
---|
| 919 | <indexterm zone="ch-system-glibc makedb">
|
---|
| 920 | <primary sortas="b-makedb">makedb</primary>
|
---|
| 921 | </indexterm>
|
---|
| 922 | </listitem>
|
---|
| 923 | </varlistentry>
|
---|
| 924 |
|
---|
[6a82dd9] | 925 | <varlistentry id="mtrace">
|
---|
| 926 | <term><command>mtrace</command></term>
|
---|
| 927 | <listitem>
|
---|
| 928 | <para>Reads and interprets a memory trace file and displays a summary
|
---|
| 929 | in human-readable format</para>
|
---|
| 930 | <indexterm zone="ch-system-glibc mtrace">
|
---|
| 931 | <primary sortas="b-mtrace">mtrace</primary>
|
---|
| 932 | </indexterm>
|
---|
| 933 | </listitem>
|
---|
| 934 | </varlistentry>
|
---|
| 935 |
|
---|
[78cc3be] | 936 | <varlistentry id="pcprofiledump">
|
---|
| 937 | <term><command>pcprofiledump</command></term>
|
---|
| 938 | <listitem>
|
---|
| 939 | <para>Dump information generated by PC profiling</para>
|
---|
| 940 | <indexterm zone="ch-system-glibc pcprofiledump">
|
---|
| 941 | <primary sortas="b-pcprofiledump">pcprofiledump</primary>
|
---|
| 942 | </indexterm>
|
---|
| 943 | </listitem>
|
---|
| 944 | </varlistentry>
|
---|
| 945 |
|
---|
[ca101ad] | 946 | <varlistentry id="pldd">
|
---|
| 947 | <term><command>pldd</command></term>
|
---|
| 948 | <listitem>
|
---|
| 949 | <para>Lists dynamic shared objects used by running processes</para>
|
---|
| 950 | <indexterm zone="ch-system-glibc pldd">
|
---|
| 951 | <primary sortas="b-pldd">pldd</primary>
|
---|
| 952 | </indexterm>
|
---|
| 953 | </listitem>
|
---|
| 954 | </varlistentry>
|
---|
[1118b17] | 955 |
|
---|
[6a82dd9] | 956 | <varlistentry id="sln">
|
---|
| 957 | <term><command>sln</command></term>
|
---|
| 958 | <listitem>
|
---|
| 959 | <para>A statically linked <command>ln</command> program</para>
|
---|
| 960 | <indexterm zone="ch-system-glibc sln">
|
---|
| 961 | <primary sortas="b-sln">sln</primary>
|
---|
| 962 | </indexterm>
|
---|
| 963 | </listitem>
|
---|
| 964 | </varlistentry>
|
---|
| 965 |
|
---|
[3119ddc] | 966 | <varlistentry id="sotruss">
|
---|
| 967 | <term><command>sotruss</command></term>
|
---|
| 968 | <listitem>
|
---|
| 969 | <para>Traces shared library procedure calls of a specified command</para>
|
---|
| 970 | <indexterm zone="ch-system-glibc sotruss">
|
---|
| 971 | <primary sortas="b-sotruss">sotruss</primary>
|
---|
| 972 | </indexterm>
|
---|
| 973 | </listitem>
|
---|
| 974 | </varlistentry>
|
---|
| 975 |
|
---|
[6a82dd9] | 976 | <varlistentry id="sprof">
|
---|
| 977 | <term><command>sprof</command></term>
|
---|
| 978 | <listitem>
|
---|
| 979 | <para>Reads and displays shared object profiling data</para>
|
---|
| 980 | <indexterm zone="ch-system-glibc sprof">
|
---|
| 981 | <primary sortas="b-sprof">sprof</primary>
|
---|
| 982 | </indexterm>
|
---|
| 983 | </listitem>
|
---|
| 984 | </varlistentry>
|
---|
| 985 |
|
---|
| 986 | <varlistentry id="tzselect">
|
---|
| 987 | <term><command>tzselect</command></term>
|
---|
| 988 | <listitem>
|
---|
| 989 | <para>Asks the user about the location of the system and reports
|
---|
| 990 | the corresponding time zone description</para>
|
---|
| 991 | <indexterm zone="ch-system-glibc tzselect">
|
---|
| 992 | <primary sortas="b-tzselect">tzselect</primary>
|
---|
| 993 | </indexterm>
|
---|
| 994 | </listitem>
|
---|
| 995 | </varlistentry>
|
---|
| 996 |
|
---|
| 997 | <varlistentry id="xtrace">
|
---|
| 998 | <term><command>xtrace</command></term>
|
---|
| 999 | <listitem>
|
---|
| 1000 | <para>Traces the execution of a program by printing the currently
|
---|
| 1001 | executed function</para>
|
---|
| 1002 | <indexterm zone="ch-system-glibc xtrace">
|
---|
| 1003 | <primary sortas="b-xtrace">xtrace</primary>
|
---|
| 1004 | </indexterm>
|
---|
| 1005 | </listitem>
|
---|
| 1006 | </varlistentry>
|
---|
| 1007 |
|
---|
| 1008 | <varlistentry id="zdump">
|
---|
| 1009 | <term><command>zdump</command></term>
|
---|
| 1010 | <listitem>
|
---|
| 1011 | <para>The time zone dumper</para>
|
---|
| 1012 | <indexterm zone="ch-system-glibc zdump">
|
---|
| 1013 | <primary sortas="b-zdump">zdump</primary>
|
---|
| 1014 | </indexterm>
|
---|
| 1015 | </listitem>
|
---|
| 1016 | </varlistentry>
|
---|
| 1017 |
|
---|
| 1018 | <varlistentry id="zic">
|
---|
| 1019 | <term><command>zic</command></term>
|
---|
| 1020 | <listitem>
|
---|
| 1021 | <para>The time zone compiler</para>
|
---|
| 1022 | <indexterm zone="ch-system-glibc zic">
|
---|
| 1023 | <primary sortas="b-zic">zic</primary>
|
---|
| 1024 | </indexterm>
|
---|
| 1025 | </listitem>
|
---|
| 1026 | </varlistentry>
|
---|
| 1027 |
|
---|
| 1028 | <varlistentry id="ld.so">
|
---|
[9c7598cc] | 1029 | <term><filename class="libraryfile">ld-*.so</filename></term>
|
---|
[6a82dd9] | 1030 | <listitem>
|
---|
| 1031 | <para>The helper program for shared library executables</para>
|
---|
| 1032 | <indexterm zone="ch-system-glibc ld.so">
|
---|
[5ef820b] | 1033 | <primary sortas="c-ld.so">ld-&glibc-version;.so</primary>
|
---|
[6a82dd9] | 1034 | </indexterm>
|
---|
| 1035 | </listitem>
|
---|
| 1036 | </varlistentry>
|
---|
| 1037 |
|
---|
| 1038 | <varlistentry id="libBrokenLocale">
|
---|
| 1039 | <term><filename class="libraryfile">libBrokenLocale</filename></term>
|
---|
| 1040 | <listitem>
|
---|
| 1041 | <para>Used internally by Glibc as a gross hack to get broken programs
|
---|
| 1042 | (e.g., some Motif applications) running. See comments in
|
---|
| 1043 | <filename>glibc-&glibc-version;/locale/broken_cur_max.c</filename>
|
---|
| 1044 | for more information</para>
|
---|
| 1045 | <indexterm zone="ch-system-glibc libBrokenLocale">
|
---|
| 1046 | <primary sortas="c-libBrokenLocale">libBrokenLocale</primary>
|
---|
| 1047 | </indexterm>
|
---|
| 1048 | </listitem>
|
---|
| 1049 | </varlistentry>
|
---|
| 1050 |
|
---|
| 1051 | <varlistentry id="libanl">
|
---|
| 1052 | <term><filename class="libraryfile">libanl</filename></term>
|
---|
| 1053 | <listitem>
|
---|
[e9ab2b3] | 1054 | <para>Dummy library containing no functions. Previously was the
|
---|
| 1055 | asynchronous name lookup library, whose functions are now in
|
---|
| 1056 | <filename class='libraryfile'>libc</filename></para>
|
---|
[6a82dd9] | 1057 | <indexterm zone="ch-system-glibc libanl">
|
---|
| 1058 | <primary sortas="c-libanl">libanl</primary>
|
---|
| 1059 | </indexterm>
|
---|
| 1060 | </listitem>
|
---|
| 1061 | </varlistentry>
|
---|
| 1062 |
|
---|
| 1063 | <varlistentry id="libc">
|
---|
| 1064 | <term><filename class="libraryfile">libc</filename></term>
|
---|
| 1065 | <listitem>
|
---|
| 1066 | <para>The main C library</para>
|
---|
| 1067 | <indexterm zone="ch-system-glibc libc">
|
---|
| 1068 | <primary sortas="c-libc">libc</primary>
|
---|
| 1069 | </indexterm>
|
---|
| 1070 | </listitem>
|
---|
| 1071 | </varlistentry>
|
---|
| 1072 |
|
---|
[b7daa52a] | 1073 | <varlistentry id="libc_malloc_debug">
|
---|
| 1074 | <term><filename class="libraryfile">libc_malloc_debug</filename></term>
|
---|
| 1075 | <listitem>
|
---|
| 1076 | <para>Turns on memory allocation checking when preloaded</para>
|
---|
| 1077 | <indexterm zone="ch-system-glibc libc_malloc_debug">
|
---|
| 1078 | <primary sortas="c-libc_malloc_debug">libc_malloc_debug</primary>
|
---|
| 1079 | </indexterm>
|
---|
| 1080 | </listitem>
|
---|
| 1081 | </varlistentry>
|
---|
| 1082 |
|
---|
[6a82dd9] | 1083 | <varlistentry id="libdl">
|
---|
| 1084 | <term><filename class="libraryfile">libdl</filename></term>
|
---|
| 1085 | <listitem>
|
---|
[9c7598cc] | 1086 | <para>Dummy library containing no functions. Previously was the
|
---|
| 1087 | dynamic linking interface library, whose functions are now in
|
---|
| 1088 | <filename class="libraryfile">libc</filename></para>
|
---|
[6a82dd9] | 1089 | <indexterm zone="ch-system-glibc libdl">
|
---|
| 1090 | <primary sortas="c-libdl">libdl</primary>
|
---|
| 1091 | </indexterm>
|
---|
| 1092 | </listitem>
|
---|
| 1093 | </varlistentry>
|
---|
| 1094 |
|
---|
| 1095 | <varlistentry id="libg">
|
---|
| 1096 | <term><filename class="libraryfile">libg</filename></term>
|
---|
| 1097 | <listitem>
|
---|
| 1098 | <para>Dummy library containing no functions. Previously was a runtime
|
---|
| 1099 | library for <command>g++</command></para>
|
---|
| 1100 | <indexterm zone="ch-system-glibc libg">
|
---|
| 1101 | <primary sortas="c-libg">libg</primary>
|
---|
| 1102 | </indexterm>
|
---|
| 1103 | </listitem>
|
---|
| 1104 | </varlistentry>
|
---|
| 1105 |
|
---|
| 1106 | <varlistentry id="libm">
|
---|
| 1107 | <term><filename class="libraryfile">libm</filename></term>
|
---|
| 1108 | <listitem>
|
---|
| 1109 | <para>The mathematical library</para>
|
---|
| 1110 | <indexterm zone="ch-system-glibc libm">
|
---|
| 1111 | <primary sortas="c-libm">libm</primary>
|
---|
| 1112 | </indexterm>
|
---|
| 1113 | </listitem>
|
---|
| 1114 | </varlistentry>
|
---|
| 1115 |
|
---|
[b7daa52a] | 1116 | <varlistentry id="libmvec">
|
---|
| 1117 | <term><filename class="libraryfile">libmvec</filename></term>
|
---|
| 1118 | <listitem>
|
---|
| 1119 | <para>The vector math library, linked in as needed
|
---|
| 1120 | when <filename class='libraryfile'>libm</filename> is used</para>
|
---|
| 1121 | <indexterm zone="ch-system-glibc libmvec">
|
---|
| 1122 | <primary sortas="c-libmvec">libmvec</primary>
|
---|
| 1123 | </indexterm>
|
---|
| 1124 | </listitem>
|
---|
| 1125 | </varlistentry>
|
---|
| 1126 |
|
---|
[6a82dd9] | 1127 | <varlistentry id="libmcheck">
|
---|
| 1128 | <term><filename class="libraryfile">libmcheck</filename></term>
|
---|
| 1129 | <listitem>
|
---|
| 1130 | <para>Turns on memory allocation checking when linked to</para>
|
---|
| 1131 | <indexterm zone="ch-system-glibc libmcheck">
|
---|
| 1132 | <primary sortas="c-libmcheck">libmcheck</primary>
|
---|
| 1133 | </indexterm>
|
---|
| 1134 | </listitem>
|
---|
| 1135 | </varlistentry>
|
---|
| 1136 |
|
---|
| 1137 | <varlistentry id="libmemusage">
|
---|
| 1138 | <term><filename class="libraryfile">libmemusage</filename></term>
|
---|
| 1139 | <listitem>
|
---|
| 1140 | <para>Used by <command>memusage</command> to help collect
|
---|
| 1141 | information about the memory usage of a program</para>
|
---|
| 1142 | <indexterm zone="ch-system-glibc libmemusage">
|
---|
| 1143 | <primary sortas="c-libmemusage">libmemusage</primary>
|
---|
| 1144 | </indexterm>
|
---|
| 1145 | </listitem>
|
---|
| 1146 | </varlistentry>
|
---|
| 1147 |
|
---|
| 1148 | <varlistentry id="libnsl">
|
---|
| 1149 | <term><filename class="libraryfile">libnsl</filename></term>
|
---|
| 1150 | <listitem>
|
---|
[9c7598cc] | 1151 | <para>The network services library, now deprecated</para>
|
---|
[6a82dd9] | 1152 | <indexterm zone="ch-system-glibc libnsl">
|
---|
| 1153 | <primary sortas="c-libnsl">libnsl</primary>
|
---|
| 1154 | </indexterm>
|
---|
| 1155 | </listitem>
|
---|
| 1156 | </varlistentry>
|
---|
| 1157 |
|
---|
| 1158 | <varlistentry id="libnss">
|
---|
[b7daa52a] | 1159 | <term><filename class="libraryfile">libnss_*</filename></term>
|
---|
[6a82dd9] | 1160 | <listitem>
|
---|
[b7daa52a] | 1161 | <para>The Name Service Switch modules, containing functions for
|
---|
[6a82dd9] | 1162 | resolving host names, user names, group names, aliases, services,
|
---|
[b7daa52a] | 1163 | protocols, etc. Loaded by
|
---|
| 1164 | <filename class='libraryfile'>libc</filename> according to the
|
---|
| 1165 | configuration in <filename>/etc/nsswitch.conf</filename></para>
|
---|
[6a82dd9] | 1166 | <indexterm zone="ch-system-glibc libnss">
|
---|
[b7daa52a] | 1167 | <primary sortas="c-libnss">libnss_*</primary>
|
---|
[6a82dd9] | 1168 | </indexterm>
|
---|
| 1169 | </listitem>
|
---|
| 1170 | </varlistentry>
|
---|
[1118b17] | 1171 |
|
---|
[78cc3be] | 1172 | <varlistentry id="libpcprofile">
|
---|
| 1173 | <term><filename class="libraryfile">libpcprofile</filename></term>
|
---|
| 1174 | <listitem>
|
---|
| 1175 | <para>Can be preloaded to PC profile an executable</para>
|
---|
| 1176 | <indexterm zone="ch-system-glibc libpcprofile">
|
---|
| 1177 | <primary sortas="c-libpcprofile">libpcprofile</primary>
|
---|
| 1178 | </indexterm>
|
---|
| 1179 | </listitem>
|
---|
| 1180 | </varlistentry>
|
---|
| 1181 |
|
---|
[6a82dd9] | 1182 | <varlistentry id="libpthread">
|
---|
| 1183 | <term><filename class="libraryfile">libpthread</filename></term>
|
---|
| 1184 | <listitem>
|
---|
[9c7598cc] | 1185 | <para>Dummy library containing no functions. Previously contained
|
---|
| 1186 | functions providing most of the interfaces specified
|
---|
[91d8e69] | 1187 | by the POSIX.1c Threads Extensions and the semaphore interfaces
|
---|
| 1188 | specified by the POSIX.1b Real-time Extensions, now the functions
|
---|
| 1189 | are in <filename class="libraryfile">libc</filename></para>
|
---|
[6a82dd9] | 1190 | <indexterm zone="ch-system-glibc libpthread">
|
---|
| 1191 | <primary sortas="c-libpthread">libpthread</primary>
|
---|
| 1192 | </indexterm>
|
---|
| 1193 | </listitem>
|
---|
| 1194 | </varlistentry>
|
---|
| 1195 |
|
---|
| 1196 | <varlistentry id="libresolv">
|
---|
| 1197 | <term><filename class="libraryfile">libresolv</filename></term>
|
---|
| 1198 | <listitem>
|
---|
| 1199 | <para>Contains functions for creating, sending, and interpreting
|
---|
| 1200 | packets to the Internet domain name servers</para>
|
---|
| 1201 | <indexterm zone="ch-system-glibc libresolv">
|
---|
| 1202 | <primary sortas="c-libresolv">libresolv</primary>
|
---|
| 1203 | </indexterm>
|
---|
| 1204 | </listitem>
|
---|
| 1205 | </varlistentry>
|
---|
| 1206 |
|
---|
| 1207 | <varlistentry id="librt">
|
---|
| 1208 | <term><filename class="libraryfile">librt</filename></term>
|
---|
| 1209 | <listitem>
|
---|
| 1210 | <para>Contains functions providing most of the interfaces specified
|
---|
[91d8e69] | 1211 | by the POSIX.1b Real-time Extensions</para>
|
---|
[6a82dd9] | 1212 | <indexterm zone="ch-system-glibc librt">
|
---|
| 1213 | <primary sortas="c-librt">librt</primary>
|
---|
| 1214 | </indexterm>
|
---|
| 1215 | </listitem>
|
---|
| 1216 | </varlistentry>
|
---|
| 1217 |
|
---|
| 1218 | <varlistentry id="libthread_db">
|
---|
| 1219 | <term><filename class="libraryfile">libthread_db</filename></term>
|
---|
| 1220 | <listitem>
|
---|
| 1221 | <para>Contains functions useful for building debuggers for
|
---|
| 1222 | multi-threaded programs</para>
|
---|
| 1223 | <indexterm zone="ch-system-glibc libthread_db">
|
---|
| 1224 | <primary sortas="c-libthread_db">libthread_db</primary>
|
---|
| 1225 | </indexterm>
|
---|
| 1226 | </listitem>
|
---|
| 1227 | </varlistentry>
|
---|
| 1228 |
|
---|
| 1229 | <varlistentry id="libutil">
|
---|
| 1230 | <term><filename class="libraryfile">libutil</filename></term>
|
---|
| 1231 | <listitem>
|
---|
[99b2938] | 1232 | <para>Dummy library containing no functions. Previously contained
|
---|
[9c7598cc] | 1233 | code for <quote>standard</quote> functions used in
|
---|
| 1234 | many different Unix utilities. These functions are now in
|
---|
| 1235 | <filename class="libraryfile">libc</filename></para>
|
---|
[6a82dd9] | 1236 | <indexterm zone="ch-system-glibc libutil">
|
---|
| 1237 | <primary sortas="c-libutil">libutil</primary>
|
---|
| 1238 | </indexterm>
|
---|
| 1239 | </listitem>
|
---|
| 1240 | </varlistentry>
|
---|
| 1241 |
|
---|
| 1242 | </variablelist>
|
---|
| 1243 |
|
---|
| 1244 | </sect2>
|
---|
[673b0d8] | 1245 |
|
---|
| 1246 | </sect1>
|
---|