Browse Source

Merge trunk, add multilib.xml to prologue

git-svn-id: http://svn.linuxfromscratch.org/LFS/branches/multilib@11570 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689
Thomas Trepl 6 năm trước cách đây
mục cha
commit
ffaeec6492

+ 1 - 1
appendices/dependencies.xml

@@ -225,7 +225,7 @@
 
         <seglistitem>
           <seg>Bash, Binutils, Bison, Coreutils, GCC, Glibc,
-          Grep, Make, and Readline</seg>
+          Grep, Make, Perl, and Readline</seg>
         </seglistitem>
       </segmentedlist>
 

+ 2 - 2
chapter05/python.xml

@@ -62,8 +62,8 @@
       <varlistentry>
         <term><parameter>--without-ensurepip</parameter></term>
         <listitem>
-          <para>This switch disables the Python installer, which is not needed
-          at this stage.</para>
+          <para>This switch disables the Python package installer, which is not
+          needed at this stage.</para>
         </listitem>
       </varlistentry>
 

+ 9 - 0
chapter06/glibc.xml

@@ -128,6 +128,15 @@ cd       build</userinput></screen>
         </listitem>
       </varlistentry>
 
+      <varlistentry>
+        <term><parameter>--with-headers=/usr/include</parameter></term>
+        <listitem>
+          <para>This option tells the build system where to find the
+          kernel API headers. By default, those headers are sought in
+          <filename class="directory">/tools/include</filename>.</para>
+        </listitem>
+      </varlistentry>
+
       <varlistentry>
         <term><parameter>libc_cv_slibdir=/lib</parameter></term>
         <listitem>

+ 1 - 1
chapter06/systemd.xml

@@ -188,7 +188,7 @@ meson --prefix=/usr                \
 
 <screen><userinput remap="install">LANG=en_US.UTF-8 ninja install</userinput></screen>
 
-    <para>Remove an unnecessary directory:</para>
+    <para>Remove an unnecessary directory and file:</para>
 
 <screen><userinput remap="install">rm -rfv /usr/lib/rpm
 rm -f /usr/bin/xsltproc</userinput></screen>

+ 0 - 19
prologue/architecture.xml

@@ -61,24 +61,5 @@ problems can be worked around, but may require some specialized procedures or
 patches.</para>
 -->
 
-<para arch="multilib">You are reading the
-<emphasis>LFS-&version;-multilib</emphasis> book. Building a multilib system
-requires compiling many applications three times: once for the primary
-64-bit architecture; once for the minor 32-bit architecture; and once again for
-the 32-bit architecture with 64-bit memory extensions.</para>
-
-<para arch="multilib">Multilib goes a bit beyond the basic educational approach
-of LFS which is to teach you how to build a Linux system. If you haven't
-previously built by the standard LFS book, you are encouraged to do so before
-attempting this edition.</para>
-
-<para arch="multilib">Continue only if you meet the following requirements:
-<itemizedlist>
-  <listitem><para>you have a x86_64 compatible machine</para></listitem>
-  <listitem><para>you already have experience with LFS</para></listitem>
-  <listitem><para>you have a need for 32-bit support</para></listitem>
-</itemizedlist>
-</para>
-
 </sect1>
 

+ 99 - 0
prologue/multilib.xml

@@ -0,0 +1,99 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
+  "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
+  <!ENTITY % general-entities SYSTEM "../general.ent">
+  %general-entities;
+]>
+
+<sect1 arch="multilib" id="pre-multilib">
+  <?dbhtml filename="multilib.html"?>
+
+  <title>About the Multilib Edition</title>
+
+  <sect2><title>What is 'multilib'</title>
+
+    <para>Today, most systems in the x86 world have a word size of 64 
+      bit. The word size is a number of bits which can be used at once
+      in the most efficient way. Previous architectures of x86 processors
+      had a word size of 32 bit which means they have a different 
+      understanding of what is the best alignment of data in memory as
+      well as they have a different mechanism to address a different size
+      of memory. Even the instruction set of the 64 bit processors is 
+      quite simmilar to the instructions of 32 bit processors, binaries
+      (objects compiled to machine code) cannot directly be executed on
+      64 bit systems.</para>
+
+    <para>Multilib is a mechanism to provide support for the 32 bit 
+      binaries so that they can be executed of modern 64 bit CPUs.</para>
+
+  </sect2>
+
+  <sect2><title>Why doing multilib?</title>
+
+    <para>From a educational point of view, LFS in its 'native' form is
+      probably the best way to see how a Linux system is built from source.
+      There is no need to confuse with different architectures. But when
+      there is a need to run 32 binaries and you don't want to build the 
+      whole system in 32 bit (which would be waste of ressources 
+      nowadays) than LFS-multilib is an option. Examples for such a
+      need could be
+      <itemizedlist>
+        <listitem><para>Closed-source software without source only 
+          available for 32 bit. That may be the case for printer driver 
+          or any other kind of hardware drivers, the company provides 
+          the binaries. If you have such a driver, LFS-multilib 
+          may help you getting the stuff running</para>
+        </listitem>
+        <listitem><para>If you want to go far beyond LFS and setup a 
+          virtualization platform like <application>VirtualBox</application>,
+          you will need multilib support</para>
+        </listitem>
+        <listitem><para>or even just because you can</para>
+        </listitem>
+      </itemizedlist>
+      
+    </para>
+
+    <para>This multilib edition of LFS goes a small step beyond and a 
+      small step back to what has been said in the previous section 
+      when talking about target architectures. On one hand, the multilib 
+      edition is focused and <emphasis>limited</emphasis> to x86_64 
+      architectures only, on the other hand, it <emphasis>expands</emphasis>
+      the instructions to utilize both possible architectures, namely
+      32-bit as well as 64-bit.</para>
+
+    <para>It also goes a bit beyond the basic educational 
+      approach of LFS which is to show you how to build a Linux system. 
+      To achieve this, no support for additional architectures than 
+      the default one for your system is required. If you haven't 
+      previously built by the standard LFS book, you are encouraged to 
+      do so before using this edition.</para>
+
+  </sect2>
+
+  <sect2><title>Building a multilib system</title>
+
+    <para>Building a multilib system is not that much different from 
+      building a system by using the 'native' LFS book. Beside some 
+      tweaks here and there the most prominent difference is that 
+      multilib requires compiling many applications three times:
+      one for the primary 64-bit architecture,
+      one for the minor 32-bit architecture (m32),
+      and once again for the 32-bit architecture with 64-bit memory 
+      extensions (mx32).</para>
+
+    <para>Continue only if you and your system meets the following 
+      requirements:
+      <itemizedlist>
+        <listitem><para>you have a x86_64 compatible machine</para></listitem>
+        <listitem><para>you already have some experience with LFS</para></listitem>
+        <listitem><para>you have a need for 32-bit support</para></listitem>
+      </itemizedlist>
+    </para>
+
+    <para>If you passed all three requirements, go ahead and build LFS 
+      in multilib mode.</para>
+
+  </sect2>
+
+</sect1>

+ 1 - 0
prologue/preface.xml

@@ -14,6 +14,7 @@
   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="foreword.xml"/>
   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="audience.xml"/>
   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="architecture.xml"/>
+  <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="multilib.xml"/>
   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="standards.xml"/>
   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="why.xml"/>
   <xi:include xmlns:xi="http://www.w3.org/2001/XInclude" href="prerequisites.xml"/>