aboutlfs.po 6.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121
  1. msgid ""
  2. msgstr ""
  3. "Project-Id-Version: PACKAGE VERSION\n"
  4. "POT-Creation-Date: 2020-06-17 12:44+0800\n"
  5. "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
  6. "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
  7. "Language-Team: LANGUAGE <LL@li.org>\n"
  8. "Language: zh_CN\n"
  9. "MIME-Version: 1.0\n"
  10. "Content-Type: text/plain; charset=UTF-8\n"
  11. "Content-Transfer-Encoding: 8bit\n"
  12. "X-Generator: Translate Toolkit 2.2.5\n"
  13. #. type: Content of: <sect1><title>
  14. #: /home/xry111/svn-repos/LFS-BOOK/chapter02/aboutlfs.xml:11
  15. msgid "Setting The $LFS Variable"
  16. msgstr "设置 $LFS 环境变量"
  17. #. type: Content of: <sect1><para>
  18. #: /home/xry111/svn-repos/LFS-BOOK/chapter02/aboutlfs.xml:13
  19. msgid ""
  20. "Throughout this book, the environment variable <envar>LFS</envar> will be "
  21. "used several times. You should ensure that this variable is always defined "
  22. "throughout the LFS build process. It should be set to the name of the "
  23. "directory where you will be building your LFS system - we will use <filename "
  24. "class=\"directory\">/mnt/lfs</filename> as an example, but the directory "
  25. "choice is up to you. If you are building LFS on a separate partition, this "
  26. "directory will be the mount point for the partition. Choose a directory "
  27. "location and set the variable with the following command:"
  28. msgstr ""
  29. "在本书中,我们经常使用环境变量 <envar>LFS</envar> 。您应该保证,在构建 LFS "
  30. "的全过程中,该变量都被定义且设置为您构建 LFS 使用的目录 —— 我们使用 "
  31. "<filename class=\"directory\">/mnt/lfs</filename> 作为例子,但您可以选择其他"
  32. "目录。如果您在一个独立的分区上构建 LFS ,那么这个目录将成为该分区的挂载点。"
  33. "选择一个目录,然后用以下命令设置环境变量:"
  34. #. type: Content of: <sect1><screen>
  35. #: /home/xry111/svn-repos/LFS-BOOK/chapter02/aboutlfs.xml:23
  36. #, no-wrap
  37. msgid "<userinput>export LFS=<replaceable>/mnt/lfs</replaceable></userinput>"
  38. msgstr "<userinput>export LFS=<replaceable>/mnt/lfs</replaceable></userinput>"
  39. #. type: Content of: <sect1><para>
  40. #: /home/xry111/svn-repos/LFS-BOOK/chapter02/aboutlfs.xml:25
  41. msgid ""
  42. "Having this variable set is beneficial in that commands such as "
  43. "<command>mkdir -v $LFS/tools</command> can be typed literally. The shell "
  44. "will automatically replace <quote>$LFS</quote> with <quote>/mnt/lfs</quote> "
  45. "(or whatever the variable was set to) when it processes the command line."
  46. msgstr ""
  47. "设置该环境变量的好处是,我们可以直接输入书中的命令,例如 <command>mkdir -v "
  48. "$LFS/tools</command> 。Shell 在解析命令时会自动将 <quote>$LFS</quote> 替换"
  49. "成 <quote>/mnt/lfs</quote> (或是您设置的其他值)。"
  50. #. type: Content of: <sect1><caution><para>
  51. #: /home/xry111/svn-repos/LFS-BOOK/chapter02/aboutlfs.xml:32
  52. msgid ""
  53. "Do not forget to check that <envar>LFS</envar> is set whenever you leave and "
  54. "reenter the current working environment (such as when doing a <command>su</"
  55. "command> to <systemitem class=\"username\">root</systemitem> or another "
  56. "user). Check that the <envar>LFS</envar> variable is set up properly with:"
  57. msgstr ""
  58. "无论何时,如果您离开并重新进入了工作环境,一定要确认 <envar>LFS</envar> 的设"
  59. "定值和您离开工作环境时相同。(例如,使用 <command>su</command> 切换到 "
  60. "<systemitem class=\"username\">root</systemitem> 或者其他用户时。) 请执行以下"
  61. "命令,检查 <envar>LFS</envar> 的设置是否正确:"
  62. #. type: Content of: <sect1><caution><screen>
  63. #: /home/xry111/svn-repos/LFS-BOOK/chapter02/aboutlfs.xml:38
  64. #, no-wrap
  65. msgid "<userinput>echo $LFS</userinput>"
  66. msgstr "<userinput>echo $LFS</userinput>"
  67. #. type: Content of: <sect1><caution><para>
  68. #: /home/xry111/svn-repos/LFS-BOOK/chapter02/aboutlfs.xml:40
  69. msgid ""
  70. "Make sure the output shows the path to your LFS system's build location, "
  71. "which is <filename class=\"directory\">/mnt/lfs</filename> if the provided "
  72. "example was followed. If the output is incorrect, use the command given "
  73. "earlier on this page to set <envar>$LFS</envar> to the correct directory "
  74. "name."
  75. msgstr ""
  76. "确认该命令的输出是您构建 LFS 的位置,如果您使用本书提供的例子,那么输出应该"
  77. "是 <filename class=\"directory\">/mnt/lfs</filename>。如果输出不正确,使用前"
  78. "文给出的命令,将 <envar>$LFS</envar> 设置成正确的目录名。"
  79. #. type: Content of: <sect1><note><para>
  80. #: /home/xry111/svn-repos/LFS-BOOK/chapter02/aboutlfs.xml:47
  81. msgid ""
  82. "One way to ensure that the <envar>LFS</envar> variable is always set is to "
  83. "edit the <filename>.bash_profile</filename> file in both your personal home "
  84. "directory and in <filename>/root/.bash_profile</filename> and enter the "
  85. "export command above. In addition, the shell specified in the <filename>/"
  86. "etc/passwd</filename> file for all users that need the <envar>LFS</envar> "
  87. "variable needs to be bash to ensure that the <filename>/root/.bash_profile</"
  88. "filename> file is incorporated as a part of the login process."
  89. msgstr ""
  90. "确保 <envar>LFS</envar> 始终正确的一种方法是:编辑您的主目录中的 <filename>."
  91. "bash_profile</filename>,以及<filename>/root/.bash_profile</filename>,为它们"
  92. "加入上述设置并导出 LFS 变量的 export 命令。还要确认 <filename>/etc/passwd</"
  93. "filename> 中为每个需要使用 <envar>LFS</envar> 变量的用户指定的 shell 都是 "
  94. "bash,以保证每次登录时都执行 <filename>.bash_profile</filename> 中的命令。"
  95. #. type: Content of: <sect1><note><para>
  96. #: /home/xry111/svn-repos/LFS-BOOK/chapter02/aboutlfs.xml:56
  97. msgid ""
  98. "Another consideration is the method that is used to log into the host "
  99. "system. If logging in through a graphical display manager, the user's "
  100. "<filename>.bash_profile</filename> is not normally used when a virtual "
  101. "terminal is started. In this case, add the export command to the <filename>."
  102. "bashrc</filename> file for the user and root. In addition, some "
  103. "distributions have instructions to not run the <filename>.bashrc</filename> "
  104. "instructions in a non-interactive bash invocation. Be sure to add the "
  105. "export command before the test for non-interactive use."
  106. msgstr ""
  107. "另外还要考虑登录宿主系统的方式,如果您使用图形显示管理器登录,再启动虚拟终"
  108. "端,那么 <filename>.bash_profile</filename> 一般不会被虚拟终端执行。此时,应"
  109. "该将 export 命令加入到您使用的用户和 root 用户的 <filename>.bashrc</"
  110. "filename> 文件中。另外,如果以非交互模式启动 bash,有的发行版不会执行 "
  111. "<filename>.bashrc</filename> 中的指令。此时一定要在使用环境变量前添加 "
  112. "export 命令。"