generalinstructions.xml 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120
  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. <sect1 id="ch-tools-generalinstructions">
  8. <?dbhtml filename="generalinstructions.html"?>
  9. <title>General Compilation Instructions</title>
  10. <para>When building packages there are several assumptions made within
  11. the instructions:</para>
  12. <itemizedlist>
  13. <listitem>
  14. <para>Several of the packages are patched before compilation, but only when
  15. the patch is needed to circumvent a problem. A patch is often needed in
  16. both this and the next chapter, but sometimes in only one or the other.
  17. Therefore, do not be concerned if instructions for a downloaded patch seem
  18. to be missing. Warning messages about <emphasis>offset</emphasis> or
  19. <emphasis>fuzz</emphasis> may also be encountered when applying a patch. Do
  20. not worry about these warnings, as the patch was still successfully
  21. applied.</para>
  22. </listitem>
  23. <listitem>
  24. <para>During the compilation of most packages, there will be several
  25. warnings that scroll by on the screen. These are normal and can safely be
  26. ignored. These warnings are as they appear&mdash;warnings about
  27. deprecated, but not invalid, use of the C or C++ syntax. C standards change
  28. fairly often, and some packages still use the older standard. This is not a
  29. problem, but does prompt the warning.</para>
  30. </listitem>
  31. <listitem>
  32. <para>Check one last time that the <envar>LFS</envar> environment variable
  33. is set up properly:</para>
  34. <screen role="nodump"><userinput>echo $LFS</userinput></screen>
  35. <para>Make sure the output shows the path to the LFS partition's mount
  36. point, which is <filename class="directory">/mnt/lfs</filename>, using our
  37. example.</para>
  38. </listitem>
  39. <listitem>
  40. <para>Finally, two important items must be emphasized:</para>
  41. <important>
  42. <para>The build instructions assume that the <xref
  43. linkend='ch-partitioning-hostreqs'/>, including symbolic links, have
  44. been set properly:</para>
  45. <itemizedlist role='important'>
  46. <listitem override='bullet'><para><command>bash</command> is the shell
  47. in use.</para></listitem>
  48. <listitem override='bullet'><para><command>sh</command> is a symbolic
  49. link to <command>bash</command>.</para></listitem>
  50. <listitem override='bullet'><para><command>/usr/bin/awk</command> is a
  51. symbolic link to <command>gawk</command>.</para></listitem>
  52. <listitem override='bullet'><para><command>/usr/bin/yacc</command> is a
  53. symbolic link to <command>bison</command> or a small script that
  54. executes bison.</para></listitem>
  55. </itemizedlist>
  56. </important>
  57. <important>
  58. <para>To re-emphasize the build process:</para>
  59. <orderedlist numeration="arabic" spacing="compact">
  60. <listitem>
  61. <para>Place all the sources and patches in a directory that will be
  62. accessible from the chroot environment such as
  63. <filename class="directory">/mnt/lfs/sources/</filename>.<!-- Do
  64. <emphasis>not</emphasis> put sources in
  65. <filename class="directory">/mnt/lfs/tools/</filename>. --></para>
  66. </listitem>
  67. <listitem>
  68. <para>Change to the sources directory.</para>
  69. </listitem>
  70. <listitem id='buildinstr' xreflabel='Package build instructions'>
  71. <para>For each package:</para>
  72. <orderedlist numeration="loweralpha" spacing="compact">
  73. <listitem>
  74. <para>Using the <command>tar</command> program, extract the package
  75. to be built. In Chapter&nbsp;5, ensure you are the <emphasis>lfs</emphasis>
  76. user when extracting the package.</para>
  77. </listitem>
  78. <listitem>
  79. <para>Change to the directory created when the package was
  80. extracted.</para>
  81. </listitem>
  82. <listitem>
  83. <para>Follow the book's instructions for building the package.</para>
  84. </listitem>
  85. <listitem>
  86. <para>Change back to the sources directory.</para>
  87. </listitem>
  88. <listitem>
  89. <para>Delete the extracted source directory unless instructed otherwise.</para>
  90. </listitem>
  91. </orderedlist>
  92. </listitem>
  93. </orderedlist>
  94. </important>
  95. </listitem>
  96. </itemizedlist>
  97. </sect1>