Apply a change to allow Perl to build correctly when
[linux_from_scratch.git] / chapter06 / glibc.xml
blob93d83f80f181309799d9c0f62a1f717c193f30dd
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 ]>
8 <sect1 id="ch-system-glibc" role="wrap">
9   <?dbhtml filename="glibc.html"?>
11   <sect1info condition="script">
12     <productname>glibc</productname>
13     <productnumber>&glibc-version;</productnumber>
14     <address>&glibc-url;</address>
15   </sect1info>
17   <title>Glibc-&glibc-version;</title>
19   <indexterm zone="ch-system-glibc">
20     <primary sortas="a-Glibc">Glibc</primary>
21   </indexterm>
23   <sect2 role="package">
24     <title/>
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>
31     <segmentedlist>
32       <segtitle>&buildtime;</segtitle>
33       <segtitle>&diskspace;</segtitle>
35       <seglistitem>
36         <seg>&glibc-ch6-sbu;</seg>
37         <seg>&glibc-ch6-du;</seg>
38       </seglistitem>
39     </segmentedlist>
41   </sect2>
43   <sect2 role="installation">
44     <title>Installation of Glibc</title>
46     <note><para>The Glibc build system is self-contained and will install
47     perfectly, even though the compiler specs file and linker are still
48     pointing to <filename class="directory">/tools</filename>. The specs
49     and linker cannot be adjusted before the Glibc install because the
50     Glibc autoconf tests would give false results and defeat the goal
51     of achieving a clean build.</para></note>
53     <para>Some of the Glibc programs use the non-FHS compilant
54     <filename class="directory">/var/db</filename> directory to store
55     their runtime data. Apply the following patch to make such programs
56     store their runtime data in the FHS-compliant locations:</para>
58 <screen><userinput remap="pre">patch -Np1 -i ../&glibc-fhs-patch;</userinput></screen>
59 <!--
60     <para>Fix a minor security issue with glob functions:</para>
62 <screen><userinput remap="pre">patch -Np1 -i ../&glibc-glob-patch;</userinput></screen>
63 --><!--
64     <para>First create a compatibility symlink to avoid references to /tools in
65     our final glibc:</para>
67 <screen><userinput remap="pre">ln -sfv /tools/lib/gcc /usr/lib</userinput></screen>
68 -->
69     <para>Create a symlink for LSB
70     compliance. Additionally, for x86_64, create a compatibility symlink
71     required for the dynamic loader to function correctly:</para>
73 <screen><userinput remap="pre">case $(uname -m) in
74     i?86)   ln -sfv ld-linux.so.2 /lib/ld-lsb.so.3
75     ;;
76     x86_64) ln -sfv ../lib/ld-linux-x86-64.so.2 /lib64
77             ln -sfv ../lib/ld-linux-x86-64.so.2 /lib64/ld-lsb-x86-64.so.3
78     ;;
79 esac</userinput></screen>
80 <!--
81     <para>Remove a file that may be left over from a previous build attempt:
82     </para>
84 <screen><userinput remap="pre">rm -f /usr/include/limits.h</userinput></screen>
85 -->
86     <para>The Glibc documentation recommends building Glibc 
87     in a dedicated build directory:</para>
89 <screen><userinput remap="pre">mkdir -v build
90 cd       build</userinput></screen>
92     <para>Prepare Glibc for compilation:</para>
94 <screen><userinput remap="configure">CC="gcc -ffile-prefix-map=/tools=/usr" \
95 ../configure --prefix=/usr                          \
96              --disable-werror                       \
97              --enable-kernel=&min-kernel;                    \
98              --enable-stack-protector=strong        \
99              --with-headers=/usr/include            \
100              libc_cv_slibdir=/lib</userinput></screen>
102    <variablelist>
103       <title>The meaning of the options and new configure parameters:</title>
105       <varlistentry>
106         <term><parameter>CC="gcc -ffile-prefix-map=/tools=/usr"</parameter></term>
107         <listitem>
108           <para>Make GCC record any references to files in /tools in result
109           of the compilation as if the files resided in /usr.  This avoids
110           introduction of invalid paths in debugging symbols.</para>
111         </listitem>
112       </varlistentry>
114       <varlistentry>
115         <term><parameter>--disable-werror</parameter></term>
116         <listitem>
117           <para>This option disables the -Werror option passed to 
118           GCC.  This is necessary for running the test suite.</para>
119         </listitem>
120       </varlistentry>
122       <varlistentry>
123         <term><parameter>--enable-stack-protector=strong</parameter></term>
124         <listitem>
125           <para>This option increases system security by adding 
126           extra code to check for buffer overflows, such as stack
127           smashing attacks.</para>
128         </listitem>
129       </varlistentry>
131       <varlistentry>
132         <term><parameter>--with-headers=/usr/include</parameter></term>
133         <listitem>
134           <para>This option tells the build system where to find the
135           kernel API headers. By default, those headers are sought in
136           <filename class="directory">/tools/include</filename>.</para>
137         </listitem>
138       </varlistentry>
140       <varlistentry>
141         <term><parameter>libc_cv_slibdir=/lib</parameter></term>
142         <listitem>
143           <para>This variable sets the correct library for all
144           systems.  We do not want lib64 to be used.</para>
145         </listitem>
146       </varlistentry>
148     </variablelist>
150     <para>Compile the package:</para>
152 <screen><userinput remap="make">make</userinput></screen>
154     <important>
155       <para>In this section, the test suite for Glibc is considered critical.
156       Do not skip it under any circumstance.</para>
157     </important>
159     <para>Generally a few tests do not pass. The test failures listed below
160     are usually safe to ignore.</para>
162 <!-- Use remap="make" here to work around a jhalfs issue. -->
163 <screen><userinput remap="make">case $(uname -m) in
164   i?86)   ln -sfnv $PWD/elf/ld-linux.so.2        /lib ;;
165   x86_64) ln -sfnv $PWD/elf/ld-linux-x86-64.so.2 /lib ;;
166 esac</userinput></screen>
168     <note><para>The symbolic link above is needed to run the tests at this
169     stage of building in the chroot envirnment.  It will be overwritten
170     in the install phase below.</para></note>
172 <screen><userinput remap="test">make check</userinput></screen>
174     <para>You may see some test failures.  The Glibc test suite is
175     somewhat dependent on the host system.  This is a list of the most common
176     issues seen for some versions of LFS:</para>
178     <itemizedlist>
180       <listitem>
181         <para><emphasis>misc/tst-ttyname</emphasis> 
182         is known to fail in the LFS chroot environment.</para>
183       </listitem>
185       <listitem>
186         <para><emphasis>inet/tst-idna_name_classify</emphasis> 
187         is known to fail in the LFS chroot environment.</para>
188       </listitem>
190       <listitem>
191         <para><emphasis>posix/tst-getaddrinfo4</emphasis> and
192         <emphasis>posix/tst-getaddrinfo5</emphasis>
193         may fail on some architectures.</para>
194       </listitem>
196       <listitem>
197         <para>The <emphasis>nss/tst-nss-files-hosts-multi</emphasis>
198         test may fail for reasons that have not been determined.</para>
199       </listitem>
201       <listitem>
202         <para>The <emphasis>rt/tst-cputimer{1,2,3}</emphasis> tests depend on
203         the host system kernel. Kernels 4.14.91&ndash;4.14.96,
204         4.19.13&ndash;4.19.18, and 4.20.0&ndash;4.20.5 are known to 
205         cause these tests to fail.
206         </para>
207       </listitem>
209       <listitem>
210         <para>The math tests sometimes fail when running on
211         systems where the CPU is not a relatively new Intel or
212         AMD processor.</para>
213       </listitem>
214 <!--
215       <listitem>
216         <para>The
217         <emphasis>nptl/tst-thread-affinity-{pthread,pthread2,sched}</emphasis>
218         tests may fail for reasons that have not been determined.  </para>
219       </listitem>
221       <listitem>
222         <para>Other tests known to fail on some architectures are
223         malloc/tst-malloc-usable and nptl/tst-cleanupx4. </para>
224       </listitem>
226     </itemizedlist>
228     <para>Though it is a harmless message, the install stage of Glibc will
229     complain about the absence of <filename>/etc/ld.so.conf</filename>.
230     Prevent this warning with:</para>
232 <screen><userinput remap="install">touch /etc/ld.so.conf</userinput></screen>
234     <para>Fix the generated Makefile to skip an unneeded sanity check
235     that fails in the LFS partial environment:
236     </para>
238 <screen><userinput remap="install">sed '/test-installation/s@$(PERL)@echo not running@' -i ../Makefile</userinput></screen>
240     <para>Install the package:</para>
242 <screen><userinput remap="install">make install</userinput></screen>
244     <para>Install the configuration file and runtime directory for
245     <command>nscd</command>:</para>
247 <screen><userinput remap="install">cp -v ../nscd/nscd.conf /etc/nscd.conf
248 mkdir -pv /var/cache/nscd</userinput></screen>
250     <para revision="systemd">Install the systemd support files for 
251     <command>nscd</command>:</para>
253     <screen revision="systemd"><userinput remap="install">install -v -Dm644 ../nscd/nscd.tmpfiles /usr/lib/tmpfiles.d/nscd.conf
254 install -v -Dm644 ../nscd/nscd.service /lib/systemd/system/nscd.service</userinput></screen>
256     <para>Next, install the locales that can make the system respond in a
257     different language.  None of the locales are required, but if some of them
258     are missing, the test suites of future packages would skip important
259     testcases.</para>
261     <para>Individual locales can be installed using the
262     <command>localedef</command> program. E.g., the first
263     <command>localedef</command> command below combines the
264     <filename>/usr/share/i18n/locales/cs_CZ</filename>
265     charset-independent locale definition with the
266     <filename>/usr/share/i18n/charmaps/UTF-8.gz</filename>
267     charmap definition and appends the result to the
268     <filename>/usr/lib/locale/locale-archive</filename> file.
269     The following instructions will install the minimum set of
270     locales necessary for the optimal coverage of tests:</para>
272 <screen role="nodump"><userinput remap="locale-test">mkdir -pv /usr/lib/locale
273 localedef -i POSIX -f UTF-8 C.UTF-8 2> /dev/null || true
274 localedef -i cs_CZ -f UTF-8 cs_CZ.UTF-8
275 localedef -i de_DE -f ISO-8859-1 de_DE
276 localedef -i de_DE@euro -f ISO-8859-15 de_DE@euro
277 localedef -i de_DE -f UTF-8 de_DE.UTF-8
278 localedef -i el_GR -f ISO-8859-7 el_GR
279 localedef -i en_GB -f UTF-8 en_GB.UTF-8
280 localedef -i en_HK -f ISO-8859-1 en_HK
281 localedef -i en_PH -f ISO-8859-1 en_PH
282 localedef -i en_US -f ISO-8859-1 en_US
283 localedef -i en_US -f UTF-8 en_US.UTF-8
284 localedef -i es_MX -f ISO-8859-1 es_MX
285 localedef -i fa_IR -f UTF-8 fa_IR
286 localedef -i fr_FR -f ISO-8859-1 fr_FR
287 localedef -i fr_FR@euro -f ISO-8859-15 fr_FR@euro
288 localedef -i fr_FR -f UTF-8 fr_FR.UTF-8
289 localedef -i it_IT -f ISO-8859-1 it_IT
290 localedef -i it_IT -f UTF-8 it_IT.UTF-8
291 localedef -i ja_JP -f EUC-JP ja_JP
292 localedef -i ja_JP -f SHIFT_JIS ja_JP.SIJS 2> /dev/null || true
293 localedef -i ja_JP -f UTF-8 ja_JP.UTF-8
294 localedef -i ru_RU -f KOI8-R ru_RU.KOI8-R
295 localedef -i ru_RU -f UTF-8 ru_RU.UTF-8
296 localedef -i tr_TR -f UTF-8 tr_TR.UTF-8
297 localedef -i zh_CN -f GB18030 zh_CN.GB18030
298 localedef -i zh_HK -f BIG5-HKSCS zh_HK.BIG5-HKSCS</userinput></screen>
300     <para>In addition, install the locale for your own country, language and
301     character set.</para>
303     <para>Alternatively, install all locales listed in the
304     <filename>glibc-&glibc-version;/localedata/SUPPORTED</filename> file
305     (it includes every locale listed above and many more) at once with the
306     following time-consuming command:</para>
308 <screen><userinput remap="locale-full">make localedata/install-locales</userinput></screen>
310     <para>Then use the <command>localedef</command> command to create and
311     install locales not listed in the
312     <filename>glibc-&glibc-version;/localedata/SUPPORTED</filename> file
313     in the unlikely case you need them.</para>
315     <note><para>Glibc now uses libidn2 when resolving internationalized 
316     domain names.  This is a run time dependency.  If this capability
317     is needed, the instructions for installing libidn2 are in the 
318     <ulink url="&blfs-book;general/libidn2.html">BLFS libidn2 page</ulink>.
319     </para></note>
321   </sect2>
323   <sect2 id="conf-glibc" role="configuration">
324     <title>Configuring Glibc</title>
326     <indexterm zone="conf-glibc">
327       <primary sortas="e-/etc/nsswitch.conf">/etc/nsswitch.conf</primary>
328     </indexterm>
330     <indexterm zone="conf-glibc">
331       <primary sortas="e-/etc/localtime">/etc/localtime</primary>
332     </indexterm>
334   <sect3>
335   <title>Adding nsswitch.conf</title>
337     <para>The <filename>/etc/nsswitch.conf</filename> file needs to be created
338     because the Glibc defaults do not work well in a networked environment.
339     </para>
341     <para>Create a new file <filename>/etc/nsswitch.conf</filename> by running the
342     following:</para>
344 <screen><userinput>cat &gt; /etc/nsswitch.conf &lt;&lt; "EOF"
345 <literal># Begin /etc/nsswitch.conf
347 passwd: files
348 group: files
349 shadow: files
351 hosts: files dns
352 networks: files
354 protocols: files
355 services: files
356 ethers: files
357 rpc: files
359 # End /etc/nsswitch.conf</literal>
360 EOF</userinput></screen>
362     </sect3>
364     <sect3>
365     <title>Adding time zone data</title>
367     <para>Install and set up the time zone data with the following:</para>
368 <screen><userinput>tar -xf ../../tzdata&tzdata-version;.tar.gz
370 ZONEINFO=/usr/share/zoneinfo
371 mkdir -pv $ZONEINFO/{posix,right}
373 for tz in etcetera southamerica northamerica europe africa antarctica  \
374           asia australasia backward pacificnew systemv; do
375     zic -L /dev/null   -d $ZONEINFO       ${tz}
376     zic -L /dev/null   -d $ZONEINFO/posix ${tz}
377     zic -L leapseconds -d $ZONEINFO/right ${tz}
378 done
380 cp -v zone.tab zone1970.tab iso3166.tab $ZONEINFO
381 zic -d $ZONEINFO -p America/New_York
382 unset ZONEINFO</userinput></screen>
384     <variablelist>
385       <title>The meaning of the zic commands:</title>
387       <varlistentry>
388         <term><parameter>zic -L /dev/null ...</parameter></term>
389         <listitem>
390           <para>This creates posix time zones, without any leap seconds.  It is
391           conventional to put these in both
392           <filename class="directory">zoneinfo</filename> and
393           <filename class="directory">zoneinfo/posix</filename>. It is
394           necessary to put the POSIX time zones in
395           <filename class="directory">zoneinfo</filename>, otherwise various
396           test-suites will report errors. On an embedded system, where space is
397           tight and you do not intend to ever update the time zones, you could save
398           1.9MB by not using the <filename class="directory">posix</filename>
399           directory, but some applications or test-suites might produce some
400           failures.</para>
401         </listitem>
402       </varlistentry>
403       <varlistentry>
404         <term><parameter>zic -L leapseconds ...</parameter></term>
405         <listitem>
406           <para>This creates right time zones, including leap seconds. On an
407           embedded system, where space is tight and you do not intend to
408           ever update the time zones, or care about the correct time, you could
409           save 1.9MB by omitting the <filename class="directory">right</filename>
410           directory.</para>
411         </listitem>
412       </varlistentry>
413       <varlistentry>
414         <term><parameter>zic ... -p ...</parameter></term>
415         <listitem>
416           <para>This creates the <filename>posixrules</filename> file. We use
417           New York because POSIX requires the daylight savings time rules
418           to be in accordance with US rules.</para>
419         </listitem>
420       </varlistentry>
421     </variablelist>
424     <para>One way to determine the local time zone is to run the following
425     script:</para>
427 <screen role="nodump"><userinput>tzselect</userinput></screen>
429     <para>After answering a few questions about the location, the script will
430     output the name of the time zone (e.g.,
431     <emphasis>America/Edmonton</emphasis>). There are also some other possible
432     time zones listed in <filename
433     class='directory'>/usr/share/zoneinfo</filename> such as
434     <emphasis>Canada/Eastern</emphasis> or <emphasis>EST5EDT</emphasis> that
435     are not identified by the script but can be used.</para>
437     <para>Then create the <filename>/etc/localtime</filename> file by
438     running:</para>
440 <screen revision="sysv"><userinput>cp -v /usr/share/zoneinfo/<replaceable>&lt;xxx&gt;</replaceable> /etc/localtime</userinput></screen>
442 <screen revision="systemd"><userinput>ln -sfv /usr/share/zoneinfo/<replaceable>&lt;xxx&gt;</replaceable> /etc/localtime</userinput></screen>
444     <para>Replace <replaceable>&lt;xxx&gt;</replaceable> with the name of the
445     time zone selected (e.g., Canada/Eastern).</para>
447   </sect3>
449   <sect3 id="conf-ld" role="configuration">
450     <title>Configuring the Dynamic Loader</title>
452     <indexterm zone="conf-ld">
453       <primary sortas="e-/etc/ld.so.conf">/etc/ld.so.conf</primary>
454     </indexterm>
456     <para>By default, the dynamic loader (<filename
457     class="libraryfile">/lib/ld-linux.so.2</filename>) searches through
458     <filename class="directory">/lib</filename> and <filename
459     class="directory">/usr/lib</filename> for dynamic libraries that are
460     needed by programs as they are run. However, if there are libraries in
461     directories other than <filename class="directory">/lib</filename> and
462     <filename class="directory">/usr/lib</filename>, these need to be added
463     to the <filename>/etc/ld.so.conf</filename> file in order for the
464     dynamic loader to find them. Two directories that are commonly known
465     to contain additional libraries are <filename
466     class="directory">/usr/local/lib</filename> and <filename
467     class="directory">/opt/lib</filename>, so add those directories to the
468     dynamic loader's search path.</para>
470     <para>Create a new file <filename>/etc/ld.so.conf</filename> by running the
471     following:</para>
473 <screen><userinput>cat &gt; /etc/ld.so.conf &lt;&lt; "EOF"
474 <literal># Begin /etc/ld.so.conf
475 /usr/local/lib
476 /opt/lib
477 </literal>
478 EOF</userinput></screen>
480   <para>If desired, the dynamic loader can also search a directory and
481   include the contents of files found there.  Generally the files in
482   this include directory are one line specifying the desired library path.
483   To add this capability run the following commands:</para>
485 <screen role="nodump"><userinput>cat &gt;&gt; /etc/ld.so.conf &lt;&lt; "EOF"
486 <literal># Add an include directory
487 include /etc/ld.so.conf.d/*.conf
488 </literal>
490 mkdir -pv /etc/ld.so.conf.d</userinput></screen>
492   </sect3>
493   </sect2>
495   <sect2 id="contents-glibc" role="content">
496     <title>Contents of Glibc</title>
498     <segmentedlist>
499       <segtitle>Installed programs</segtitle>
500       <segtitle>Installed libraries</segtitle>
501       <segtitle>Installed directories</segtitle>
503       <seglistitem>
504         <seg>catchsegv, gencat, getconf, getent, iconv, iconvconfig, ldconfig,
505         ldd, lddlibc4, locale, localedef, makedb, mtrace, nscd, 
506         pcprofiledump, pldd, sln, sotruss, sprof, tzselect, xtrace,
507         zdump, and zic</seg>
508         <seg>ld-&glibc-version;.so, libBrokenLocale.{a,so}, libSegFault.so, libanl.{a,so},
509         libc.{a,so}, libc_nonshared.a,
510         libcrypt.{a,so}, libdl.{a,so}, libg.a, libm.{a,so},
511         libmcheck.a, libmemusage.so, libmvec.{a,so}, libnsl.{a,so},
512         libnss_compat.so, libnss_dns.so, libnss_files.so, libnss_hesiod.so,
513         libpcprofile.so, libpthread.{a,so},
514         libpthread_nonshared.a, libresolv.{a,so}, librt.{a,so},
515         libthread_db.so, and libutil.{a,so}</seg>
516         <seg>/usr/include/arpa, /usr/include/bits, /usr/include/gnu,
517         /usr/include/net, /usr/include/netash, /usr/include/netatalk,
518         /usr/include/netax25, /usr/include/neteconet, /usr/include/netinet,
519         /usr/include/netipx, /usr/include/netiucv, /usr/include/netpacket,
520         /usr/include/netrom, /usr/include/netrose, /usr/include/nfs,
521         /usr/include/protocols, /usr/include/rpc,
522         /usr/include/sys, /usr/lib/audit, /usr/lib/gconv, /usr/lib/locale,
523         /usr/libexec/getconf, /usr/share/i18n, /usr/share/zoneinfo,
524         /var/cache/nscd, and /var/lib/nss_db</seg>
525       </seglistitem>
526     </segmentedlist>
528     <variablelist>
529       <bridgehead renderas="sect3">Short Descriptions</bridgehead>
530       <?dbfo list-presentation="list"?>
531       <?dbhtml list-presentation="table"?>
533       <varlistentry id="catchsegv">
534         <term><command>catchsegv</command></term>
535         <listitem>
536           <para>Can be used to create a stack trace when a program
537           terminates with a segmentation fault</para>
538           <indexterm zone="ch-system-glibc catchsegv">
539             <primary sortas="b-catchsegv">catchsegv</primary>
540           </indexterm>
541         </listitem>
542       </varlistentry>
544       <varlistentry id="gencat">
545         <term><command>gencat</command></term>
546         <listitem>
547           <para>Generates message catalogues</para>
548           <indexterm zone="ch-system-glibc gencat">
549             <primary sortas="b-gencat">gencat</primary>
550           </indexterm>
551         </listitem>
552       </varlistentry>
554       <varlistentry id="getconf">
555         <term><command>getconf</command></term>
556         <listitem>
557           <para>Displays the system configuration values for file system
558           specific variables</para>
559           <indexterm zone="ch-system-glibc getconf">
560             <primary sortas="b-getconf">getconf</primary>
561           </indexterm>
562         </listitem>
563       </varlistentry>
565       <varlistentry id="getent">
566         <term><command>getent</command></term>
567         <listitem>
568           <para>Gets entries from an administrative database</para>
569           <indexterm zone="ch-system-glibc getent">
570             <primary sortas="b-getent">getent</primary>
571           </indexterm>
572         </listitem>
573       </varlistentry>
575       <varlistentry id="iconv">
576         <term><command>iconv</command></term>
577         <listitem>
578           <para>Performs character set conversion</para>
579           <indexterm zone="ch-system-glibc iconv">
580             <primary sortas="b-iconv">iconv</primary>
581           </indexterm>
582         </listitem>
583       </varlistentry>
585       <varlistentry id="iconvconfig">
586         <term><command>iconvconfig</command></term>
587         <listitem>
588           <para>Creates fastloading <command>iconv</command> module configuration
589           files</para>
590           <indexterm zone="ch-system-glibc iconvconfig">
591             <primary sortas="b-iconvconfig">iconvconfig</primary>
592           </indexterm>
593         </listitem>
594       </varlistentry>
596       <varlistentry id="ldconfig">
597         <term><command>ldconfig</command></term>
598         <listitem>
599           <para>Configures the dynamic linker runtime bindings</para>
600           <indexterm zone="ch-system-glibc ldconfig">
601             <primary sortas="b-ldconfig">ldconfig</primary>
602           </indexterm>
603         </listitem>
604       </varlistentry>
606       <varlistentry id="ldd">
607         <term><command>ldd</command></term>
608         <listitem>
609           <para>Reports which shared libraries are required
610           by each given program or shared library</para>
611           <indexterm zone="ch-system-glibc ldd">
612             <primary sortas="b-ldd">ldd</primary>
613           </indexterm>
614         </listitem>
615       </varlistentry>
617       <varlistentry id="lddlibc4">
618         <term><command>lddlibc4</command></term>
619         <listitem>
620           <para>Assists <command>ldd</command> with object files</para>
621           <indexterm zone="ch-system-glibc lddlibc4">
622             <primary sortas="b-lddlibc4">lddlibc4</primary>
623           </indexterm>
624         </listitem>
625       </varlistentry>
627       <varlistentry id="locale">
628         <term><command>locale</command></term>
629         <listitem>
630           <para>Prints various information about the current locale</para>
631           <indexterm zone="ch-system-glibc locale">
632             <primary sortas="b-locale">locale</primary>
633           </indexterm>
634         </listitem>
635       </varlistentry>
637       <varlistentry id="localedef">
638         <term><command>localedef</command></term>
639         <listitem>
640           <para>Compiles locale specifications</para>
641           <indexterm zone="ch-system-glibc localedef">
642             <primary sortas="b-localedef">localedef</primary>
643           </indexterm>
644         </listitem>
645       </varlistentry>
647       <varlistentry id="makedb">
648         <term><command>makedb</command></term>
649         <listitem>
650           <para>Creates a simple database from textual input</para>
651           <indexterm zone="ch-system-glibc makedb">
652             <primary sortas="b-makedb">makedb</primary>
653           </indexterm>
654         </listitem>
655       </varlistentry>
657       <varlistentry id="mtrace">
658         <term><command>mtrace</command></term>
659         <listitem>
660           <para>Reads and interprets a memory trace file and displays a summary
661           in human-readable format</para>
662           <indexterm zone="ch-system-glibc mtrace">
663             <primary sortas="b-mtrace">mtrace</primary>
664           </indexterm>
665         </listitem>
666       </varlistentry>
668       <varlistentry id="nscd">
669         <term><command>nscd</command></term>
670         <listitem>
671           <para>A daemon that provides a cache for the most common name
672           service requests</para>
673           <indexterm zone="ch-system-glibc nscd">
674             <primary sortas="b-nscd">nscd</primary>
675           </indexterm>
676         </listitem>
677       </varlistentry>
679       <varlistentry id="pcprofiledump">
680         <term><command>pcprofiledump</command></term>
681         <listitem>
682           <para>Dump information generated by PC profiling</para>
683           <indexterm zone="ch-system-glibc pcprofiledump">
684             <primary sortas="b-pcprofiledump">pcprofiledump</primary>
685           </indexterm>
686         </listitem>
687       </varlistentry>
689       <varlistentry id="pldd">
690         <term><command>pldd</command></term>
691         <listitem>
692           <para>Lists dynamic shared objects used by running processes</para>
693           <indexterm zone="ch-system-glibc pldd">
694             <primary sortas="b-pldd">pldd</primary>
695           </indexterm>
696         </listitem>
697       </varlistentry>
699       <varlistentry id="sln">
700         <term><command>sln</command></term>
701         <listitem>
702           <para>A statically linked <command>ln</command> program</para>
703           <indexterm zone="ch-system-glibc sln">
704             <primary sortas="b-sln">sln</primary>
705           </indexterm>
706         </listitem>
707       </varlistentry>
709       <varlistentry id="sotruss">
710         <term><command>sotruss</command></term>
711         <listitem>
712           <para>Traces shared library procedure calls of a specified command</para>
713           <indexterm zone="ch-system-glibc sotruss">
714             <primary sortas="b-sotruss">sotruss</primary>
715           </indexterm>
716         </listitem>
717       </varlistentry>
719       <varlistentry id="sprof">
720         <term><command>sprof</command></term>
721         <listitem>
722           <para>Reads and displays shared object profiling data</para>
723           <indexterm zone="ch-system-glibc sprof">
724             <primary sortas="b-sprof">sprof</primary>
725           </indexterm>
726         </listitem>
727       </varlistentry>
729       <varlistentry id="tzselect">
730         <term><command>tzselect</command></term>
731         <listitem>
732           <para>Asks the user about the location of the system and reports
733           the corresponding time zone description</para>
734           <indexterm zone="ch-system-glibc tzselect">
735             <primary sortas="b-tzselect">tzselect</primary>
736           </indexterm>
737         </listitem>
738       </varlistentry>
740       <varlistentry id="xtrace">
741         <term><command>xtrace</command></term>
742         <listitem>
743           <para>Traces the execution of a program by printing the currently
744           executed function</para>
745           <indexterm zone="ch-system-glibc xtrace">
746             <primary sortas="b-xtrace">xtrace</primary>
747           </indexterm>
748         </listitem>
749       </varlistentry>
751       <varlistentry id="zdump">
752         <term><command>zdump</command></term>
753         <listitem>
754           <para>The time zone dumper</para>
755           <indexterm zone="ch-system-glibc zdump">
756             <primary sortas="b-zdump">zdump</primary>
757           </indexterm>
758         </listitem>
759       </varlistentry>
761       <varlistentry id="zic">
762         <term><command>zic</command></term>
763         <listitem>
764           <para>The time zone compiler</para>
765           <indexterm zone="ch-system-glibc zic">
766             <primary sortas="b-zic">zic</primary>
767           </indexterm>
768         </listitem>
769       </varlistentry>
771       <varlistentry id="ld.so">
772         <term><filename class="libraryfile">ld-&glibc-version;.so</filename></term>
773         <listitem>
774           <para>The helper program for shared library executables</para>
775           <indexterm zone="ch-system-glibc ld.so">
776             <primary sortas="c-ld.so">ld-&glibc-version;.so</primary>
777           </indexterm>
778         </listitem>
779       </varlistentry>
781       <varlistentry id="libBrokenLocale">
782         <term><filename class="libraryfile">libBrokenLocale</filename></term>
783         <listitem>
784           <para>Used internally by Glibc as a gross hack to get broken programs
785           (e.g., some Motif applications) running. See comments in
786           <filename>glibc-&glibc-version;/locale/broken_cur_max.c</filename>
787           for more information</para>
788           <indexterm zone="ch-system-glibc libBrokenLocale">
789             <primary sortas="c-libBrokenLocale">libBrokenLocale</primary>
790           </indexterm>
791         </listitem>
792       </varlistentry>
794       <varlistentry id="libSegFault">
795         <term><filename class="libraryfile">libSegFault</filename></term>
796         <listitem>
797           <para>The segmentation fault signal handler, used by
798           <command>catchsegv</command></para>
799           <indexterm zone="ch-system-glibc libSegFault">
800             <primary sortas="c-libSegFault">libSegFault</primary>
801           </indexterm>
802         </listitem>
803       </varlistentry>
805       <varlistentry id="libanl">
806         <term><filename class="libraryfile">libanl</filename></term>
807         <listitem>
808           <para>An asynchronous name lookup library</para>
809           <indexterm zone="ch-system-glibc libanl">
810             <primary sortas="c-libanl">libanl</primary>
811           </indexterm>
812         </listitem>
813       </varlistentry>
815       <varlistentry id="libc">
816         <term><filename class="libraryfile">libc</filename></term>
817         <listitem>
818           <para>The main C library</para>
819           <indexterm zone="ch-system-glibc libc">
820             <primary sortas="c-libc">libc</primary>
821           </indexterm>
822         </listitem>
823       </varlistentry>
825       <varlistentry id="libcrypt">
826         <term><filename class="libraryfile">libcrypt</filename></term>
827         <listitem>
828           <para>The cryptography library</para>
829           <indexterm zone="ch-system-glibc libcrypt">
830             <primary sortas="c-libcrypt">libcrypt</primary>
831           </indexterm>
832         </listitem>
833       </varlistentry>
835       <varlistentry id="libdl">
836         <term><filename class="libraryfile">libdl</filename></term>
837         <listitem>
838           <para>The dynamic linking interface library</para>
839           <indexterm zone="ch-system-glibc libdl">
840             <primary sortas="c-libdl">libdl</primary>
841           </indexterm>
842         </listitem>
843       </varlistentry>
845       <varlistentry id="libg">
846         <term><filename class="libraryfile">libg</filename></term>
847         <listitem>
848           <para>Dummy library containing no functions. Previously was a runtime
849           library for <command>g++</command></para>
850           <indexterm zone="ch-system-glibc libg">
851             <primary sortas="c-libg">libg</primary>
852           </indexterm>
853         </listitem>
854       </varlistentry>
856       <varlistentry id="libm">
857         <term><filename class="libraryfile">libm</filename></term>
858         <listitem>
859           <para>The mathematical library</para>
860           <indexterm zone="ch-system-glibc libm">
861             <primary sortas="c-libm">libm</primary>
862           </indexterm>
863         </listitem>
864       </varlistentry>
866       <varlistentry id="libmcheck">
867         <term><filename class="libraryfile">libmcheck</filename></term>
868         <listitem>
869           <para>Turns on memory allocation checking when linked to</para>
870           <indexterm zone="ch-system-glibc libmcheck">
871             <primary sortas="c-libmcheck">libmcheck</primary>
872           </indexterm>
873         </listitem>
874       </varlistentry>
876       <varlistentry id="libmemusage">
877         <term><filename class="libraryfile">libmemusage</filename></term>
878         <listitem>
879           <para>Used by <command>memusage</command> to help collect
880           information about the memory usage of a program</para>
881           <indexterm zone="ch-system-glibc libmemusage">
882             <primary sortas="c-libmemusage">libmemusage</primary>
883           </indexterm>
884         </listitem>
885       </varlistentry>
887       <varlistentry id="libnsl">
888         <term><filename class="libraryfile">libnsl</filename></term>
889         <listitem>
890           <para>The network services library</para>
891           <indexterm zone="ch-system-glibc libnsl">
892             <primary sortas="c-libnsl">libnsl</primary>
893           </indexterm>
894         </listitem>
895       </varlistentry>
897       <varlistentry id="libnss">
898         <term><filename class="libraryfile">libnss</filename></term>
899         <listitem>
900           <para>The Name Service Switch libraries, containing functions for
901           resolving host names, user names, group names, aliases, services,
902           protocols, etc.</para>
903           <indexterm zone="ch-system-glibc libnss">
904             <primary sortas="c-libnss">libnss</primary>
905           </indexterm>
906         </listitem>
907       </varlistentry>
909       <varlistentry id="libpcprofile">
910         <term><filename class="libraryfile">libpcprofile</filename></term>
911         <listitem>
912           <para>Can be preloaded to PC profile an executable</para>
913           <indexterm zone="ch-system-glibc libpcprofile">
914             <primary sortas="c-libpcprofile">libpcprofile</primary>
915           </indexterm>
916         </listitem>
917       </varlistentry>
919       <varlistentry id="libpthread">
920         <term><filename class="libraryfile">libpthread</filename></term>
921         <listitem>
922           <para>The POSIX threads library</para>
923           <indexterm zone="ch-system-glibc libpthread">
924             <primary sortas="c-libpthread">libpthread</primary>
925           </indexterm>
926         </listitem>
927       </varlistentry>
929       <varlistentry id="libresolv">
930         <term><filename class="libraryfile">libresolv</filename></term>
931         <listitem>
932           <para>Contains functions for creating, sending, and interpreting
933           packets to the Internet domain name servers</para>
934           <indexterm zone="ch-system-glibc libresolv">
935             <primary sortas="c-libresolv">libresolv</primary>
936           </indexterm>
937         </listitem>
938       </varlistentry>
940       <varlistentry id="librt">
941         <term><filename class="libraryfile">librt</filename></term>
942         <listitem>
943           <para>Contains functions providing most of the interfaces specified
944           by the POSIX.1b Realtime Extension</para>
945           <indexterm zone="ch-system-glibc librt">
946             <primary sortas="c-librt">librt</primary>
947           </indexterm>
948         </listitem>
949       </varlistentry>
951       <varlistentry id="libthread_db">
952         <term><filename class="libraryfile">libthread_db</filename></term>
953         <listitem>
954           <para>Contains functions useful for building debuggers for
955           multi-threaded programs</para>
956           <indexterm zone="ch-system-glibc libthread_db">
957             <primary sortas="c-libthread_db">libthread_db</primary>
958           </indexterm>
959         </listitem>
960       </varlistentry>
962       <varlistentry id="libutil">
963         <term><filename class="libraryfile">libutil</filename></term>
964         <listitem>
965           <para>Contains code for <quote>standard</quote> functions used in
966           many different Unix utilities</para>
967           <indexterm zone="ch-system-glibc libutil">
968             <primary sortas="c-libutil">libutil</primary>
969           </indexterm>
970         </listitem>
971       </varlistentry>
973     </variablelist>
975   </sect2>
977 </sect1>