source: chapter08/glibc.xml@ b91b12a

12.1 12.1-rc1 12.2 12.2-rc1 multilib trunk xry111/arm64 xry111/clfs-ng xry111/loongarch xry111/loongarch-12.1 xry111/loongarch-12.2 xry111/mips64el xry111/multilib xry111/update-glibc
Last change on this file since b91b12a was 48d8f5a, checked in by Xi Ruoyao <xry111@…>, 13 months ago

glibc: Fix CVE-2023-4527

  • Property mode set to 100644
File size: 36.0 KB
Line 
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]>
7
8<sect1 id="ch-system-glibc" role="wrap">
9 <?dbhtml filename="glibc.html"?>
10
11 <sect1info condition="script">
12 <productname>glibc</productname>
13 <productnumber>&glibc-version;</productnumber>
14 <address>&glibc-url;</address>
15 </sect1info>
16
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>
36 <seg>&glibc-fin-sbu;</seg>
37 <seg>&glibc-fin-du;</seg>
38 </seglistitem>
39 </segmentedlist>
40
41 </sect2>
42
43 <sect2 role="installation">
44 <title>Installation of Glibc</title>
45
46 <para>Some of the Glibc programs use the non-FHS compliant
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>
52
53 <para>Now fix a regression causing the posix_memalign() function
54 to be very slow in some conditions:</para>
55
56<screen><userinput remap="pre">patch -Np1 -i ../&glibc-memalign-patch;</userinput></screen>
57
58 <!-- CVE-2023-4527
59 https://sourceware.org/bugzilla/show_bug.cgi?id=30842
60 https://sourceware.org/ml/libc-alpha/2023-September/151522.html -->
61 <para>Then fix a security vulnerability exploitable when the
62 <option>no-aaaa</option> option is used in
63 <filename>/etc/resolv.conf</filename>:</para>
64
65<screen><userinput remap="pre">sed \
66 -E "/__res_context_search/\
67 {N;N;s/(search \(([^,]*,){6}[^,]*)NULL/\1\&amp;alt_dns_packet_buffer/}" \
68 -i resolv/nss_dns/dns-host.c</userinput></screen>
69
70 <para>The Glibc documentation recommends building Glibc
71 in a dedicated build directory:</para>
72
73<screen><userinput remap="pre">mkdir -v build
74cd build</userinput></screen>
75
76 <para>Ensure that the <command>ldconfig</command> and <command>sln</command>
77 utilities will be installed into
78 <filename class="directory">/usr/sbin</filename>:</para>
79
80<screen><userinput remap="pre">echo "rootsbindir=/usr/sbin" &gt; configparms</userinput></screen>
81
82 <para>Prepare Glibc for compilation:</para>
83
84<screen><userinput remap="configure">../configure --prefix=/usr \
85 --disable-werror \
86 --enable-kernel=&min-kernel; \
87 --enable-stack-protector=strong \
88 --with-headers=/usr/include \
89 libc_cv_slibdir=/usr/lib</userinput></screen>
90
91 <variablelist>
92 <title>The meaning of the configure options:</title>
93
94 <varlistentry>
95 <term><parameter>--disable-werror</parameter></term>
96 <listitem>
97 <para>This option disables the -Werror option passed to
98 GCC. This is necessary for running the test suite.</para>
99 </listitem>
100 </varlistentry>
101
102 <varlistentry>
103 <term><parameter>--enable-kernel=&min-kernel;</parameter></term>
104 <listitem>
105 <para>This option tells the build system that this Glibc may
106 be used with kernels as old as &min-kernel;. This means generating
107 workarounds in case a system call introduced in a later version
108 cannot be used.</para>
109 </listitem>
110 </varlistentry>
111
112 <varlistentry>
113 <term><parameter>--enable-stack-protector=strong</parameter></term>
114 <listitem>
115 <para>This option increases system security by adding
116 extra code to check for buffer overflows, such as stack
117 smashing attacks.</para>
118 </listitem>
119 </varlistentry>
120<!-- do we need this one? -->
121 <varlistentry>
122 <term><parameter>--with-headers=/usr/include</parameter></term>
123 <listitem>
124 <para>This option tells the build system where to find the
125 kernel API headers.</para>
126 </listitem>
127 </varlistentry>
128
129 <varlistentry>
130 <term><parameter>libc_cv_slibdir=/usr/lib</parameter></term>
131 <listitem>
132 <para>This variable sets the correct library for all
133 systems. We do not want lib64 to be used.</para>
134 </listitem>
135 </varlistentry>
136
137 </variablelist>
138
139 <para>Compile the package:</para>
140
141<screen><userinput remap="make">make</userinput></screen>
142
143 <important>
144 <para>In this section, the test suite for Glibc is considered critical.
145 Do not skip it under any circumstance.</para>
146 </important>
147
148 <para>Generally a few tests do not pass. The test failures listed below
149 are usually safe to ignore.</para>
150
151<!-- Use remap="make" here to work around a jhalfs issue. -->
152<!--<screen><userinput remap="make">case $(uname -m) in
153 i?86) ln -sfnv $PWD/elf/ld-linux.so.2 /lib ;;
154 x86_64) ln -sfnv $PWD/elf/ld-linux-x86-64.so.2 /lib ;;
155esac</userinput></screen>
156
157 <note><para>The symbolic link above is needed to run the tests at this
158 stage of building in the chroot environment. It will be overwritten
159 in the install phase below.</para></note>
160-->
161<screen><userinput remap="test">make check</userinput></screen>
162
163 <para>You may see some test failures. The Glibc test suite is
164 somewhat dependent on the host system. A few failures out of
165 over 5000 tests can generally be ignored. This is a list of the
166 most common issues seen for recent versions of LFS:</para>
167
168 <itemizedlist>
169
170 <listitem>
171 <para><emphasis>io/tst-lchmod</emphasis>
172 is known to fail in the LFS chroot environment.</para>
173 </listitem>
174
175<!-- Did not fail with glibc-2.38
176 <listitem>
177 <para><emphasis>misc/tst-ttyname</emphasis>
178 is known to fail in the LFS chroot environment.</para>
179 </listitem>
180-->
181
182 <!-- https://sourceware.org/pipermail/libc-alpha/2022-August/141567.html -->
183 <listitem>
184 <para>The <emphasis>stdlib/tst-arc4random-thread</emphasis>
185 test is known to fail if the host kernel is relatively old.</para>
186 </listitem>
187
188 <listitem>
189 <para>Some tests, for example
190 <emphasis>nss/tst-nss-files-hosts-multi</emphasis>,
191 are known to fail on relatively slow systems due to an internal
192 timeout.</para>
193 </listitem>
194
195 <listitem>
196 <para>Additionally, some tests may fail with a relatively old CPU
197 model or host kernel version.</para>
198 </listitem>
199 </itemizedlist>
200
201 <para>Though it is a harmless message, the install stage of Glibc will
202 complain about the absence of <filename>/etc/ld.so.conf</filename>.
203 Prevent this warning with:</para>
204
205<screen><userinput remap="install">touch /etc/ld.so.conf</userinput></screen>
206
207 <!-- https://sourceware.org/bugzilla/show_bug.cgi?id=21911 -->
208 <para>Fix the Makefile to skip an outdated sanity check
209 that fails with a modern Glibc configuration:</para>
210
211<screen><userinput remap="install">sed '/test-installation/s@$(PERL)@echo not running@' -i ../Makefile</userinput></screen>
212
213 <para>Install the package:</para>
214
215<screen><userinput remap="install">make install</userinput></screen>
216
217 <para>Fix a hardcoded path to the executable loader in the
218 <command>ldd</command> script:</para>
219
220<screen><userinput remap="install">sed '/RTLDLIST=/s@/usr@@g' -i /usr/bin/ldd</userinput></screen>
221
222 <para>Install the configuration file and runtime directory for
223 <command>nscd</command>:</para>
224
225<screen><userinput remap="install">cp -v ../nscd/nscd.conf /etc/nscd.conf
226mkdir -pv /var/cache/nscd</userinput></screen>
227
228 <para revision="systemd">Install the systemd support files for
229 <command>nscd</command>:</para>
230
231 <screen revision="systemd"><userinput remap="install">install -v -Dm644 ../nscd/nscd.tmpfiles /usr/lib/tmpfiles.d/nscd.conf
232install -v -Dm644 ../nscd/nscd.service /usr/lib/systemd/system/nscd.service</userinput></screen>
233
234 <para>Next, install the locales that can make the system respond in a
235 different language. None of these locales are required, but if some of them
236 are missing, the test suites of some packages will skip important
237 test cases.</para>
238
239 <para>Individual locales can be installed using the
240 <command>localedef</command> program. E.g., the second
241 <command>localedef</command> command below combines the
242 <filename>/usr/share/i18n/locales/cs_CZ</filename>
243 charset-independent locale definition with the
244 <filename>/usr/share/i18n/charmaps/UTF-8.gz</filename>
245 charmap definition and appends the result to the
246 <filename>/usr/lib/locale/locale-archive</filename> file.
247 The following instructions will install the minimum set of
248 locales necessary for the optimal coverage of tests:</para>
249
250<screen role="nodump"><userinput remap="locale-test">mkdir -pv /usr/lib/locale
251localedef -i POSIX -f UTF-8 C.UTF-8 2> /dev/null || true
252localedef -i cs_CZ -f UTF-8 cs_CZ.UTF-8
253localedef -i de_DE -f ISO-8859-1 de_DE
254localedef -i de_DE@euro -f ISO-8859-15 de_DE@euro
255localedef -i de_DE -f UTF-8 de_DE.UTF-8
256localedef -i el_GR -f ISO-8859-7 el_GR
257localedef -i en_GB -f ISO-8859-1 en_GB
258localedef -i en_GB -f UTF-8 en_GB.UTF-8
259localedef -i en_HK -f ISO-8859-1 en_HK
260localedef -i en_PH -f ISO-8859-1 en_PH
261localedef -i en_US -f ISO-8859-1 en_US
262localedef -i en_US -f UTF-8 en_US.UTF-8
263localedef -i es_ES -f ISO-8859-15 es_ES@euro
264localedef -i es_MX -f ISO-8859-1 es_MX
265localedef -i fa_IR -f UTF-8 fa_IR
266localedef -i fr_FR -f ISO-8859-1 fr_FR
267localedef -i fr_FR@euro -f ISO-8859-15 fr_FR@euro
268localedef -i fr_FR -f UTF-8 fr_FR.UTF-8
269localedef -i is_IS -f ISO-8859-1 is_IS
270localedef -i is_IS -f UTF-8 is_IS.UTF-8
271localedef -i it_IT -f ISO-8859-1 it_IT
272localedef -i it_IT -f ISO-8859-15 it_IT@euro
273localedef -i it_IT -f UTF-8 it_IT.UTF-8
274localedef -i ja_JP -f EUC-JP ja_JP
275localedef -i ja_JP -f SHIFT_JIS ja_JP.SJIS 2> /dev/null || true
276localedef -i ja_JP -f UTF-8 ja_JP.UTF-8
277localedef -i nl_NL@euro -f ISO-8859-15 nl_NL@euro
278localedef -i ru_RU -f KOI8-R ru_RU.KOI8-R
279localedef -i ru_RU -f UTF-8 ru_RU.UTF-8
280localedef -i se_NO -f UTF-8 se_NO.UTF-8
281localedef -i ta_IN -f UTF-8 ta_IN.UTF-8
282localedef -i tr_TR -f UTF-8 tr_TR.UTF-8
283localedef -i zh_CN -f GB18030 zh_CN.GB18030
284localedef -i zh_HK -f BIG5-HKSCS zh_HK.BIG5-HKSCS
285localedef -i zh_TW -f UTF-8 zh_TW.UTF-8</userinput></screen>
286
287 <para>In addition, install the locale for your own country, language and
288 character set.</para>
289
290 <para>Alternatively, install all the locales listed in the
291 <filename>glibc-&glibc-version;/localedata/SUPPORTED</filename> file
292 (it includes every locale listed above and many more) at once with the
293 following time-consuming command:</para>
294
295<screen><userinput remap="locale-full">make localedata/install-locales</userinput></screen>
296
297 <para>Then use the <command>localedef</command> command to create and
298 install locales not listed in the
299 <filename>glibc-&glibc-version;/localedata/SUPPORTED</filename> file
300 when you need them. For instance, the following two locales are
301 needed for some tests later in this chapter:</para>
302
303<screen role="nodump"><userinput remap="locale-full">localedef -i POSIX -f UTF-8 C.UTF-8 2> /dev/null || true
304localedef -i ja_JP -f SHIFT_JIS ja_JP.SJIS 2> /dev/null || true</userinput></screen>
305
306 <note><para>Glibc now uses libidn2 when resolving internationalized
307 domain names. This is a run time dependency. If this capability
308 is needed, the instructions for installing libidn2 are in the
309 <ulink url="&blfs-book;general/libidn2.html">BLFS libidn2 page</ulink>.
310 </para></note>
311
312 </sect2>
313
314 <sect2 id="conf-glibc" role="configuration">
315 <title>Configuring Glibc</title>
316
317 <indexterm zone="conf-glibc">
318 <primary sortas="e-/etc/nsswitch.conf">/etc/nsswitch.conf</primary>
319 </indexterm>
320
321 <indexterm zone="conf-glibc">
322 <primary sortas="e-/etc/localtime">/etc/localtime</primary>
323 </indexterm>
324
325 <sect3>
326 <title>Adding nsswitch.conf</title>
327
328 <para>The <filename>/etc/nsswitch.conf</filename> file needs to be created
329 because the Glibc defaults do not work well in a networked environment.
330 </para>
331
332 <para>Create a new file <filename>/etc/nsswitch.conf</filename> by running the
333 following:</para>
334
335<screen><userinput>cat &gt; /etc/nsswitch.conf &lt;&lt; "EOF"
336<literal># Begin /etc/nsswitch.conf
337
338passwd: files
339group: files
340shadow: files
341
342hosts: files dns
343networks: files
344
345protocols: files
346services: files
347ethers: files
348rpc: files
349
350# End /etc/nsswitch.conf</literal>
351EOF</userinput></screen>
352
353 </sect3>
354
355 <sect3>
356 <title>Adding Time Zone Data</title>
357
358 <para>Install and set up the time zone data with the following:</para>
359<screen><userinput>tar -xf ../../tzdata&tzdata-version;.tar.gz
360
361ZONEINFO=/usr/share/zoneinfo
362mkdir -pv $ZONEINFO/{posix,right}
363
364for tz in etcetera southamerica northamerica europe africa antarctica \
365 asia australasia backward; do
366 zic -L /dev/null -d $ZONEINFO ${tz}
367 zic -L /dev/null -d $ZONEINFO/posix ${tz}
368 zic -L leapseconds -d $ZONEINFO/right ${tz}
369done
370
371cp -v zone.tab zone1970.tab iso3166.tab $ZONEINFO
372zic -d $ZONEINFO -p America/New_York
373unset ZONEINFO</userinput></screen>
374
375 <variablelist>
376 <title>The meaning of the zic commands:</title>
377
378 <varlistentry>
379 <term><parameter>zic -L /dev/null ...</parameter></term>
380 <listitem>
381 <para>This creates posix time zones without any leap seconds. It is
382 conventional to put these in both
383 <filename class="directory">zoneinfo</filename> and
384 <filename class="directory">zoneinfo/posix</filename>. It is
385 necessary to put the POSIX time zones in
386 <filename class="directory">zoneinfo</filename>, otherwise various
387 test suites will report errors. On an embedded system, where space is
388 tight and you do not intend to ever update the time zones, you could save
389 1.9 MB by not using the <filename class="directory">posix</filename>
390 directory, but some applications or test suites might produce some
391 failures.</para>
392 </listitem>
393 </varlistentry>
394 <varlistentry>
395 <term><parameter>zic -L leapseconds ...</parameter></term>
396 <listitem>
397 <para>This creates right time zones, including leap seconds. On an
398 embedded system, where space is tight and you do not intend to
399 ever update the time zones, or care about the correct time, you could
400 save 1.9MB by omitting the <filename class="directory">right</filename>
401 directory.</para>
402 </listitem>
403 </varlistentry>
404 <varlistentry>
405 <term><parameter>zic ... -p ...</parameter></term>
406 <listitem>
407 <para>This creates the <filename>posixrules</filename> file. We use
408 New York because POSIX requires the daylight savings time rules
409 to be in accordance with US rules.</para>
410 </listitem>
411 </varlistentry>
412 </variablelist>
413
414
415 <para>One way to determine the local time zone is to run the following
416 script:</para>
417
418<screen role="nodump"><userinput>tzselect</userinput></screen>
419
420 <para>After answering a few questions about the location, the script will
421 output the name of the time zone (e.g.,
422 <emphasis>America/Edmonton</emphasis>). There are also some other possible
423 time zones listed in <filename
424 class='directory'>/usr/share/zoneinfo</filename> such as
425 <emphasis>Canada/Eastern</emphasis> or <emphasis>EST5EDT</emphasis> that
426 are not identified by the script but can be used.</para>
427
428 <para>Then create the <filename>/etc/localtime</filename> file by
429 running:</para>
430
431<screen><userinput>ln -sfv /usr/share/zoneinfo/<replaceable>&lt;xxx&gt;</replaceable> /etc/localtime</userinput></screen>
432
433 <para>Replace <replaceable>&lt;xxx&gt;</replaceable> with the name of the
434 time zone selected (e.g., Canada/Eastern).</para>
435
436 </sect3>
437
438 <sect3 id="conf-ld" role="configuration">
439 <title>Configuring the Dynamic Loader</title>
440
441 <indexterm zone="conf-ld">
442 <primary sortas="e-/etc/ld.so.conf">/etc/ld.so.conf</primary>
443 </indexterm>
444
445 <para>By default, the dynamic loader (<filename
446 class="libraryfile">/lib/ld-linux.so.2</filename>) searches through
447 <filename class="directory">/usr/lib</filename> for dynamic libraries
448 that are needed by programs as they are run. However, if there are
449 libraries in directories other than
450 <filename class="directory">/usr/lib</filename>, these need to be added
451 to the <filename>/etc/ld.so.conf</filename> file in order for the
452 dynamic loader to find them. Two directories that are commonly known
453 to contain additional libraries are <filename
454 class="directory">/usr/local/lib</filename> and <filename
455 class="directory">/opt/lib</filename>, so add those directories to the
456 dynamic loader's search path.</para>
457
458 <para>Create a new file <filename>/etc/ld.so.conf</filename> by running the
459 following:</para>
460
461<screen><userinput>cat &gt; /etc/ld.so.conf &lt;&lt; "EOF"
462<literal># Begin /etc/ld.so.conf
463/usr/local/lib
464/opt/lib
465</literal>
466EOF</userinput></screen>
467
468 <para>If desired, the dynamic loader can also search a directory and
469 include the contents of files found there. Generally the files in
470 this include directory are one line specifying the desired library path.
471 To add this capability run the following commands:</para>
472
473<screen role="nodump"><userinput>cat &gt;&gt; /etc/ld.so.conf &lt;&lt; "EOF"
474<literal># Add an include directory
475include /etc/ld.so.conf.d/*.conf
476</literal>
477EOF
478mkdir -pv /etc/ld.so.conf.d</userinput></screen>
479
480 </sect3>
481 </sect2>
482
483 <sect2 id="contents-glibc" role="content">
484 <title>Contents of Glibc</title>
485
486 <segmentedlist>
487 <segtitle>Installed programs</segtitle>
488 <segtitle>Installed libraries</segtitle>
489 <segtitle>Installed directories</segtitle>
490
491 <seglistitem>
492 <seg>gencat, getconf, getent, iconv, iconvconfig, ldconfig,
493 ldd, lddlibc4,
494 ld.so (symlink to ld-linux-x86-64.so.2 or ld-linux.so.2),
495 locale, localedef, makedb, mtrace, nscd,
496 pcprofiledump, pldd, sln, sotruss, sprof, tzselect, xtrace,
497 zdump, and zic</seg>
498 <seg>ld-linux-x86-64.so.2, ld-linux.so.2,
499 libBrokenLocale.{a,so}, libanl.{a,so},
500 libc.{a,so}, libc_nonshared.a, libc_malloc_debug.so,
501 libdl.{a,so.2}, libg.a, libm.{a,so},
502 libmcheck.a, libmemusage.so, libmvec.{a,so}, libnsl.so.1,
503 libnss_compat.so, libnss_dns.so, libnss_files.so, libnss_hesiod.so,
504 libpcprofile.so, libpthread.{a,so.0},
505 libresolv.{a,so}, librt.{a,so.1},
506 libthread_db.so, and libutil.{a,so.1}</seg>
507 <seg>/usr/include/arpa, /usr/include/bits, /usr/include/gnu,
508 /usr/include/net, /usr/include/netash, /usr/include/netatalk,
509 /usr/include/netax25, /usr/include/neteconet, /usr/include/netinet,
510 /usr/include/netipx, /usr/include/netiucv, /usr/include/netpacket,
511 /usr/include/netrom, /usr/include/netrose, /usr/include/nfs,
512 /usr/include/protocols, /usr/include/rpc,
513 /usr/include/sys, /usr/lib/audit, /usr/lib/gconv, /usr/lib/locale,
514 /usr/libexec/getconf, /usr/share/i18n, /usr/share/zoneinfo,
515 /var/cache/nscd, and /var/lib/nss_db</seg>
516 </seglistitem>
517 </segmentedlist>
518
519 <variablelist>
520 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
521 <?dbfo list-presentation="list"?>
522 <?dbhtml list-presentation="table"?>
523
524 <varlistentry id="gencat">
525 <term><command>gencat</command></term>
526 <listitem>
527 <para>Generates message catalogues</para>
528 <indexterm zone="ch-system-glibc gencat">
529 <primary sortas="b-gencat">gencat</primary>
530 </indexterm>
531 </listitem>
532 </varlistentry>
533
534 <varlistentry id="getconf">
535 <term><command>getconf</command></term>
536 <listitem>
537 <para>Displays the system configuration values for file system
538 specific variables</para>
539 <indexterm zone="ch-system-glibc getconf">
540 <primary sortas="b-getconf">getconf</primary>
541 </indexterm>
542 </listitem>
543 </varlistentry>
544
545 <varlistentry id="getent">
546 <term><command>getent</command></term>
547 <listitem>
548 <para>Gets entries from an administrative database</para>
549 <indexterm zone="ch-system-glibc getent">
550 <primary sortas="b-getent">getent</primary>
551 </indexterm>
552 </listitem>
553 </varlistentry>
554
555 <varlistentry id="iconv">
556 <term><command>iconv</command></term>
557 <listitem>
558 <para>Performs character set conversion</para>
559 <indexterm zone="ch-system-glibc iconv">
560 <primary sortas="b-iconv">iconv</primary>
561 </indexterm>
562 </listitem>
563 </varlistentry>
564
565 <varlistentry id="iconvconfig">
566 <term><command>iconvconfig</command></term>
567 <listitem>
568 <para>Creates fastloading <command>iconv</command> module configuration
569 files</para>
570 <indexterm zone="ch-system-glibc iconvconfig">
571 <primary sortas="b-iconvconfig">iconvconfig</primary>
572 </indexterm>
573 </listitem>
574 </varlistentry>
575
576 <varlistentry id="ldconfig">
577 <term><command>ldconfig</command></term>
578 <listitem>
579 <para>Configures the dynamic linker runtime bindings</para>
580 <indexterm zone="ch-system-glibc ldconfig">
581 <primary sortas="b-ldconfig">ldconfig</primary>
582 </indexterm>
583 </listitem>
584 </varlistentry>
585
586 <varlistentry id="ldd">
587 <term><command>ldd</command></term>
588 <listitem>
589 <para>Reports which shared libraries are required
590 by each given program or shared library</para>
591 <indexterm zone="ch-system-glibc ldd">
592 <primary sortas="b-ldd">ldd</primary>
593 </indexterm>
594 </listitem>
595 </varlistentry>
596
597 <varlistentry id="lddlibc4">
598 <term><command>lddlibc4</command></term>
599 <listitem>
600 <para>Assists <command>ldd</command> with object files.
601 It does not exist on newer architectures like x86_64</para>
602 <indexterm zone="ch-system-glibc lddlibc4">
603 <primary sortas="b-lddlibc4">lddlibc4</primary>
604 </indexterm>
605 </listitem>
606 </varlistentry>
607
608 <varlistentry id="locale">
609 <term><command>locale</command></term>
610 <listitem>
611 <para>Prints various information about the current locale</para>
612 <indexterm zone="ch-system-glibc locale">
613 <primary sortas="b-locale">locale</primary>
614 </indexterm>
615 </listitem>
616 </varlistentry>
617
618 <varlistentry id="localedef">
619 <term><command>localedef</command></term>
620 <listitem>
621 <para>Compiles locale specifications</para>
622 <indexterm zone="ch-system-glibc localedef">
623 <primary sortas="b-localedef">localedef</primary>
624 </indexterm>
625 </listitem>
626 </varlistentry>
627
628 <varlistentry id="makedb">
629 <term><command>makedb</command></term>
630 <listitem>
631 <para>Creates a simple database from textual input</para>
632 <indexterm zone="ch-system-glibc makedb">
633 <primary sortas="b-makedb">makedb</primary>
634 </indexterm>
635 </listitem>
636 </varlistentry>
637
638 <varlistentry id="mtrace">
639 <term><command>mtrace</command></term>
640 <listitem>
641 <para>Reads and interprets a memory trace file and displays a summary
642 in human-readable format</para>
643 <indexterm zone="ch-system-glibc mtrace">
644 <primary sortas="b-mtrace">mtrace</primary>
645 </indexterm>
646 </listitem>
647 </varlistentry>
648
649 <varlistentry id="nscd">
650 <term><command>nscd</command></term>
651 <listitem>
652 <para>A daemon that provides a cache for the most common name
653 service requests</para>
654 <indexterm zone="ch-system-glibc nscd">
655 <primary sortas="b-nscd">nscd</primary>
656 </indexterm>
657 </listitem>
658 </varlistentry>
659
660 <varlistentry id="pcprofiledump">
661 <term><command>pcprofiledump</command></term>
662 <listitem>
663 <para>Dump information generated by PC profiling</para>
664 <indexterm zone="ch-system-glibc pcprofiledump">
665 <primary sortas="b-pcprofiledump">pcprofiledump</primary>
666 </indexterm>
667 </listitem>
668 </varlistentry>
669
670 <varlistentry id="pldd">
671 <term><command>pldd</command></term>
672 <listitem>
673 <para>Lists dynamic shared objects used by running processes</para>
674 <indexterm zone="ch-system-glibc pldd">
675 <primary sortas="b-pldd">pldd</primary>
676 </indexterm>
677 </listitem>
678 </varlistentry>
679
680 <varlistentry id="sln">
681 <term><command>sln</command></term>
682 <listitem>
683 <para>A statically linked <command>ln</command> program</para>
684 <indexterm zone="ch-system-glibc sln">
685 <primary sortas="b-sln">sln</primary>
686 </indexterm>
687 </listitem>
688 </varlistentry>
689
690 <varlistentry id="sotruss">
691 <term><command>sotruss</command></term>
692 <listitem>
693 <para>Traces shared library procedure calls of a specified command</para>
694 <indexterm zone="ch-system-glibc sotruss">
695 <primary sortas="b-sotruss">sotruss</primary>
696 </indexterm>
697 </listitem>
698 </varlistentry>
699
700 <varlistentry id="sprof">
701 <term><command>sprof</command></term>
702 <listitem>
703 <para>Reads and displays shared object profiling data</para>
704 <indexterm zone="ch-system-glibc sprof">
705 <primary sortas="b-sprof">sprof</primary>
706 </indexterm>
707 </listitem>
708 </varlistentry>
709
710 <varlistentry id="tzselect">
711 <term><command>tzselect</command></term>
712 <listitem>
713 <para>Asks the user about the location of the system and reports
714 the corresponding time zone description</para>
715 <indexterm zone="ch-system-glibc tzselect">
716 <primary sortas="b-tzselect">tzselect</primary>
717 </indexterm>
718 </listitem>
719 </varlistentry>
720
721 <varlistentry id="xtrace">
722 <term><command>xtrace</command></term>
723 <listitem>
724 <para>Traces the execution of a program by printing the currently
725 executed function</para>
726 <indexterm zone="ch-system-glibc xtrace">
727 <primary sortas="b-xtrace">xtrace</primary>
728 </indexterm>
729 </listitem>
730 </varlistentry>
731
732 <varlistentry id="zdump">
733 <term><command>zdump</command></term>
734 <listitem>
735 <para>The time zone dumper</para>
736 <indexterm zone="ch-system-glibc zdump">
737 <primary sortas="b-zdump">zdump</primary>
738 </indexterm>
739 </listitem>
740 </varlistentry>
741
742 <varlistentry id="zic">
743 <term><command>zic</command></term>
744 <listitem>
745 <para>The time zone compiler</para>
746 <indexterm zone="ch-system-glibc zic">
747 <primary sortas="b-zic">zic</primary>
748 </indexterm>
749 </listitem>
750 </varlistentry>
751
752 <varlistentry id="ld.so">
753 <term><filename class="libraryfile">ld-*.so</filename></term>
754 <listitem>
755 <para>The helper program for shared library executables</para>
756 <indexterm zone="ch-system-glibc ld.so">
757 <primary sortas="c-ld.so">ld-&glibc-version;.so</primary>
758 </indexterm>
759 </listitem>
760 </varlistentry>
761
762 <varlistentry id="libBrokenLocale">
763 <term><filename class="libraryfile">libBrokenLocale</filename></term>
764 <listitem>
765 <para>Used internally by Glibc as a gross hack to get broken programs
766 (e.g., some Motif applications) running. See comments in
767 <filename>glibc-&glibc-version;/locale/broken_cur_max.c</filename>
768 for more information</para>
769 <indexterm zone="ch-system-glibc libBrokenLocale">
770 <primary sortas="c-libBrokenLocale">libBrokenLocale</primary>
771 </indexterm>
772 </listitem>
773 </varlistentry>
774
775 <varlistentry id="libanl">
776 <term><filename class="libraryfile">libanl</filename></term>
777 <listitem>
778 <para>Dummy library containing no functions. Previously was the
779 asynchronous name lookup library, whose functions are now in
780 <filename class='libraryfile'>libc</filename></para>
781 <indexterm zone="ch-system-glibc libanl">
782 <primary sortas="c-libanl">libanl</primary>
783 </indexterm>
784 </listitem>
785 </varlistentry>
786
787 <varlistentry id="libc">
788 <term><filename class="libraryfile">libc</filename></term>
789 <listitem>
790 <para>The main C library</para>
791 <indexterm zone="ch-system-glibc libc">
792 <primary sortas="c-libc">libc</primary>
793 </indexterm>
794 </listitem>
795 </varlistentry>
796
797 <varlistentry id="libc_malloc_debug">
798 <term><filename class="libraryfile">libc_malloc_debug</filename></term>
799 <listitem>
800 <para>Turns on memory allocation checking when preloaded</para>
801 <indexterm zone="ch-system-glibc libc_malloc_debug">
802 <primary sortas="c-libc_malloc_debug">libc_malloc_debug</primary>
803 </indexterm>
804 </listitem>
805 </varlistentry>
806
807 <varlistentry id="libdl">
808 <term><filename class="libraryfile">libdl</filename></term>
809 <listitem>
810 <para>Dummy library containing no functions. Previously was the
811 dynamic linking interface library, whose functions are now in
812 <filename class="libraryfile">libc</filename></para>
813 <indexterm zone="ch-system-glibc libdl">
814 <primary sortas="c-libdl">libdl</primary>
815 </indexterm>
816 </listitem>
817 </varlistentry>
818
819 <varlistentry id="libg">
820 <term><filename class="libraryfile">libg</filename></term>
821 <listitem>
822 <para>Dummy library containing no functions. Previously was a runtime
823 library for <command>g++</command></para>
824 <indexterm zone="ch-system-glibc libg">
825 <primary sortas="c-libg">libg</primary>
826 </indexterm>
827 </listitem>
828 </varlistentry>
829
830 <varlistentry id="libm">
831 <term><filename class="libraryfile">libm</filename></term>
832 <listitem>
833 <para>The mathematical library</para>
834 <indexterm zone="ch-system-glibc libm">
835 <primary sortas="c-libm">libm</primary>
836 </indexterm>
837 </listitem>
838 </varlistentry>
839
840 <varlistentry id="libmvec">
841 <term><filename class="libraryfile">libmvec</filename></term>
842 <listitem>
843 <para>The vector math library, linked in as needed
844 when <filename class='libraryfile'>libm</filename> is used</para>
845 <indexterm zone="ch-system-glibc libmvec">
846 <primary sortas="c-libmvec">libmvec</primary>
847 </indexterm>
848 </listitem>
849 </varlistentry>
850
851 <varlistentry id="libmcheck">
852 <term><filename class="libraryfile">libmcheck</filename></term>
853 <listitem>
854 <para>Turns on memory allocation checking when linked to</para>
855 <indexterm zone="ch-system-glibc libmcheck">
856 <primary sortas="c-libmcheck">libmcheck</primary>
857 </indexterm>
858 </listitem>
859 </varlistentry>
860
861 <varlistentry id="libmemusage">
862 <term><filename class="libraryfile">libmemusage</filename></term>
863 <listitem>
864 <para>Used by <command>memusage</command> to help collect
865 information about the memory usage of a program</para>
866 <indexterm zone="ch-system-glibc libmemusage">
867 <primary sortas="c-libmemusage">libmemusage</primary>
868 </indexterm>
869 </listitem>
870 </varlistentry>
871
872 <varlistentry id="libnsl">
873 <term><filename class="libraryfile">libnsl</filename></term>
874 <listitem>
875 <para>The network services library, now deprecated</para>
876 <indexterm zone="ch-system-glibc libnsl">
877 <primary sortas="c-libnsl">libnsl</primary>
878 </indexterm>
879 </listitem>
880 </varlistentry>
881
882 <varlistentry id="libnss">
883 <term><filename class="libraryfile">libnss_*</filename></term>
884 <listitem>
885 <para>The Name Service Switch modules, containing functions for
886 resolving host names, user names, group names, aliases, services,
887 protocols, etc. Loaded by
888 <filename class='libraryfile'>libc</filename> according to the
889 configuration in <filename>/etc/nsswitch.conf</filename></para>
890 <indexterm zone="ch-system-glibc libnss">
891 <primary sortas="c-libnss">libnss_*</primary>
892 </indexterm>
893 </listitem>
894 </varlistentry>
895
896 <varlistentry id="libpcprofile">
897 <term><filename class="libraryfile">libpcprofile</filename></term>
898 <listitem>
899 <para>Can be preloaded to PC profile an executable</para>
900 <indexterm zone="ch-system-glibc libpcprofile">
901 <primary sortas="c-libpcprofile">libpcprofile</primary>
902 </indexterm>
903 </listitem>
904 </varlistentry>
905
906 <varlistentry id="libpthread">
907 <term><filename class="libraryfile">libpthread</filename></term>
908 <listitem>
909 <para>Dummy library containing no functions. Previously contained
910 functions providing most of the interfaces specified
911 by the POSIX.1c Threads Extensions and the semaphore interfaces
912 specified by the POSIX.1b Real-time Extensions, now the functions
913 are in <filename class="libraryfile">libc</filename></para>
914 <indexterm zone="ch-system-glibc libpthread">
915 <primary sortas="c-libpthread">libpthread</primary>
916 </indexterm>
917 </listitem>
918 </varlistentry>
919
920 <varlistentry id="libresolv">
921 <term><filename class="libraryfile">libresolv</filename></term>
922 <listitem>
923 <para>Contains functions for creating, sending, and interpreting
924 packets to the Internet domain name servers</para>
925 <indexterm zone="ch-system-glibc libresolv">
926 <primary sortas="c-libresolv">libresolv</primary>
927 </indexterm>
928 </listitem>
929 </varlistentry>
930
931 <varlistentry id="librt">
932 <term><filename class="libraryfile">librt</filename></term>
933 <listitem>
934 <para>Contains functions providing most of the interfaces specified
935 by the POSIX.1b Real-time Extensions</para>
936 <indexterm zone="ch-system-glibc librt">
937 <primary sortas="c-librt">librt</primary>
938 </indexterm>
939 </listitem>
940 </varlistentry>
941
942 <varlistentry id="libthread_db">
943 <term><filename class="libraryfile">libthread_db</filename></term>
944 <listitem>
945 <para>Contains functions useful for building debuggers for
946 multi-threaded programs</para>
947 <indexterm zone="ch-system-glibc libthread_db">
948 <primary sortas="c-libthread_db">libthread_db</primary>
949 </indexterm>
950 </listitem>
951 </varlistentry>
952
953 <varlistentry id="libutil">
954 <term><filename class="libraryfile">libutil</filename></term>
955 <listitem>
956 <para>Dummy library containing no functions. Previously contained
957 code for <quote>standard</quote> functions used in
958 many different Unix utilities. These functions are now in
959 <filename class="libraryfile">libc</filename></para>
960 <indexterm zone="ch-system-glibc libutil">
961 <primary sortas="c-libutil">libutil</primary>
962 </indexterm>
963 </listitem>
964 </varlistentry>
965
966 </variablelist>
967
968 </sect2>
969
970</sect1>
Note: See TracBrowser for help on using the repository browser.