|
@@ -27,9 +27,9 @@
|
|
|
the basic routines for allocating memory, searching directories, opening and
|
|
|
closing files, reading and writing files, string handling, pattern matching,
|
|
|
arithmetic, and so on.</para-->
|
|
|
- <para>Glibc 软件包包含主要的 C 语言库。它提供用于分配内存、检索目录、
|
|
|
- 打开和关闭文件、读写文件、字符串处理、模式匹配、
|
|
|
- 算术等用途的基本子程序。</para>
|
|
|
+ <para>Glibc 软件包包含主要的 C 语言库。它提供用于分配内存、检索目录、
|
|
|
+ 打开和关闭文件、读写文件、字符串处理、模式匹配、
|
|
|
+ 算术等用途的基本子程序。</para>
|
|
|
|
|
|
<segmentedlist>
|
|
|
<segtitle>&buildtime;</segtitle>
|
|
@@ -51,23 +51,23 @@
|
|
|
pointing to <filename class="directory">/tools</filename>. The specs
|
|
|
and linker cannot be adjusted before the Glibc install because the
|
|
|
Glibc autoconf tests would give false results and defeat the goal
|
|
|
- of achieving a clean build.</para-->
|
|
|
- <para> Glibc 构建系统是自给自足的,
|
|
|
- 即使编译器 specs 文件和链接器仍然指向
|
|
|
- <filename class="directory">/tools</filename>,
|
|
|
- 也能完美地安装 Glibc 。在安装 Glibc 之前不能调整工具链,
|
|
|
- 否则 Glibc 的 autoconf 测试会给出错误结果,
|
|
|
- 结果无法达成干净地构建 Glibc 这一目的。</para>
|
|
|
- </note>
|
|
|
+ of achieving a clean build.</para-->
|
|
|
+ <para> Glibc 构建系统是自给自足的,
|
|
|
+ 即使编译器 specs 文件和链接器仍然指向
|
|
|
+ <filename class="directory">/tools</filename>,
|
|
|
+ 也能完美地安装 Glibc 。在安装 Glibc 之前不能调整工具链,
|
|
|
+ 否则 Glibc 的 autoconf 测试会给出错误结果,
|
|
|
+ 结果无法达成干净地构建 Glibc 这一目的。</para>
|
|
|
+ </note>
|
|
|
|
|
|
<!--para>Some of the Glibc programs use the non-FHS compilant
|
|
|
<filename class="directory">/var/db</filename> directory to store
|
|
|
their runtime data. Apply the following patch to make such programs
|
|
|
store their runtime data in the FHS-compliant locations:</para-->
|
|
|
- <para>某些 Glibc 程序使用与 FHS 不兼容的
|
|
|
- <filename class="directory">/var/db</filename>
|
|
|
- 目录存放运行时数据。应用下列补丁,
|
|
|
- 使得这些程序在 FHS 兼容的位置存储运行时数据:</para>
|
|
|
+ <para>某些 Glibc 程序使用与 FHS 不兼容的
|
|
|
+ <filename class="directory">/var/db</filename>
|
|
|
+ 目录存放运行时数据。应用下列补丁,
|
|
|
+ 使得这些程序在 FHS 兼容的位置存储运行时数据:</para>
|
|
|
|
|
|
<screen><userinput remap="pre">patch -Np1 -i ../&glibc-fhs-patch;</userinput></screen>
|
|
|
<!--
|
|
@@ -78,8 +78,8 @@
|
|
|
<!--para>First create a compatibility symlink to avoid references to /tools in
|
|
|
our final glibc:</para-->
|
|
|
<para>创建一个与最终的 LFS 系统兼容的符号链接,
|
|
|
- 避免最终的 Glibc 包含对 /tools 的引用:
|
|
|
- </para>
|
|
|
+ 避免最终的 Glibc 包含对 /tools 的引用:
|
|
|
+ </para>
|
|
|
|
|
|
<screen><userinput remap="pre">ln -sfv /tools/lib/gcc /usr/lib</userinput></screen>
|
|
|
|
|
@@ -87,8 +87,8 @@
|
|
|
compliance. Additionally, for x86_64, create a compatibility symlink
|
|
|
required for the dynamic loader to function correctly:</para-->
|
|
|
<para>判定 GCC 包含文件目录,并为了兼容 LSB 创建一个符号链接。另外,
|
|
|
- 对于 x86_64 ,还要创建一个动态链接器的兼容性符号链接,
|
|
|
- 使它能够正常工作:</para>
|
|
|
+ 对于 x86_64 ,还要创建一个动态链接器的兼容性符号链接,
|
|
|
+ 使它能够正常工作:</para>
|
|
|
|
|
|
<screen><userinput remap="pre">case $(uname -m) in
|
|
|
i?86) GCC_INCDIR=/usr/lib/gcc/$(uname -m)-pc-linux-gnu/&gcc-version;/include
|
|
@@ -102,17 +102,17 @@ esac</userinput></screen>
|
|
|
|
|
|
<!--para>Remove a file that may be left over from a previous build attempt:
|
|
|
</para-->
|
|
|
- <para>删除上次编译时可能留下的文件:</para>
|
|
|
- <note><title>译注</title>
|
|
|
- <para>译者的惨痛教训表明,如果存在这个文件,
|
|
|
- 构建系统会无限循环。</para>
|
|
|
- </note>
|
|
|
+ <para>删除上次编译时可能留下的文件:</para>
|
|
|
+ <note><title>译注</title>
|
|
|
+ <para>译者的惨痛教训表明,如果存在这个文件,
|
|
|
+ 构建系统会无限循环。</para>
|
|
|
+ </note>
|
|
|
|
|
|
<screen><userinput remap="pre">rm -f /usr/include/limits.h</userinput></screen>
|
|
|
|
|
|
<!--para>The Glibc documentation recommends building Glibc
|
|
|
in a dedicated build directory:</para-->
|
|
|
- <para>Glibc 文档推荐在专用目录中构建它:</para>
|
|
|
+ <para>Glibc 文档推荐在专用目录中构建它:</para>
|
|
|
|
|
|
<screen><userinput remap="pre">mkdir -v build
|
|
|
cd build</userinput></screen>
|
|
@@ -136,7 +136,7 @@ unset GCC_INCDIR</userinput></screen>
|
|
|
<!--para>Setting the location of both gcc and system include directories
|
|
|
avoids introduction of invalid paths in debugging symbols.</para-->
|
|
|
<para>设定 GCC 和系统的包含文件目录,避免调试符号中包含无效路径。
|
|
|
- </para>
|
|
|
+ </para>
|
|
|
</listitem>
|
|
|
</varlistentry>
|
|
|
|
|
@@ -145,8 +145,8 @@ unset GCC_INCDIR</userinput></screen>
|
|
|
<listitem>
|
|
|
<!--para>This option disables the -Werror option passed to
|
|
|
GCC. This is necessary for running the test suite.</para-->
|
|
|
- <para>该选项禁用 GCC 的 -Werror 选项,
|
|
|
- 这对于运行测试套件来说是必须的。</para>
|
|
|
+ <para>该选项禁用 GCC 的 -Werror 选项,
|
|
|
+ 这对于运行测试套件来说是必须的。</para>
|
|
|
</listitem>
|
|
|
</varlistentry>
|
|
|
|
|
@@ -156,17 +156,17 @@ unset GCC_INCDIR</userinput></screen>
|
|
|
<!--para>This option increases system security by adding
|
|
|
extra code to check for buffer overflows, such as stack
|
|
|
smashing attacks.</para-->
|
|
|
- <para>该选项通过加入额外代码,
|
|
|
- 对栈溢出攻击等导致的缓冲区溢出进行检查,以提高系统安全性。
|
|
|
- </para>
|
|
|
+ <para>该选项通过加入额外代码,
|
|
|
+ 对栈溢出攻击等导致的缓冲区溢出进行检查,以提高系统安全性。
|
|
|
+ </para>
|
|
|
</listitem>
|
|
|
</varlistentry>
|
|
|
|
|
|
<varlistentry>
|
|
|
<term><parameter>libc_cv_slibdir=/lib</parameter></term>
|
|
|
<listitem>
|
|
|
- <para>这个变量纠正库文件安装位置,
|
|
|
- 我们不希望使用 lib64 目录。</para>
|
|
|
+ <para>这个变量纠正库文件安装位置,
|
|
|
+ 我们不希望使用 lib64 目录。</para>
|
|
|
</listitem>
|
|
|
</varlistentry>
|
|
|
|
|
@@ -180,13 +180,13 @@ unset GCC_INCDIR</userinput></screen>
|
|
|
<!--para>In this section, the test suite for Glibc is considered critical.
|
|
|
Do not skip it under any circumstance.</para-->
|
|
|
<para>在本节中, Glibc 的测试套件十分关键,在任何情况下都不能跳过。
|
|
|
- </para>
|
|
|
+ </para>
|
|
|
</important>
|
|
|
|
|
|
<!--para>Generally a few tests do not pass. The test failures listed below
|
|
|
are usually safe to ignore.</para-->
|
|
|
<para>通常来说,可能会有极少数测试不能通过,
|
|
|
- 下面列出的失败结果一般可以安全地忽略。执行以下命令进行测试:
|
|
|
+ 下面列出的失败结果一般可以安全地忽略。执行以下命令进行测试:
|
|
|
</para>
|
|
|
|
|
|
<screen><userinput remap="test">make check</userinput></screen>
|
|
@@ -195,8 +195,8 @@ unset GCC_INCDIR</userinput></screen>
|
|
|
somewhat dependent on the host system. This is a list of the most common
|
|
|
issues seen for some versions of LFS:</para-->
|
|
|
<para>您可能看到一些失败结果。
|
|
|
- Glibc 的测试套件和宿主系统之间有某种依赖关系,以下是在一些版本的
|
|
|
- LFS 上最常见的问题:</para>
|
|
|
+ Glibc 的测试套件和宿主系统之间有某种依赖关系,以下是在一些版本的
|
|
|
+ LFS 上最常见的问题:</para>
|
|
|
|
|
|
<itemizedlist>
|
|
|
|
|
@@ -249,17 +249,17 @@ unset GCC_INCDIR</userinput></screen>
|
|
|
<!--para>Though it is a harmless message, the install stage of Glibc will
|
|
|
complain about the absence of <filename>/etc/ld.so.conf</filename>.
|
|
|
Prevent this warning with:</para-->
|
|
|
- <para>在安装 Glibc 时,它会抱怨文件 <filename>/etc/ld.so.conf</filename>
|
|
|
- 不存在。尽管这是一条无害的消息,执行以下命令即可防止这个警告:
|
|
|
- </para>
|
|
|
+ <para>在安装 Glibc 时,它会抱怨文件 <filename>/etc/ld.so.conf</filename>
|
|
|
+ 不存在。尽管这是一条无害的消息,执行以下命令即可防止这个警告:
|
|
|
+ </para>
|
|
|
|
|
|
<screen><userinput remap="install">touch /etc/ld.so.conf</userinput></screen>
|
|
|
|
|
|
<!--para>Fix the generated Makefile to skip an unneeded sanity check
|
|
|
that fails in the LFS partial environment:
|
|
|
</para-->
|
|
|
- <para>修正生成的 Makefile ,
|
|
|
- 跳过一个在 LFS 的不完整环境中会失败的完整性检查:</para>
|
|
|
+ <para>修正生成的 Makefile ,
|
|
|
+ 跳过一个在 LFS 的不完整环境中会失败的完整性检查:</para>
|
|
|
|
|
|
<screen><userinput remap="install">sed '/test-installation/s@$(PERL)@echo not running@' -i ../Makefile</userinput></screen>
|
|
|
|
|
@@ -269,7 +269,7 @@ unset GCC_INCDIR</userinput></screen>
|
|
|
|
|
|
<!--para>Install the configuration file and runtime directory for
|
|
|
<command>nscd</command>:</para-->
|
|
|
- <para>安装 <command>nscd</command> 的配置文件和运行时目录:</para>
|
|
|
+ <para>安装 <command>nscd</command> 的配置文件和运行时目录:</para>
|
|
|
|
|
|
<screen><userinput remap="install">cp -v ../nscd/nscd.conf /etc/nscd.conf
|
|
|
mkdir -pv /var/cache/nscd</userinput></screen>
|
|
@@ -284,9 +284,9 @@ install -v -Dm644 ../nscd/nscd.service /lib/systemd/system/nscd.service</userinp
|
|
|
different language. None of the locales are required, but if some of them
|
|
|
are missing, the test suites of future packages would skip important
|
|
|
testcases.</para-->
|
|
|
- <para>下面,安装一些 locale ,它们可以使得系统用不同语言响应用户请求。
|
|
|
- 这些 locale 都不是必须的,但是如果缺少了它们中的某些,
|
|
|
- 在将来运行软件包的测试套件时,可能跳过重要的测试。</para>
|
|
|
+ <para>下面,安装一些 locale ,它们可以使得系统用不同语言响应用户请求。
|
|
|
+ 这些 locale 都不是必须的,但是如果缺少了它们中的某些,
|
|
|
+ 在将来运行软件包的测试套件时,可能跳过重要的测试。</para>
|
|
|
|
|
|
<!--para>Individual locales can be installed using the
|
|
|
<command>localedef</command> program. E.g., the first
|
|
@@ -298,14 +298,14 @@ install -v -Dm644 ../nscd/nscd.service /lib/systemd/system/nscd.service</userinp
|
|
|
<filename>/usr/lib/locale/locale-archive</filename> file.
|
|
|
The following instructions will install the minimum set of
|
|
|
locales necessary for the optimal coverage of tests:</para-->
|
|
|
- <para>可以用 <command>localedef</command> 程序安装单独的 locale 。
|
|
|
- 例如,下面的第一个 <command>localedef</command> 命令将
|
|
|
- <filename>/usr/share/i18n/locales/cs_CZ</filename>
|
|
|
- 中的字符集无关 locale 定义和
|
|
|
- <filename>/usr/share/i18n/charmaps/UTF-8.gz</filename>
|
|
|
- 中的字符映射定义组合起来,并附加到
|
|
|
- <filename>/usr/lib/locale/locale-archive</filename> 文件。
|
|
|
- 以下命令将会安装能够覆盖测试所需的最小 locale 集合:</para>
|
|
|
+ <para>可以用 <command>localedef</command> 程序安装单独的 locale 。
|
|
|
+ 例如,下面的第一个 <command>localedef</command> 命令将
|
|
|
+ <filename>/usr/share/i18n/locales/cs_CZ</filename>
|
|
|
+ 中的字符集无关 locale 定义和
|
|
|
+ <filename>/usr/share/i18n/charmaps/UTF-8.gz</filename>
|
|
|
+ 中的字符映射定义组合起来,并附加到
|
|
|
+ <filename>/usr/lib/locale/locale-archive</filename> 文件。
|
|
|
+ 以下命令将会安装能够覆盖测试所需的最小 locale 集合:</para>
|
|
|
|
|
|
|
|
|
<screen role="nodump"><userinput remap="locale-test">mkdir -pv /usr/lib/locale
|
|
@@ -333,22 +333,22 @@ localedef -i zh_CN -f GB18030 zh_CN.GB18030</userinput></screen>
|
|
|
|
|
|
<!--para>In addition, install the locale for your own country, language and
|
|
|
character set.</para-->
|
|
|
- <para>另外,安装适合您自己国家、语言和字符集的 locale 。</para>
|
|
|
- <note><title>译注</title><para>
|
|
|
- 建议中文用户安装 zh_CN.UTF-8 作为日常使用的 locale。GB18030
|
|
|
- 是为了后向兼容古老的 GB2312 而设计的编码,
|
|
|
- 在现代 Linux 系统和互联网使用时会引起一些奇怪的问题。
|
|
|
- 中华人民共和国国家标准化管理委员会的官方网站已经切换到 UTF-8。
|
|
|
- </para></note>
|
|
|
+ <para>另外,安装适合您自己国家、语言和字符集的 locale 。</para>
|
|
|
+ <note><title>译注</title><para>
|
|
|
+ 建议中文用户安装 zh_CN.UTF-8 作为日常使用的 locale。GB18030
|
|
|
+ 是为了后向兼容古老的 GB2312 而设计的编码,
|
|
|
+ 在现代 Linux 系统和互联网使用时会引起一些奇怪的问题。
|
|
|
+ 中华人民共和国国家标准化管理委员会的官方网站已经切换到 UTF-8。
|
|
|
+ </para></note>
|
|
|
|
|
|
<!--para>Alternatively, install all locales listed in the
|
|
|
<filename>glibc-&glibc-version;/localedata/SUPPORTED</filename> file
|
|
|
(it includes every locale listed above and many more) at once with the
|
|
|
following time-consuming command:</para-->
|
|
|
- <para>或者,也可以一次安装
|
|
|
- <filename>glibc-&glibc-version;/localedata/SUPPORTED</filename>
|
|
|
- 中列出的所有 locale (包括上面列出的所有 locale,以及其他很多)。
|
|
|
- 执行下面这个需要很长时间的命令:</para>
|
|
|
+ <para>或者,也可以一次安装
|
|
|
+ <filename>glibc-&glibc-version;/localedata/SUPPORTED</filename>
|
|
|
+ 中列出的所有 locale (包括上面列出的所有 locale,以及其他很多)。
|
|
|
+ 执行下面这个需要很长时间的命令:</para>
|
|
|
|
|
|
<screen><userinput remap="locale-full">make localedata/install-locales</userinput></screen>
|
|
|
|
|
@@ -356,9 +356,9 @@ localedef -i zh_CN -f GB18030 zh_CN.GB18030</userinput></screen>
|
|
|
install locales not listed in the
|
|
|
<filename>glibc-&glibc-version;/localedata/SUPPORTED</filename> file
|
|
|
in the unlikely case you need them.</para-->
|
|
|
- <para>如果需要,再使用 <command>localedef</command> 命令创建和安装
|
|
|
- <filename>glibc-&glibc-version;/localedata/SUPPORTED</filename>
|
|
|
- 中没有列出的 locale ,当然您不太可能需要它们。</para>
|
|
|
+ <para>如果需要,再使用 <command>localedef</command> 命令创建和安装
|
|
|
+ <filename>glibc-&glibc-version;/localedata/SUPPORTED</filename>
|
|
|
+ 中没有列出的 locale ,当然您不太可能需要它们。</para>
|
|
|
|
|
|
<note><para>Glibc now uses libidn2 when resolving internationalized
|
|
|
domain names. This is a run time dependency. If this capability
|
|
@@ -385,13 +385,13 @@ localedef -i zh_CN -f GB18030 zh_CN.GB18030</userinput></screen>
|
|
|
<!--para>The <filename>/etc/nsswitch.conf</filename> file needs to be created
|
|
|
because the Glibc defaults do not work well in a networked environment.
|
|
|
</para-->
|
|
|
- <para>由于 Glibc 的默认值在网络环境下不能很好地工作,
|
|
|
- 需要创建配置文件 <filename>/etc/nsswitch.conf</filename>。</para>
|
|
|
+ <para>由于 Glibc 的默认值在网络环境下不能很好地工作,
|
|
|
+ 需要创建配置文件 <filename>/etc/nsswitch.conf</filename>。</para>
|
|
|
|
|
|
<!--para>Create a new file <filename>/etc/nsswitch.conf</filename> by running the
|
|
|
following:</para-->
|
|
|
- <para>执行以下命令创建新的 <filename>/etc/nsswitch.conf</filename>:
|
|
|
- </para>
|
|
|
+ <para>执行以下命令创建新的 <filename>/etc/nsswitch.conf</filename>:
|
|
|
+ </para>
|
|
|
|
|
|
<screen><userinput>cat > /etc/nsswitch.conf << "EOF"
|
|
|
<literal># Begin /etc/nsswitch.conf
|
|
@@ -417,7 +417,7 @@ EOF</userinput></screen>
|
|
|
<title>添加时区数据</title>
|
|
|
|
|
|
<!--para>Install and set up the time zone data with the following:</para-->
|
|
|
- <para>输入以下命令,安装并设置时区数据:</para>
|
|
|
+ <para>输入以下命令,安装并设置时区数据:</para>
|
|
|
<screen><userinput>tar -xf ../../tzdata&tzdata-version;.tar.gz
|
|
|
|
|
|
ZONEINFO=/usr/share/zoneinfo
|
|
@@ -451,15 +451,14 @@ unset ZONEINFO</userinput></screen>
|
|
|
1.9MB by not using the <filename class="directory">posix</filename>
|
|
|
directory, but some applications or test-suites might produce some
|
|
|
failures.</para-->
|
|
|
- <para>该命令创建没有闰秒的 POSIX 时区。一般的惯例是将它们安装在
|
|
|
- <filename class="directory">zoneinfo</filename> 和
|
|
|
- <filename class="directory">zoneinfo/posix</filename>
|
|
|
- 两个目录中。前者是必须的,否则若干测试套件会报告错误。
|
|
|
- 在嵌入式系统上,如果存储空间十分紧张,
|
|
|
- 而且您永远不会更新时区信息,您可以不使用
|
|
|
- <filename class="directory">posix</filename> 目录,
|
|
|
- 以节约 1.9 MB,
|
|
|
- 但个别程序或测试套件可能会失败。</para>
|
|
|
+ <para>该命令创建没有闰秒的 POSIX 时区。一般的惯例是将它们安装在
|
|
|
+ <filename class="directory">zoneinfo</filename> 和
|
|
|
+ <filename class="directory">zoneinfo/posix</filename>
|
|
|
+ 两个目录中。前者是必须的,否则若干测试套件会报告错误。
|
|
|
+ 在嵌入式系统上,如果存储空间十分紧张,
|
|
|
+ 而且您永远不会更新时区信息,您可以不使用
|
|
|
+ <filename class="directory">posix</filename> 目录,
|
|
|
+ 以节约 1.9 MB,但个别程序或测试套件可能会失败。</para>
|
|
|
</listitem>
|
|
|
</varlistentry>
|
|
|
<varlistentry>
|
|
@@ -471,10 +470,10 @@ unset ZONEINFO</userinput></screen>
|
|
|
save 1.9MB by omitting the <filename class="directory">right</filename>
|
|
|
directory.</para-->
|
|
|
<para>该命令创建正确的,包含闰秒的时区。在嵌入式系统上,
|
|
|
- 如果存储空间十分紧张,而且您永远不会更新时区信息,
|
|
|
- 也不关心系统时间是否正确,您可以跳过
|
|
|
- <filename class="directory">right</filename> 目录,
|
|
|
- 以节约 1.9 MB。</para>
|
|
|
+ 如果存储空间十分紧张,而且您永远不会更新时区信息,
|
|
|
+ 也不关心系统时间是否正确,您可以跳过
|
|
|
+ <filename class="directory">right</filename> 目录,
|
|
|
+ 以节约 1.9 MB。</para>
|
|
|
</listitem>
|
|
|
</varlistentry>
|
|
|
<varlistentry>
|
|
@@ -484,8 +483,8 @@ unset ZONEINFO</userinput></screen>
|
|
|
New York because POSIX requires the daylight savings time rules
|
|
|
to be in accordance with US rules.</para-->
|
|
|
<para>该命令创建 <filename>posixrule</filename> 文件。
|
|
|
- 我们使用纽约时区,因为 POSIX 要求与美国一致的夏令时规则。
|
|
|
- </para>
|
|
|
+ 我们使用纽约时区,因为 POSIX 要求与美国一致的夏令时规则。
|
|
|
+ </para>
|
|
|
</listitem>
|
|
|
</varlistentry>
|
|
|
</variablelist>
|
|
@@ -493,7 +492,7 @@ unset ZONEINFO</userinput></screen>
|
|
|
|
|
|
<!--para>One way to determine the local time zone is to run the following
|
|
|
script:</para-->
|
|
|
- <para>一种确定本地时区的方法是运行脚本:</para>
|
|
|
+ <para>一种确定本地时区的方法是运行脚本:</para>
|
|
|
|
|
|
<screen role="nodump"><userinput>tzselect</userinput></screen>
|
|
|
|
|
@@ -508,14 +507,14 @@ unset ZONEINFO</userinput></screen>
|
|
|
<para>Then create the <filename>/etc/localtime</filename> file by
|
|
|
running:</para-->
|
|
|
<para>在回答关于当前位置的若干问题后,脚本会输出对应时区的名字
|
|
|
- (例如<emphasis>America/Edmonton</emphasis>)。
|
|
|
- 在 <filename class="directory">/usr/share/zoneinfo</filename>
|
|
|
- 中还有一些该脚本不能识别,但可以使用的时区,如
|
|
|
- <emphasis>Canada/Eastern</emphasis> 或者
|
|
|
- <emphasis>EST5EDT</emphasis>。</para>
|
|
|
+ (例如<emphasis>America/Edmonton</emphasis>)。
|
|
|
+ 在 <filename class="directory">/usr/share/zoneinfo</filename>
|
|
|
+ 中还有一些该脚本不能识别,但可以使用的时区,如
|
|
|
+ <emphasis>Canada/Eastern</emphasis> 或者
|
|
|
+ <emphasis>EST5EDT</emphasis>。</para>
|
|
|
|
|
|
- <para>确定时区后,执行以下命令,创建
|
|
|
- <filename>/etc/localtime</filename>:</para>
|
|
|
+ <para>确定时区后,执行以下命令,创建
|
|
|
+ <filename>/etc/localtime</filename>:</para>
|
|
|
|
|
|
<screen revision="sysv"><userinput>cp -v /usr/share/zoneinfo/<replaceable><xxx></replaceable> /etc/localtime</userinput></screen>
|
|
|
|
|
@@ -523,8 +522,8 @@ unset ZONEINFO</userinput></screen>
|
|
|
|
|
|
<!--para>Replace <replaceable><xxx></replaceable> with the name of the
|
|
|
time zone selected (e.g., Canada/Eastern).</para-->
|
|
|
- <para>将 <replaceable><xxx></replaceable> 替换成选定时区的名称
|
|
|
- (例如 Canada/Eastern)。</para>
|
|
|
+ <para>将 <replaceable><xxx></replaceable> 替换成选定时区的名称
|
|
|
+ (例如 Canada/Eastern)。</para>
|
|
|
|
|
|
</sect3>
|
|
|
|
|
@@ -549,21 +548,21 @@ unset ZONEINFO</userinput></screen>
|
|
|
class="directory">/opt/lib</filename>, so add those directories to the
|
|
|
dynamic loader's search path.</para-->
|
|
|
<para>默认情况下,动态加载器
|
|
|
- (<filename class="libraryfile">/lib/ld-linux.so.2</filename>)
|
|
|
- 在 <filename class="directory">/lib</filename> 和
|
|
|
- <filename class="directory">/usr/lib</filename>
|
|
|
- 中搜索程序运行时需要的动态库。然而,如果在其他目录中有动态库,
|
|
|
- 为了使动态加载器能够找到它们,需要把这些目录添加到文件
|
|
|
- <filename>/etc/ld.so.conf</filename> 中。
|
|
|
- 有两个目录 <filename class="directory">/usr/local/lib</filename>
|
|
|
- 和 <filename class="directory">/opt/lib</filename>
|
|
|
- 经常包含附加的共享库,所以现在将它们添加到动态加载器的搜索目录中。
|
|
|
- </para>
|
|
|
+ (<filename class="libraryfile">/lib/ld-linux.so.2</filename>)
|
|
|
+ 在 <filename class="directory">/lib</filename> 和
|
|
|
+ <filename class="directory">/usr/lib</filename>
|
|
|
+ 中搜索程序运行时需要的动态库。然而,如果在其他目录中有动态库,
|
|
|
+ 为了使动态加载器能够找到它们,需要把这些目录添加到文件
|
|
|
+ <filename>/etc/ld.so.conf</filename> 中。
|
|
|
+ 有两个目录 <filename class="directory">/usr/local/lib</filename>
|
|
|
+ 和 <filename class="directory">/opt/lib</filename>
|
|
|
+ 经常包含附加的共享库,所以现在将它们添加到动态加载器的搜索目录中。
|
|
|
+ </para>
|
|
|
|
|
|
<!--para>Create a new file <filename>/etc/ld.so.conf</filename> by running the
|
|
|
following:</para-->
|
|
|
- <para>运行以下命令,创建一个新的 <filename>/etc/ld.so.conf</filename>:
|
|
|
- </para>
|
|
|
+ <para>运行以下命令,创建一个新的 <filename>/etc/ld.so.conf</filename>:
|
|
|
+ </para>
|
|
|
|
|
|
<screen><userinput>cat > /etc/ld.so.conf << "EOF"
|
|
|
<literal># Begin /etc/ld.so.conf
|
|
@@ -577,9 +576,9 @@ EOF</userinput></screen>
|
|
|
this include directory are one line specifying the desired library path.
|
|
|
To add this capability run the following commands:</para-->
|
|
|
<para>如果希望的话,动态加载器也可以搜索一个目录,并将其中的文件包含在
|
|
|
- <filename>ld.so.conf</filename> 中。
|
|
|
- 通常包含文件目录中的文件只有一行,指定一个期望的库文件目录。
|
|
|
- 如果需要这项功能,执行以下命令:</para>
|
|
|
+ <filename>ld.so.conf</filename> 中。
|
|
|
+ 通常包含文件目录中的文件只有一行,指定一个期望的库文件目录。
|
|
|
+ 如果需要这项功能,执行以下命令:</para>
|
|
|
|
|
|
<screen role="nodump"><userinput>cat >> /etc/ld.so.conf << "EOF"
|
|
|
<literal># Add an include directory
|
|
@@ -853,7 +852,7 @@ mkdir -pv /etc/ld.so.conf.d</userinput></screen>
|
|
|
<varlistentry id="ld.so">
|
|
|
<term><filename class="libraryfile">ld-&glibc-version;.so</filename></term>
|
|
|
<listitem>
|
|
|
- <para>动态链接器/加载器</para>
|
|
|
+ <para>动态链接器/加载器</para>
|
|
|
<indexterm zone="ch-system-glibc ld.so">
|
|
|
<primary sortas="c-ld.so">ld-&glibc-version;.so</primary>
|
|
|
</indexterm>
|
|
@@ -863,10 +862,10 @@ mkdir -pv /etc/ld.so.conf.d</userinput></screen>
|
|
|
<varlistentry id="libBrokenLocale">
|
|
|
<term><filename class="libraryfile">libBrokenLocale</filename></term>
|
|
|
<listitem>
|
|
|
- <para>被 Glibc 内部用作使某些不正确的程序(例如某些 Motif 程序)
|
|
|
- 正常运行的粗糙手段,参阅
|
|
|
- <filename>glibc-&glibc-version;/locale/broken_cur_max.c</filename>
|
|
|
- 中的注释了解更多信息</para>
|
|
|
+ <para>被 Glibc 内部用作使某些不正确的程序(例如某些 Motif 程序)
|
|
|
+ 正常运行的粗糙手段,参阅
|
|
|
+ <filename>glibc-&glibc-version;/locale/broken_cur_max.c</filename>
|
|
|
+ 中的注释了解更多信息</para>
|
|
|
<indexterm zone="ch-system-glibc libBrokenLocale">
|
|
|
<primary sortas="c-libBrokenLocale">libBrokenLocale</primary>
|
|
|
</indexterm>
|
|
@@ -876,8 +875,8 @@ mkdir -pv /etc/ld.so.conf.d</userinput></screen>
|
|
|
<varlistentry id="libSegFault">
|
|
|
<term><filename class="libraryfile">libSegFault</filename></term>
|
|
|
<listitem>
|
|
|
- <para><command>catchsegv</command> 使用的段错误信号处理程序
|
|
|
- </para>
|
|
|
+ <para><command>catchsegv</command> 使用的段错误信号处理程序
|
|
|
+ </para>
|
|
|
<indexterm zone="ch-system-glibc libSegFault">
|
|
|
<primary sortas="c-libSegFault">libSegFault</primary>
|
|
|
</indexterm>
|
|
@@ -907,8 +906,8 @@ mkdir -pv /etc/ld.so.conf.d</userinput></screen>
|
|
|
<varlistentry id="libcidn">
|
|
|
<term><filename class="libraryfile">libcidn</filename></term>
|
|
|
<listitem>
|
|
|
- <para>被 Glibc 内部的 <function>getaddrinfo</function> 函数
|
|
|
- 用于处理国际化域名</para>
|
|
|
+ <para>被 Glibc 内部的 <function>getaddrinfo</function> 函数
|
|
|
+ 用于处理国际化域名</para>
|
|
|
<indexterm zone="ch-system-glibc libcidn">
|
|
|
<primary sortas="c-libcidn">libcidn</primary>
|
|
|
</indexterm>
|
|
@@ -938,8 +937,8 @@ mkdir -pv /etc/ld.so.conf.d</userinput></screen>
|
|
|
<varlistentry id="libg">
|
|
|
<term><filename class="libraryfile">libg</filename></term>
|
|
|
<listitem>
|
|
|
- <para>没有功能的空库,曾经是 <command>g++</command> 的运行库。
|
|
|
- </para>
|
|
|
+ <para>没有功能的空库,曾经是 <command>g++</command> 的运行库。
|
|
|
+ </para>
|
|
|
<indexterm zone="ch-system-glibc libg">
|
|
|
<primary sortas="c-libg">libg</primary>
|
|
|
</indexterm>
|
|
@@ -952,9 +951,9 @@ mkdir -pv /etc/ld.so.conf.d</userinput></screen>
|
|
|
<!--para>Linking in this module forces error handling rules for math
|
|
|
functions as defined by the Institute of Electrical and Electronic
|
|
|
Engineers (IEEE). The default is POSIX.1 error handling</para-->
|
|
|
- <para>链接该库以使用国际电气电子工程师学会(IEEE)
|
|
|
- 定义的数学函数错误处理规则,而不是默认的 POSIX.1 错误处理。
|
|
|
- </para>
|
|
|
+ <para>链接该库以使用国际电气电子工程师学会(IEEE)
|
|
|
+ 定义的数学函数错误处理规则,而不是默认的 POSIX.1 错误处理。
|
|
|
+ </para>
|
|
|
<indexterm zone="ch-system-glibc libieee">
|
|
|
<primary sortas="c-libieee">libieee</primary>
|
|
|
</indexterm>
|
|
@@ -964,7 +963,7 @@ mkdir -pv /etc/ld.so.conf.d</userinput></screen>
|
|
|
<varlistentry id="libm">
|
|
|
<term><filename class="libraryfile">libm</filename></term>
|
|
|
<listitem>
|
|
|
- <para>数学库</para>
|
|
|
+ <para>数学库</para>
|
|
|
<indexterm zone="ch-system-glibc libm">
|
|
|
<primary sortas="c-libm">libm</primary>
|
|
|
</indexterm>
|
|
@@ -1005,8 +1004,8 @@ mkdir -pv /etc/ld.so.conf.d</userinput></screen>
|
|
|
<varlistentry id="libnss">
|
|
|
<term><filename class="libraryfile">libnss</filename></term>
|
|
|
<listitem>
|
|
|
- <para>命名服务开关库,包含用于解析域名、用户名、组名、代号、
|
|
|
- 服务、协议等的函数。</para>
|
|
|
+ <para>命名服务开关库,包含用于解析域名、用户名、组名、代号、
|
|
|
+ 服务、协议等的函数。</para>
|
|
|
<indexterm zone="ch-system-glibc libnss">
|
|
|
<primary sortas="c-libnss">libnss</primary>
|
|
|
</indexterm>
|