source: chapter08/glibc.xml@ cdf280e

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

glibc: Add more rationale about --enable-stack-protector, and remove the stale explanation of --with-headers

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