1
0

stripping.po 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298
  1. msgid ""
  2. msgstr ""
  3. "X-Pootle-Revision: 9999999\n"
  4. "X-Pootle-Path: /zh_CN/lfs/chapter07/stripping.po\n"
  5. "Project-Id-Version: PACKAGE VERSION\n"
  6. "POT-Creation-Date: 2020-08-20 01:17+0800\n"
  7. "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
  8. "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
  9. "Language-Team: LANGUAGE <LL@li.org>\n"
  10. "Language: zh_CN\n"
  11. "MIME-Version: 1.0\n"
  12. "Content-Type: text/plain; charset=UTF-8\n"
  13. "Content-Transfer-Encoding: 8bit\n"
  14. "X-Generator: Translate Toolkit 2.2.5\n"
  15. #. type: Content of: <sect1><title>
  16. msgid "Cleaning up and Saving the Temporary System"
  17. msgstr "清理和备份临时系统"
  18. #. type: Content of: <sect1><para>
  19. msgid ""
  20. "The libtool .la files are only useful when linking with static libraries. "
  21. "They are unneeded, and potentially harmful, when using dynamic shared "
  22. "libraries, specially when using non-autotools build systems. While still in "
  23. "chroot, remove those files now:"
  24. msgstr ""
  25. "libtool .la 文件仅在链接到静态库时有用。在使用动态共享库时它们没有意义,甚至"
  26. "有害,特别是对于非 autotools 构建系统。仍然在 chroot 环境中,运行命令删除它"
  27. "们:"
  28. #. type: Content of: <sect1><screen>
  29. #, no-wrap
  30. msgid "<userinput>find /usr/{lib,libexec} -name \\*.la -delete</userinput>"
  31. msgstr "<userinput>find /usr/{lib,libexec} -name \\*.la -delete</userinput>"
  32. #. type: Content of: <sect1><para>
  33. msgid ""
  34. "Remove the documentation of the temporary tools, to prevent them from ending "
  35. "up in the final system, and save about 35 MB:"
  36. msgstr ""
  37. "删除临时工具的文档,以防止它们进入最终构建的系统,并节省大约 35 MB:"
  38. #. type: Content of: <sect1><screen>
  39. #, no-wrap
  40. msgid "<userinput>rm -rf /usr/share/{info,man,doc}/*</userinput>"
  41. msgstr "<userinput>rm -rf /usr/share/{info,man,doc}/*</userinput>"
  42. #. type: Content of: <sect1><note><para>
  43. msgid ""
  44. "All the remaining steps in this section are optional. Nevertheless, as soon "
  45. "as you begin installing packages in <xref linkend=\"chapter-building-system"
  46. "\"/>, the temporary tools will be overwritten. So it may be a good idea to "
  47. "do a backup of the temporary tools as described below. The other steps are "
  48. "only needed if you are really short on disk space."
  49. msgstr ""
  50. "本节中的其余步骤都是可选的。不过,一旦您开始在<xref linkend=\"chapter-"
  51. "building-system\"/>中安装软件包,临时工具就会被覆盖。因此,按照下面描述的步骤"
  52. "备份临时工具可能是个好主意。其余步骤只有在您的磁盘空间非常紧张时才需要执行。"
  53. #. type: Content of: <sect1><para>
  54. msgid ""
  55. "The following steps are performed from outside the chroot environment. That "
  56. "means, you have to leave the chroot environment first before continuing. The "
  57. "reason for that is to:"
  58. msgstr ""
  59. "以下步骤在 chroot 环境之外进行。换句话说,您需要在继续操作之前退出 chroot 环"
  60. "境。这样做的主要原因是:"
  61. #. type: Content of: <sect1><para><itemizedlist><listitem><para>
  62. msgid "make sure that objects are not in use while they are manipulated."
  63. msgstr "保证在操作时,目标文件不会被使用。"
  64. #. type: Content of: <sect1><para><itemizedlist><listitem><para>
  65. msgid ""
  66. "get access to file system locations outside of the chroot environment to "
  67. "store/read the backup archive which should not be placed within the "
  68. "<filename class=\"directory\">$LFS</filename> hierarchy for safety reasons."
  69. msgstr ""
  70. "访问 chroot 环境之外的文件系统位置,以写入或读取备份档案,备份档案不应存放在 "
  71. "<filename class=\"directory\">$LFS</filename> 目录树中,以保证安全。"
  72. #. type: Content of: <sect1><para>
  73. msgid ""
  74. "Leave the chroot environment and unmount the kernel virtual file systems:"
  75. msgstr "退出 chroot 环境,并解除挂载内核虚拟文件系统:"
  76. #. type: Content of: <sect1><note><para>
  77. msgid ""
  78. "All of the following instructions are executed by <systemitem class="
  79. "\"username\">root</systemitem>. Take extra care about the commands you're "
  80. "going to run as mistakes here can modify your host system. Be aware that the "
  81. "environment variable <envar>LFS</envar> is set for user <systemitem class="
  82. "\"username\">lfs</systemitem> by default but it might <emphasis>not</"
  83. "emphasis> be set for <systemitem class=\"username\">root</systemitem>. "
  84. "Whenever commands are to be executed by <systemitem class=\"username\">root</"
  85. "systemitem>, make sure you have set <envar>LFS</envar> accordingly. This "
  86. "has been discussed in <xref linkend='ch-partitioning-aboutlfs'/>."
  87. msgstr ""
  88. "以下给出的所有步骤都以 <systemitem class=\"username\">root</systemitem> 身份"
  89. "执行。请非常小心地执行命令,错误的命令可能修改您的宿主系统。特别注意环境变量 "
  90. "<envar>LFS</envar> 会自动为用户 <systemitem class=\"username\">lfs</"
  91. "systemitem> 设定,但可能<emphasis>没有</emphasis>为 <systemitem class="
  92. "\"username\">root</systemitem> 设定。无论何时,只要准备以 <systemitem class="
  93. "\"username\">root</systemitem> 身份执行命令,一定要确认 <envar>LFS</envar> 变"
  94. "量正确设定。<xref linkend='ch-partitioning-aboutlfs'/>已经讨论了这个问题。"
  95. #. type: Content of: <sect1><screen>
  96. #, no-wrap
  97. msgid ""
  98. "<userinput>exit\n"
  99. "umount $LFS/dev{/pts,}\n"
  100. "umount $LFS/{sys,proc,run}</userinput>"
  101. msgstr ""
  102. "<userinput>exit\n"
  103. "umount $LFS/dev{/pts,}\n"
  104. "umount $LFS/{sys,proc,run}</userinput>"
  105. #. type: Content of: <sect1><sect2><title>
  106. msgid "Stripping"
  107. msgstr "移除无用内容"
  108. #. type: Content of: <sect1><sect2><para>
  109. msgid ""
  110. "If the LFS partition is rather small, it is good to know that unnecessary "
  111. "items can be removed. The executables and libraries built so far contain a "
  112. "little over 90 MB of unneeded debugging symbols."
  113. msgstr ""
  114. "如果 LFS 分区比较小,好消息是,有些无用的内容可以删除。到现在为止,已经构建的"
  115. "可执行文件和库包含大约 90MB 的无用调试符号。"
  116. #. type: Content of: <sect1><sect2><para>
  117. msgid "Strip off debugging symbols from binaries:"
  118. msgstr "从二进制文件移除调试符号:"
  119. #. type: Content of: <sect1><sect2><screen>
  120. #, no-wrap
  121. msgid ""
  122. "<userinput>strip --strip-debug $LFS/usr/lib/*\n"
  123. "strip --strip-unneeded $LFS/usr/{,s}bin/*\n"
  124. "strip --strip-unneeded $LFS/tools/bin/*</userinput>"
  125. msgstr ""
  126. "<userinput>strip --strip-debug $LFS/usr/lib/*\n"
  127. "strip --strip-unneeded $LFS/usr/{,s}bin/*\n"
  128. "strip --strip-unneeded $LFS/tools/bin/*</userinput>"
  129. #. Note that we use the <command>
  130. #. strip</command> program built in
  131. #. <quote>Binutils pass 2</quote>, since it is the one that knows how to strip
  132. #. our cross-compiled programs.
  133. #. type: Content of: <sect1><sect2><para>
  134. msgid ""
  135. "These commands will skip a number of files reporting that it does not "
  136. "recognize their file format. Most of these are scripts instead of binaries."
  137. msgstr ""
  138. "以上命令会跳过一些文件,并报告说无法识别它们的格式。这些文件大多数都是脚本文"
  139. "件,而不是二进制文件。"
  140. #. type: Content of: <sect1><sect2><para>
  141. msgid ""
  142. "Take care <emphasis>NOT</emphasis> to use <parameter>--strip-unneeded</"
  143. "parameter> on the libraries. The static ones would be destroyed and the "
  144. "toolchain packages would need to be built all over again."
  145. msgstr ""
  146. "注意<emphasis>不要</emphasis>对库文件使用 <parameter>--strip-unneeded</"
  147. "parameter> 选项。这会损坏静态库,结果工具链软件包都要重新构建。"
  148. #. type: Content of: <sect1><sect2><para>
  149. msgid ""
  150. "At this point, you should have at least 5 GB of free space on the chroot "
  151. "partition that can be used to build and install Glibc and GCC in the next "
  152. "phase. If you can build and install Glibc, you can build and install the "
  153. "rest too. You can check the free disk space with the command <command>df -h "
  154. "$LFS</command>."
  155. msgstr ""
  156. "现在,您应该保证 chroot 分区有至少 5 GB 的可用空间,以在下一阶段构建和安装 "
  157. "Glibc 和 GCC。如果空间足够构建和安装 Glibc,那么构建和安装剩余的软件包就不成"
  158. "问题。您可以使用命令 <command>df -h $LFS</command> 查询磁盘可用空间。"
  159. #. type: Content of: <sect1><sect2><title>
  160. msgid "Backup"
  161. msgstr "备份"
  162. #. type: Content of: <sect1><sect2><para>
  163. msgid ""
  164. "Now that the essential tools have been created, its time to think about a "
  165. "backup. When every check has passed successfully in the previously built "
  166. "packages, your temporary tools are in a good state and might be backed up "
  167. "for later reuse. In case of fatal failures in the subsequent chapters, it "
  168. "often turns out that removing everything and starting over (more carefully) "
  169. "is the best option to recover. Unfortunately, all the temporary tools will "
  170. "be removed, too. To avoid spending extra time to redo something which has "
  171. "been built successfully, prepare a backup."
  172. msgstr ""
  173. "现在已经建立了必要的工具,可以考虑备份它们。如果对之前构建的软件包进行的各项"
  174. "检查都没有发现问题,即可判定您的临时工具状态良好,可以将它们备份起来供以后重"
  175. "新使用。如果在后续章节发生了无法挽回的错误,通常来说,最好的办法是删除所有东"
  176. "西,然后 (更小心地) 从头开始。不幸的是,这也会删除所有临时工具。为了避免浪费"
  177. "时间对已经构建成功的部分进行返工,可以准备一个备份。"
  178. #. type: Content of: <sect1><sect2><para>
  179. msgid ""
  180. "Make sure you have at least 600 MB free disk space (the source tarballs will "
  181. "be included in the backup archive) in the home directory of user <systemitem "
  182. "class=\"username\">root</systemitem>."
  183. msgstr ""
  184. "确认在 <systemitem class=\"username\">root</systemitem> 的主目录中,有至少 "
  185. "600 MB 的可用存储空间 (源代码压缩包也会被包含在备份档案中)。"
  186. #. type: Content of: <sect1><sect2><para>
  187. msgid "Create the backup archive by running the following command:"
  188. msgstr "运行以下命令,创建备份档案:"
  189. #. type: Content of: <sect1><sect2><screen>
  190. #, no-wrap
  191. msgid ""
  192. "<userinput>cd $LFS &amp;&amp;\n"
  193. "tar -cJpf $HOME/lfs-temp-tools-&version;.tar.xz .</userinput>"
  194. msgstr ""
  195. "<userinput>cd $LFS &amp;&amp;\n"
  196. "tar -cJpf $HOME/lfs-temp-tools-&version;.tar.xz .</userinput>"
  197. #. type: Content of: <sect1><sect2><screen>
  198. #, no-wrap
  199. msgid ""
  200. "<userinput>cd $LFS &amp;&amp;\n"
  201. "tar -cJpf $HOME/lfs-temp-tools-&versiond;.tar.xz .</userinput>"
  202. msgstr ""
  203. "<userinput>cd $LFS &amp;&amp;\n"
  204. "tar -cJpf $HOME/lfs-temp-tools-&versiond;.tar.xz .</userinput>"
  205. #. type: Content of: <sect1><sect2><para>
  206. msgid ""
  207. "Replace <envar>$HOME</envar> by a directory of your choice if you do not "
  208. "want to have the backup stored in <systemitem class=\"username\">root</"
  209. "systemitem>'s home directory."
  210. msgstr ""
  211. "如果您不想将备份存储在 <systemitem class=\"username\">root</systemitem> 的主"
  212. "目录中,将 <envar>$HOME</envar> 替换为您选择的其他位置。"
  213. #. type: Content of: <sect1><sect2><title>
  214. msgid "Restore"
  215. msgstr "还原"
  216. #. type: Content of: <sect1><sect2><para>
  217. msgid ""
  218. "In case some mistakes have been made and you need to start over, you can use "
  219. "this backup to restore the temporary tools and save some recovery time. "
  220. "Since the sources are located under <filename class=\"directory\">$LFS</"
  221. "filename>, they are included in the backup archive as well, so they do not "
  222. "need to be downloaded again. After checking that <envar>$LFS</envar> is set "
  223. "properly, restore the backup by executing the following commands:"
  224. msgstr ""
  225. "如果您犯下了一些错误,并不得不重新开始构建,您可以使用备份档案还原临时工具,"
  226. "节约一些工作时间。由于源代码在 <filename class=\"directory\">$LFS</filename> "
  227. "中,它们也包含在备份档案内,因此不需要重新下载它们。在确认 <envar>$LFS</"
  228. "envar>设定正确后,运行以下命令从备份档案进行还原:"
  229. #. Make the following look different so users don't blindly run the
  230. #. restore when they don't need to.
  231. #. type: Content of: <sect1><sect2><screen>
  232. #, no-wrap
  233. msgid ""
  234. "<computeroutput>cd $LFS &amp;&amp;\n"
  235. "rm -rf ./* &amp;&amp;\n"
  236. "tar -xpf $HOME/lfs-temp-tools-&version;.tar.xz</computeroutput>"
  237. msgstr ""
  238. "<computeroutput>cd $LFS &amp;&amp;\n"
  239. "rm -rf ./* &amp;&amp;\n"
  240. "tar -xpf $HOME/lfs-temp-tools-&version;.tar.xz</computeroutput>"
  241. #. type: Content of: <sect1><sect2><screen>
  242. #, no-wrap
  243. msgid ""
  244. "<computeroutput>cd $LFS &amp;&amp;\n"
  245. "rm -rf ./* &amp;&amp;\n"
  246. "tar -xpf $HOME/lfs-temp-tools-&versiond;.tar.xz</computeroutput>"
  247. msgstr ""
  248. "<computeroutput>cd $LFS &amp;&amp;\n"
  249. "rm -rf ./* &amp;&amp;\n"
  250. "tar -xpf $HOME/lfs-temp-tools-&versiond;.tar.xz</computeroutput>"
  251. #. type: Content of: <sect1><sect2><para>
  252. msgid ""
  253. "Again, double check that the environment has been setup properly and "
  254. "continue building the rest of the system."
  255. msgstr "再一次复查环境是否配置正确,即可继续构建系统。"
  256. #. type: Content of: <sect1><sect2><important><para>
  257. msgid ""
  258. "If you left the chroot environment either to strip off debug symbols, create "
  259. "a backup, or restart building using a restore, remember to mount the kernel "
  260. "virtual filesystems now again as described in <xref linkend='ch-tools-"
  261. "kernfs'/> and re-enter the chroot environment (see <xref linkend='ch-tools-"
  262. "chroot'/>) again before continuing."
  263. msgstr ""
  264. "如果您在移除调试符号,进行备份,或从备份进行恢复时退出了 chroot 环境,记得按"
  265. "照<xref linkend='ch-tools-kernfs'/>的描述重新挂载内核虚拟文件系统,并重新进"
  266. "入 chroot 环境 (参阅<xref linkend='ch-tools-chroot'/>),再继续进行构建。"