Changes in / [af944eb:0cbb853]


Ignore:
Files:
26 edited

Legend:

Unmodified
Added
Removed
  • chapter02/creatingpartition.xml

    raf944eb r0cbb853  
    105105
    106106    <sect3>
    107     <title>The Grub Bios Partition</title>
    108 
    109     <para>If the <emphasis>boot disk</emphasis> has been partitioned with a
    110     GUID Partition Table (GPT), then a small, typically 1 MB, partition must be
    111     created if it does not already exist.  This partition is not formatted, but
    112     must be available for GRUB to use during installation of the boot
    113     loader. This partition will normally be labeled 'BIOS Boot' if using
    114     <command>fdisk</command> or have a code of <emphasis>EF02</emphasis> if
    115     using the <command>gdisk</command> command.</para>
    116 
    117     <note><para>The Grub Bios partition must be on the drive that the BIOS
    118     uses to boot the system.  This is not necessarily the drive that holds
    119     the LFS root partition. The disks on a system may use different
    120     partition table types. The necessity of the Grub Bios partition depends
    121     only on the partition table type of the boot disk.</para></note>
    122     </sect3>
    123 
    124     <sect3>
    125107    <title>Convenience Partitions</title>
    126108
  • chapter04/addinguser.xml

    raf944eb r0cbb853  
    8181  <systemitem class="username">lfs</systemitem> the owner:</para>
    8282
    83 <screen><userinput>chown -v lfs $LFS/{usr{,/*},lib,var,etc,bin,sbin,tools}
    84 case $(uname -m) in
    85   x86_64) chown -v lfs $LFS/lib64 ;;
    86 esac</userinput></screen>
     83<screen><userinput>chown -v lfs $LFS/{usr{,/*},lib,var,etc,bin,sbin,tools}</userinput></screen>
    8784
    8885<note><para>In some host systems, the following <command>su</command> command does not complete
  • chapter04/creatingminlayout.xml

    raf944eb r0cbb853  
    2626for i in bin lib sbin; do
    2727  ln -sv usr/$i $LFS/$i
    28 done
    29 
    30 case $(uname -m) in
    31   x86_64) mkdir -pv $LFS/lib64 ;;
    32 esac</userinput></screen>
     28done</userinput></screen>
    3329
    3430  <para>Programs in <xref linkend="chapter-temporary-tools"/> will be compiled
  • chapter05/gcc-pass1.xml

    raf944eb r0cbb853  
    6363mv -v mpc-&mpc-version; mpc</userinput></screen>
    6464
    65     <para>On x86_64 hosts, set the default directory name for
     65    <para>On ARM64 hosts, set the default directory name for
    6666    64-bit libraries to <quote>lib</quote>:</para>
    6767
    68 <screen><userinput remap="pre">case $(uname -m) in
    69   x86_64)
    70     sed -e '/m64=/s/lib64/lib/' \
    71         -i.orig gcc/config/i386/t-linux64
    72  ;;
    73 esac</userinput></screen>
     68<screen><userinput remap="pre">sed -e '/lp64=/s/lib64/lib/' \
     69    -i.orig gcc/config/aarch64/t-aarch64-linux</userinput></screen>
    7470
    7571    <para>The GCC documentation recommends building GCC
     
    160156        <term><parameter>--disable-multilib</parameter></term>
    161157        <listitem>
    162           <para>On x86_64, LFS does not support a multilib configuration.
    163           This switch is harmless for x86.</para>
     158          <para>On ARM64, LFS does not support a multilib configuration.</para>
    164159        </listitem>
    165160      </varlistentry>
  • chapter05/glibc.xml

    raf944eb r0cbb853  
    4343  <sect2 role="installation">
    4444    <title>Installation of Glibc</title>
    45 
    46     <para>First, create a symbolic link for LSB compliance. Additionally,
    47     for x86_64, create a compatibility symbolic link required for proper
    48     operation of the dynamic library loader:</para>
    49 
    50 <screen><userinput remap="pre">case $(uname -m) in
    51     i?86)   ln -sfv ld-linux.so.2 $LFS/lib/ld-lsb.so.3
    52     ;;
    53     x86_64) ln -sfv ../lib/ld-linux-x86-64.so.2 $LFS/lib64
    54             ln -sfv ../lib/ld-linux-x86-64.so.2 $LFS/lib64/ld-lsb-x86-64.so.3
    55     ;;
    56 esac</userinput></screen>
    57 
    58     <note>
    59       <para>
    60         The above command is correct.  The <command>ln</command> command has
    61         several syntactic versions, so be sure to check
    62         <command>info coreutils ln</command> and <filename>ln(1)</filename>
    63         before reporting what may appear to be an error.
    64       </para>
    65     </note>
    6645
    6746    <para>Fix an issue building Glibc with parallel jobs and make-4.4
     
    207186      and the output of the last command will be of the form:</para>
    208187
    209 <screen><computeroutput>[Requesting program interpreter: /lib64/ld-linux-x86-64.so.2]</computeroutput></screen>
    210 
    211       <para>Note that for 32-bit machines, the interpreter name will be
    212       <filename>/lib/ld-linux.so.2</filename>.</para>
     188<screen><computeroutput>[Requesting program interpreter: /lib/ld-linux-aarch64.so.1]</computeroutput></screen>
     189
     190      <para>Note that for big-endian machines, the interpreter name will be
     191          <filename>/lib/ld-linux-aarch64_be.so.1</filename>.</para>
    213192
    214193      <para>If the output is not as shown above, or there is no output at all,
  • chapter06/gcc-pass2.xml

    raf944eb r0cbb853  
    5858mv -v mpc-&mpc-version; mpc</userinput></screen>
    5959
    60     <para>If building on x86_64, change the default directory name for 64-bit
    61     libraries to <quote>lib</quote>:</para>
     60    <para>On ARM64 hosts, set the default directory name for
     61    64-bit libraries to <quote>lib</quote>:</para>
    6262
    63 <screen><userinput remap="pre">case $(uname -m) in
    64   x86_64)
    65     sed -e '/m64=/s/lib64/lib/' -i.orig gcc/config/i386/t-linux64
    66   ;;
    67 esac</userinput></screen>
     63<screen><userinput remap="pre">sed -e '/lp64=/s/lib64/lib/' \
     64    -i.orig gcc/config/aarch64/t-aarch64-linux</userinput></screen>
    6865
    6966    <para>Override the building rule of libgcc and libstdc++ headers, to
  • chapter07/changingowner.xml

    raf944eb r0cbb853  
    3434  command:</para>
    3535
    36 <screen><userinput>chown -R root:root $LFS/{usr,lib,var,etc,bin,sbin,tools}
    37 case $(uname -m) in
    38   x86_64) chown -R root:root $LFS/lib64 ;;
    39 esac</userinput></screen>
     36<screen><userinput>chown -R root:root $LFS/{usr,lib,var,etc,bin,sbin,tools}</userinput></screen>
    4037
    4138</sect1>
  • chapter08/binutils.xml

    raf944eb r0cbb853  
    139139          ultimately be located) is set to <filename
    140140          class="directory">$(exec_prefix)/$(target_alias)</filename>. For
    141           example, x86_64 machines would expand that to <filename
    142           class="directory">/usr/x86_64-pc-linux-gnu</filename>. Because this is
     141          example, ARM64 machines would expand that to <filename
     142          class="directory">/usr/aarch64-unknown-linux-gnu</filename>. Because this is
    143143          a custom system, this target-specific directory in <filename
    144144          class="directory">/usr</filename> is not required. <filename
     
    165165<screen><userinput remap="test">grep '^FAIL:' $(find -name '*.log')</userinput></screen>
    166166
    167     <para>Twelve tests fail in the gold test suite when the
    168     <option>--enable-default-pie</option> and
    169     <option>--enable-default-ssp</option> options are passed to GCC.
     167    <para>
    170168    <!-- Caused by egrep deprecation.  Note that we don't "patch" temp grep.
    171169         And it seems unworthy to add a sed into temp grep just for one test
     
    173171         anyway.)
    174172         Will be fixed in 2.40 (upstream commit 67d1991). -->
    175     The test named <filename>ar with versioned solib</filename> is also
     173    The test named <filename>ar with versioned solib</filename> is
    176174    known to fail.
    177175    <!-- https://sourceware.org/bugzilla/show_bug.cgi?id=29107 -->
  • chapter08/expect.xml

    raf944eb r0cbb853  
    4848  <sect2 role="installation">
    4949    <title>Installation of Expect</title>
     50
     51    <para>Update two config scripts to allow building this package for
     52    AArch64:</para>
     53
     54<screen><userinput remap="pre">tar -C tclconfig -xf ../autoconf-&autoconf-version;.tar.xz --strip-components=2 \
     55    autoconf-&autoconf-version;/build-aux/config.{guess,sub}</userinput></screen>
    5056
    5157    <para>Prepare Expect for compilation:</para>
  • chapter08/findutils.xml

    raf944eb r0cbb853  
    4848    <para>Prepare Findutils for compilation:</para>
    4949
    50 <screen><userinput remap="configure">case $(uname -m) in
    51     i?86)   TIME_T_32_BIT_OK=yes ./configure --prefix=/usr --localstatedir=/var/lib/locate ;;
    52     x86_64) ./configure --prefix=/usr --localstatedir=/var/lib/locate ;;
    53 esac</userinput></screen>
     50<screen><userinput remap="configure">./configure --prefix=/usr --localstatedir=/var/lib/locate</userinput></screen>
    5451
    5552    <variablelist>
    5653      <title>The meaning of the configure options:</title>
    57 
    58       <varlistentry>
    59         <term><command>TIME_32_BIT_OK=yes</command></term>
    60         <listitem>
    61           <para>This setting is needed for building on a 32 bit system.</para>
    62         </listitem>
    63       </varlistentry>
    6454
    6555      <varlistentry>
  • chapter08/gcc.xml

    raf944eb r0cbb853  
    5555    <screen><userinput remap="pre">patch -Np1 -i ../&gcc-upstream-fixes-patch;</userinput></screen>
    5656-->
    57     <para>If building on x86_64, change the default directory name for 64-bit
    58     libraries to <quote>lib</quote>:</para>
    59 
    60 <screen><userinput remap="pre">case $(uname -m) in
    61   x86_64)
    62     sed -e '/m64=/s/lib64/lib/' \
    63         -i.orig gcc/config/i386/t-linux64
    64   ;;
    65 esac</userinput></screen>
     57    <para>On ARM64 hosts, set the default directory name for
     58    64-bit libraries to <quote>lib</quote>:</para>
     59
     60<screen><userinput remap="pre">sed -e '/lp64=/s/lib64/lib/' \
     61    -i.orig gcc/config/aarch64/t-aarch64-linux</userinput></screen>
    6662
    6763    <para>The GCC documentation recommends building GCC in a dedicated build directory:</para>
     
    161157    <ulink url="https://gcc.gnu.org/ml/gcc-testresults/"/>.</para>
    162158
    163     <para>Eleven tests in the i386 test suite for the gcc compiler are known to FAIL.
    164     It's because the test files do not account for the
     159    <para>In gcc tests, the tests related to
     160    <filename>fuse_adrp_add_1.c</filename>,
     161    <filename>pr63304_1.c</filename>,
     162    <filename>pr70120-2.c</filename>,
     163    <filename>pr78733.c</filename>,
     164    <filename>pr78796.c</filename>,
     165    <filename>pr79041-2.c</filename>,
     166    <filename>pr94530.c</filename>,
     167    <filename>pr94577.c</filename>,
     168    <filename>reload-valid-spoff.c</filename>, and
     169    many <filename>aapcs64</filename> tests are known to fail.
     170    They are because the test files do not account for the
    165171    <parameter>--enable-default-pie</parameter> option.</para>
    166172
    167     <para>Four tests related to PR100400 may be reported
    168     as both XPASS and FAIL when testing the g++ compiler; the test file
     173    <para>In gcc tests, the tests related to
     174    <filename>pr104005.c</filename>,
     175    <filename>pr103147-10.C</filename>,
     176    <filename>shrink_wrap_1.c</filename>,
     177    <filename>stack-check-cfa-1.c</filename>,
     178    <filename>stack-check-cfa-2.c</filename>,
     179    <filename>test_frame_17.c</filename>, and
     180    many <filename>sve/pcs</filename> tests are known
     181    to fail.  The g++ test related to <filename>pr103147-10.C</filename>
     182    is known to fail.  They are because the test files do not account for
     183    the <parameter>--enable-default-ssp</parameter> option.</para>
     184
     185    <para>In g++, four tests related to PR100400 are known to be reported
     186    as both XPASS and FAIL.  It's because the test file for this known issue
    169187    is not well written.</para>
     188
     189    <!-- Already known via gcc-testresults@gcc.gnu.org -->
     190    <para>On ARM64,
     191    four g++ tests related to <filename>Waddress-5.C</filename>,
     192    twelve g++ tests related to <filename>attrs-10.C</filename>,
     193    four g++ tests related to <filename>declare-simd-8.C</filename>,
     194    one gcc tests related to <filename>ssa-dom-thread-7.c</filename>,
     195    one gcc tests related to <filename>fcsel_1.c</filename>,
     196    one gcc tests related to <filename>mgeneral-regs_3.c</filename>, and
     197    four gcc tests related to <filename>vqdmlalh_laneq*.c</filename>
     198    are known to fail.</para>
     199
     200    <!-- Need further investigation -->
     201    <para>Many gcc and g++ tests related to hwasan are known to fail.
     202    And, two tests related to <filename>thread_leak1.c</filename> are known
     203    to fail for both gcc and g++.</para>
    170204
    171205    <para>A few unexpected failures cannot always be avoided. The GCC developers
     
    224258  platform-specific differences in the dynamic linker name):</para>
    225259
    226 <screen><computeroutput>[Requesting program interpreter: /lib64/ld-linux-x86-64.so.2]</computeroutput></screen>
     260<screen><computeroutput>[Requesting program interpreter: /lib/ld-linux-aarch64.so.1]</computeroutput></screen>
    227261
    228262  <para>Now make sure that we're set up to use the correct start files:</para>
     
    232266  <para>The output of the last command should be:</para>
    233267
    234 <screen><computeroutput>/usr/lib/gcc/x86_64-pc-linux-gnu/&gcc-version;/../../../../lib/Scrt1.o succeeded
    235 /usr/lib/gcc/x86_64-pc-linux-gnu/&gcc-version;/../../../../lib/crti.o succeeded
    236 /usr/lib/gcc/x86_64-pc-linux-gnu/&gcc-version;/../../../../lib/crtn.o succeeded</computeroutput></screen>
     268<screen><computeroutput>/usr/lib/gcc/aarch64-unknown-linux-gnu/&gcc-version;/../../../../lib/Scrt1.o succeeded
     269/usr/lib/gcc/aarch64-unknown-linux-gnu/&gcc-version;/../../../../lib/crti.o succeeded
     270/usr/lib/gcc/aarch64-unknown-linux-gnu/&gcc-version;/../../../../lib/crtn.o succeeded</computeroutput></screen>
    237271
    238272  <para>Depending on your machine architecture, the above may differ slightly.
     
    251285
    252286<screen><computeroutput>#include &lt;...&gt; search starts here:
    253  /usr/lib/gcc/x86_64-pc-linux-gnu/&gcc-version;/include
     287 /usr/lib/gcc/aarch64-unknown-linux-gnu/&gcc-version;/include
    254288 /usr/local/include
    255  /usr/lib/gcc/x86_64-pc-linux-gnu/&gcc-version;/include-fixed
     289 /usr/lib/gcc/aarch64-unknown-linux-gnu/&gcc-version;/include-fixed
    256290 /usr/include</computeroutput></screen>
    257291
     
    266300  be ignored, but otherwise the output of the last command should be:</para>
    267301
    268 <screen><computeroutput>SEARCH_DIR("/usr/x86_64-pc-linux-gnu/lib64")
     302<screen><computeroutput>SEARCH_DIR("/usr/aarch64-unknown-linux-gnu/lib64")
    269303SEARCH_DIR("/usr/local/lib64")
    270304SEARCH_DIR("/lib64")
    271305SEARCH_DIR("/usr/lib64")
    272 SEARCH_DIR("/usr/x86_64-pc-linux-gnu/lib")
     306SEARCH_DIR("/usr/aarch64-unknown-linux-gnu/lib")
    273307SEARCH_DIR("/usr/local/lib")
    274308SEARCH_DIR("/lib")
     
    302336  platform-specific differences in dynamic linker name):</para>
    303337
    304 <screen><computeroutput>found ld-linux-x86-64.so.2 at /usr/lib/ld-linux-x86-64.so.2</computeroutput></screen>
     338<screen><computeroutput>found ld-linux-aarch64.so.1 at /usr/lib/ld-linux-aarch64.so.1</computeroutput></screen>
    305339
    306340  <para>If the output does not appear as shown above or is not received
  • chapter08/glibc.xml

    raf944eb r0cbb853  
    447447
    448448    <para>By default, the dynamic loader (<filename
    449     class="libraryfile">/lib/ld-linux.so.2</filename>) searches through
     449    class="libraryfile">/lib/ld-linux-aarch64.so.1</filename>) searches through
    450450    <filename class="directory">/usr/lib</filename> for dynamic libraries
    451451    that are needed by programs as they are run. However, if there are
     
    495495        <seg>gencat, getconf, getent, iconv, iconvconfig, ldconfig,
    496496        ldd, lddlibc4,
    497         ld.so (symlink to ld-linux-x86-64.so.2 or ld-linux.so.2),
     497        ld.so (symlink to ld-linux-aarch64[_be].so.1),
    498498        locale, localedef, makedb, mtrace, nscd,
    499499        pcprofiledump, pldd, sln, sotruss, sprof, tzselect, xtrace,
    500500        zdump, and zic</seg>
    501         <seg>ld-linux-x86-64.so.2, ld-linux.so.2,
     501        <seg>ld-linux-aarch64[_be].so.1,
    502502        libBrokenLocale.{a,so}, libanl.{a,so},
    503503        libc.{a,so}, libc_nonshared.a, libc_malloc_debug.so,
  • chapter08/gmp.xml

    raf944eb r0cbb853  
    4141  <sect2 role="installation">
    4242    <title>Installation of GMP</title>
    43 
    44     <note>
    45       <para>If you are building for 32-bit x86, but you have a CPU which is
    46       capable of running 64-bit code <emphasis>and</emphasis> you have specified
    47       <envar>CFLAGS</envar> in the environment, the configure script will
    48       attempt to configure for 64-bits and fail.
    49       Avoid this by invoking the configure command below with
    50 <screen role="nodump"><userinput><parameter>ABI=32</parameter> ./configure ...</userinput></screen></para>
    51     </note>
    5243
    5344    <note>
     
    10798    applications using the gmp libraries with the message "Illegal
    10899    instruction".  In this case, gmp should be reconfigured with the option
    109     --build=x86_64-pc-linux-gnu and rebuilt.</para></caution>
     100    --build=aarch64-unknown-linux-gnu and rebuilt.</para></caution>
    110101
    111102    <para>Ensure that all 197 tests in the test suite passed.
  • chapter08/grub.xml

    raf944eb r0cbb853  
    4343    <note>
    4444      <para>
     45        On ARM64 systems, the following instruction builds GRUB for UEFI.
     46        But the built GRUB lacks some features because a few optional
     47        dependencies of GRUB for UEFI is beyond the scope of LFS and not
     48        installed yet.
     49      </para>
     50      <para>
     51        If your system firmware does not support UEFI, you need to skip the
     52        content of this page and try to figure out how to boot your system.
     53      </para>
     54      <para>
    4555        If your system has UEFI support and you wish to boot LFS with UEFI,
    4656        you can skip this package in LFS,
    4757        and install GRUB with UEFI support (and its dependencies) by following
    4858        the instructions on
    49         <ulink url="&blfs-book;postlfs/grub-efi.html">the BLFS page</ulink>.
     59        <ulink url="&blfs-book;postlfs/grub-efi.html">the BLFS page</ulink>
     60        (with <parameter>--target=x86_64</parameter> removed).
    5061      </para>
    5162    </note>
  • chapter08/kbd.xml

    raf944eb r0cbb853  
    4545    across the keymaps in the Kbd package. The following patch fixes this
    4646    issue for i386 keymaps:</para>
     47
     48    <note>
     49      <para>
     50        Don't skip the patch just because it mentions "i386".  The keymaps
     51        for the keyboards most common on the market (qwerty or dvorak) are
     52        in "i386" catagory.
     53      </para>
     54    </note>
    4755
    4856<screen><userinput remap="pre">patch -Np1 -i ../&kbd-backspace-patch;</userinput></screen>
  • chapter08/libcap.xml

    raf944eb r0cbb853  
    6060          <para>This parameter sets the library directory to
    6161          <filename>/usr/lib</filename> rather than
    62           <filename>/usr/lib64</filename> on x86_64. It has no effect on
    63           x86.</para>
     62          <filename>/usr/lib64</filename> on ARM64.</para>
    6463        </listitem>
    6564      </varlistentry>
  • chapter08/libelf.xml

    raf944eb r0cbb853  
    6060
    6161    <para>One test named <filename>run-low_high_pc.sh</filename> is known to
    62     fail on 32-bit x86 systems.</para>
     62    fail on ARM64 systems.</para>
    6363
    6464    <para>Install only Libelf:</para>
  • chapter08/libffi.xml

    raf944eb r0cbb853  
    7878          system, use the less capable system as a parameter. For details
    7979          about alternative system types, see <ulink
    80           url='https://gcc.gnu.org/onlinedocs/gcc-&gcc-version;/gcc/x86-Options.html'>
    81           the x86 options in the GCC manual</ulink>.</para>
     80          url='https://gcc.gnu.org/onlinedocs/gcc-&gcc-version;/gcc/AArch64-Options.html'>
     81          the AArch64 options in the GCC manual</ulink>.</para>
    8282        </listitem>
    8383      </varlistentry>
     
    102102
    103103<screen><userinput remap="test">make check</userinput></screen>
     104
     105    <!-- https://github.com/libffi/libffi/actions/runs/3084390461/jobs/4986488117 -->
     106    <para>90 tests are known to fail on ARM64.</para>
    104107
    105108    <para>Install the package:</para>
  • chapter08/stripping.xml

    raf944eb r0cbb853  
    4747  rationale for using the <command>install</command> command here.)</para>
    4848
    49   <note><para>The ELF loader's name is ld-linux-x86-64.so.2 on 64-bit systems
    50   and ld-linux.so.2 on 32-bit systems.  The construct below selects the
     49  <note><para>The ELF loader's name is ld-linux-aarch64.so.1 on
     50  little-endian systems and ld-linux-aarch64_be.so.1 on big-endian systems.
     51  The construct below selects the
    5152  correct name for the current architecture, excluding anything ending
    5253  with <quote>g</quote>, in case the commands below have already been
  • chapter08/util-linux.xml

    raf944eb r0cbb853  
    127127        eject, fallocate, fdisk, fincore, findfs, findmnt, flock, fsck,
    128128        fsck.cramfs, fsck.minix, fsfreeze, fstrim, getopt, hardlink, hexdump, hwclock,
    129         i386 (link to setarch), ionice, ipcmk, ipcrm, ipcs, irqtop, isosize, kill, last,
     129        ionice, ipcmk, ipcrm, ipcs, irqtop, isosize, kill, last,
    130130        lastb (link to last), ldattach, linux32 (link to setarch), linux64 (link to setarch),
    131131        logger, look, losetup, lsblk, lscpu, lsipc, lsirq, lsfd, lslocks, lslogins,
     
    136136        swapoff, swapon, switch_root, taskset, uclampset, ul,
    137137        umount, uname26 (link to setarch), unshare, utmpdump, uuidd, uuidgen, uuidparse,
    138         wall, wdctl, whereis, wipefs, x86_64 (link to setarch), and zramctl</seg>
     138        wall, wdctl, whereis, wipefs, and zramctl</seg>
    139139        <seg>libblkid.so, libfdisk.so, libmount.so,
    140140        libsmartcols.so, and libuuid.so</seg>
     
    519519      </varlistentry>
    520520
    521       <varlistentry id="i386">
    522         <term><command>i386</command></term>
    523         <listitem>
    524           <para>A symbolic link to setarch</para>
    525           <indexterm zone="ch-system-util-linux i386">
    526             <primary sortas="b-i386">i386</primary>
    527           </indexterm>
    528         </listitem>
    529       </varlistentry>
    530 
    531521      <varlistentry id="ionice">
    532522        <term><command>ionice</command></term>
     
    12781268      </varlistentry>
    12791269
    1280       <varlistentry id="x86_64">
    1281         <term><command>x86_64</command></term>
    1282         <listitem>
    1283           <para>A symbolic link to setarch</para>
    1284           <indexterm zone="ch-system-util-linux x86_64">
    1285             <primary sortas="b-x86_64">x86_64</primary>
    1286           </indexterm>
    1287         </listitem>
    1288       </varlistentry>
    1289 
    12901270      <varlistentry id="zramctl">
    12911271        <term><command>zramctl</command></term>
  • chapter10/grub.xml

    raf944eb r0cbb853  
    1919  <note>
    2020    <para>
    21       If your system has UEFI support and you wish to boot LFS with UEFI,
    22       you should skip this page, and configure GRUB with UEFI support
     21      This section assume your system has UEFI support and you wish to boot
     22      LFS with UEFI and GRUB built following the instructions in Chapter 8.
     23    </para>
     24    <para>
     25      If you've installed GRUB for UEFI with optional dependencies following
     26      BLFS, you should skip this page, and configure GRUB with UEFI support
    2327      using the instructions provided in
    24       <ulink url="&blfs-book;postlfs/grub-setup.html">the BLFS page</ulink>.
     28      <ulink url="&blfs-book;postlfs/grub-setup.html">the BLFS page</ulink>,
     29      but replace <parameter>--target=x86_64-efi</parameter> with
     30      <parameter>--target=arm64-efi</parameter> for the ARM64 system.
     31    </para>
     32    <para>
     33      If your system does not support UEFI or you don't want to use it,
     34      you'll need to figure out how to configure the booting process of
     35      the system on your own.
    2536    </para>
    2637  </note>
     
    3546    LILO.</para></warning>
    3647
    37     <para> Ensure that an emergency boot disk is ready to <quote>rescue</quote>
     48    <para>Ensure that an emergency boot disk is ready to <quote>rescue</quote>
    3849    the computer if the computer becomes unusable (un-bootable).  If you do not
    39     already have a boot device, you can create one.  In order for the procedure
    40     below to work, you need to jump ahead to BLFS and install
    41     <userinput>xorriso</userinput> from the <ulink
    42     url="&blfs-book;multimedia/libisoburn.html">
    43     libisoburn</ulink> package.</para>
    44 
    45 <screen role="nodump"><userinput>cd /tmp
    46 grub-mkrescue --output=grub-img.iso
    47 xorriso -as cdrecord -v dev=/dev/cdrw blank=as_needed grub-img.iso</userinput></screen>
    48 
     50    already have a boot device, you can create one.  To create a emergency
     51    boot device for UEFI, consult section <quote>Create an Emergency Boot
     52    Disk</quote> in
     53        <ulink url="&blfs-book;postlfs/grub-setup.html">the BLFS page</ulink>.</para>
     54
     55  </sect2>
     56
     57  <sect2>
     58    <title>Turn off Secure Boot</title>
     59
     60    <para>LFS does not have the essential packages to support Secure Boot.
     61    To set up the boot process following the instructions in this section,
     62    Secure Boot must be turned off from the configuration interface of the
     63    firmware. Read the documentation provided by the manufacturer of your
     64    system to find out how.</para>
    4965  </sect2>
    5066
     
    7288    <title>Setting Up the Configuration</title>
    7389
    74     <para>GRUB works by writing data to the first physical track of the
    75     hard disk.  This area is not part of any file system.  The programs
    76     there access GRUB modules in the boot partition.  The default location
    77     is /boot/grub/.</para>
     90    <para>GRUB works by creating an EFI executable in the EFI System
     91    Partition (ESP).  You can find the ESP with:</para>
     92
     93<screen role="nodump"><userinput>fdisk -l | grep 'EFI System'</userinput></screen>
     94
     95    <para>If no ESP exists on your hard drive (for example, you are building
     96    LFS on a fresh new system with a Live CD as the host distro), read
     97    <ulink url="&blfs-book;postlfs/grub-setup.html">the BLFS page</ulink>
     98    for the instruction to create an ESP on your hard drive.</para>
     99
     100    <para>If the ESP is not mounted at
     101    <filename class="directory">/boot/efi</filename> (in the chroot),
     102    mount it now:</para>
     103
     104<screen role="nodump"><userinput>mkdir -pv /boot/efi
     105mount /boot/efi</userinput></screen>
     106
     107    <note>
     108      <para>The path to the device node is intentionally omitted in the
     109      command.  We expect the entry for mounting the ESP to
     110      <filename class="directory">/boot/efi</filename> is already in
     111      <filename>/etc/fstab</filename>.  Add the entry before running the
     112      command if you forgot to create an entry for the ESP in
     113      <xref linkend="ch-bootable-fstab"/>.</para>
     114    </note>
    78115
    79116    <para>The location of the boot partition is a choice of the user that
     
    100137
    101138    <para>Install the GRUB files into <filename
    102     class="directory">/boot/grub</filename> and set up the boot track:</para>
     139    class="directory">/boot/grub</filename> and the GRUB EFI executable into
     140    <filename class="directory">/boot/efi/EFI/BOOTAA64.EFI</filename>:</para>
    103141
    104142    <warning>
    105       <para>The following command will overwrite the current boot loader. Do not
    106       run the command if this is not desired, for example, if using a third party
    107       boot manager to manage the Master Boot Record (MBR).</para>
     143      <para>The following command will overwrite
     144      <filename>BOOTAA64.EFI</filename>. Do not run the command if this is
     145      not desired, for example, if it contains a third party boot manager.
     146      You can backup it with <command>cp</command> as it's a regular
     147      file.</para>
    108148    </warning>
    109149
    110 <screen role="nodump"><userinput>grub-install /dev/sda</userinput></screen>
     150<screen role="nodump"><userinput>grub-install --removable</userinput></screen>
    111151
    112152    <note>
    113       <para>If the system has been booted using UEFI,
    114       <command>grub-install</command> will try to install files for the
    115       <emphasis>x86_64-efi</emphasis> target, but those files
    116       have not been installed in <xref linkend="chapter-building-system"/>.
    117       If this is the case, add <option>--target i386-pc</option> to the
    118       command above.</para>
     153      <para>
     154        <parameter>--removable</parameter> may seem strange here.  The UEFI
     155        firmware searches EFI executables for boot loaders in a hardcoded
     156        path, <filename>EFI/BOOTAA64.EFI</filename> in the ESP, and other
     157        boot loader paths listed in the EFI variables.  We've not installed
     158        the utilities for manipulating EFI variables so we need to install
     159        the EFI executable into the hardcoded path.  The hardcoded path is
     160        usually used by removable devices (for example, USB thumb devices)
     161        so the <command>grub-install</command> option for this purpose is
     162        named <parameter>--removable</parameter>.
     163      </para>
     164      <para>
     165        UEFI implementation usually prefers the boot loaders with paths
     166        recorded in an EFI variable, to the boot loader with the hardcoded
     167        search path.  You may need to invoke the boot device selection menu
     168        or setting interface of your EFI firmware on next boot to explicitly
     169        select the bootloader.
     170      </para>
     171      <para>
     172        Some UEFI implementation may completely skip the hardcoded path if
     173        there are other boot loaders in the same hard drive with paths
     174        recorded in an EFI variable.  Then you need to create an EFI
     175        variable for the newly installed boot loader.  Install
     176        <ulink url="&blfs-book;postlfs/efibootmgr.html">efibootmgr</ulink>,
     177        then run the following commands:
     178
     179<screen role="nodump"><userinput>mount -v -t efivarfs efivarfs /sys/firmware/efi/efivars
     180efibootmgr -B -L LFS || true
     181efibootmgr -c -L LFS -l '\EFI\BOOT\BOOTAA64.EFI' -d /dev/sda
     182umount /sys/firmware/efi/efivars</userinput></screen>
     183
     184        Replace <filename>/dev/sda</filename> with the device node of the
     185        hard drive where you are installing GRUB into.  For some UEFI
     186        firmwares, <option>-e 3</option> option may be needed for the
     187        <command>efibootmgr -c</command> command.
     188      </para>
    119189    </note>
    120190
  • chapter10/kernel.xml

    raf944eb r0cbb853  
    165165       Pseudo filesystems  ---&gt;
    166166        [*] Tmpfs POSIX Access Control Lists [CONFIG_TMPFS_POSIX_ACL]</screen>
    167 
    168       <para>Enable some additional features if you are building a 64-bit
    169       system.  If you are using menuconfig, enable them in the order of
    170       <parameter>CONFIG_PCI_MSI</parameter> first, then
    171       <parameter>CONFIG_IRQ_REMAP</parameter>, at last
    172       <parameter>CONFIG_X86_X2APIC</parameter> because an option only
    173       shows up after its dependencies are selected.</para>
    174 
    175       <screen role="nodump">Processor type and features ---&gt;
    176   [*] Support x2apic [CONFIG_X86_X2APIC]
    177 Device Drivers ---&gt;
    178   [*] PCI Support ---&gt; [CONFIG_PCI]
    179     [*] Message Signaled Interrupts (MSI and MSI-X) [CONFIG_PCI_MSI]
    180   [*] IOMMU Hardware Support ---&gt; [CONFIG_IOMMU_SUPPORT]
    181     [*] Support for Interrupt Remapping [CONFIG_IRQ_REMAP]</screen>
    182167    </note>
    183168
     
    288273      </varlistentry>
    289274
    290       <varlistentry>
    291         <term><parameter>Support x2apic</parameter></term>
    292         <listitem>
    293           <para>Support running the interrupt controller of 64-bit x86
    294           processors in x2APIC mode.  x2APIC may be enabled by firmware on
    295           64-bit x86 systems, and a kernel without this option enabled will
    296           panic on boot if x2APIC is enabled by firmware.  This option has
    297           has no effect, but also does no harm if x2APIC is disabled by the
    298           firmware.</para>
    299         </listitem>
    300       </varlistentry>
    301 
    302275    </variablelist>
    303276
     
    354327    the filename should be <emphasis>vmlinuz</emphasis> to be compatible with
    355328    the automatic setup of the boot process described in the next section.  The
    356     following command assumes an x86 architecture:</para>
    357 
    358 <screen><userinput remap="install">cp -iv arch/x86/boot/bzImage /boot/vmlinuz-&linux-version;-lfs-&version;</userinput></screen>
     329    following command assumes an ARM64 architecture:</para>
     330
     331<screen><userinput remap="install">cp -iv arch/arm64/boot/Image /boot/vmlinuz-&linux-version;-lfs-&version;</userinput></screen>
    359332
    360333    <para><filename>System.map</filename> is a symbol file for the kernel.
  • general.ent

    raf944eb r0cbb853  
    9292<!ENTITY test-results    "&lfs-root;lfs/build-logs/&generic-version;/">
    9393<!ENTITY secadv          "&lfs-root;lfs/advisories/">
    94 <!ENTITY min-kernel      "3.2">
     94<!ENTITY min-kernel      "3.7">
    9595<!--
    9696<!ENTITY patches-rootd   "&lfs-root;patches/lfs/&generic-versiond;/">
  • git-version.sh

    raf944eb r0cbb853  
    4949
    5050sha="$(git describe --abbrev=1)"
    51 rev=$(echo "$sha" | sed 's/-g[^-]*$//')
     51rev=arm64-$(echo "$sha" | sed 's/-g[^-]*$//')
    5252version="$rev"
    5353versiond="$rev-systemd"
  • prologue/architecture.xml

    raf944eb r0cbb853  
    1111  <title>LFS Target Architectures</title>
    1212
    13 <para>The primary target architectures of LFS are the AMD/Intel x86 (32-bit)
    14 and x86_64 (64-bit) CPUs.  On the other hand, the instructions in this book are
    15 also known to work, with some modifications, with the Power PC and ARM CPUs. To
    16 build a system that utilizes one of these alternative CPUs, the main prerequisite, in
    17 addition to those on the next page, is an existing Linux system such as an
    18 earlier LFS installation, Ubuntu, Red Hat/Fedora, SuSE, or some other distribution
    19 that targets that architecture. (Note that a 32-bit
    20 distribution can be installed and used as a host system on a 64-bit AMD/Intel
    21 computer.)</para>
     13<para>The target architectures of this LFS edition are ARM64 (sometimes
     14called AArch64) CPUs.  On the other hand, the instructions in this book may
     15work on 32-bit ARM CPUs with some modifications. To build a system that
     16utilizes one of these alternative CPUs, the main prerequisite, in
     17addition to those on
     18the next page, is an existing Linux system such as an earlier LFS
     19installation, Ubuntu, Red Hat/Fedora, SuSE, or other distribution that
     20targets the architecture that you have.</para>
    2221
    23 <para>The gain from building on a 64-bit system, as
    24 compared to a 32-bit system, is minimal.
    25 For example, in a test build of LFS-9.1 on a Core i7-4790 CPU based system,
    26 using 4 cores, the following statistics were measured:</para>
    27 
    28 <screen><computeroutput>Architecture Build Time     Build Size
    29 32-bit       239.9 minutes  3.6 GB
    30 64-bit       233.2 minutes  4.4 GB</computeroutput></screen>
    31 
    32 <para>As you can see, on the same hardware, the 64-bit build is only 3% faster
    33 (and 22% larger) than the 32-bit build. If you plan to use LFS as a LAMP
    34 server, or a firewall, a 32-bit CPU may be good enough. On the other
    35 hand, several packages in BLFS now need more than 4 GB of RAM to be built
    36 and/or to run; if you plan to use LFS as a desktop, the LFS authors
    37 recommend building a 64-bit system.</para>
    38 
    39 <para>The default 64-bit build that results from LFS is a
    40 <quote>pure</quote> 64-bit system. That is, it supports 64-bit executables
    41 only. Building a <quote>multi-lib</quote> system requires compiling many
     22<para>The build results from this LFS edition is considered a
     23<quote>pure</quote> 64-bit system.  That is, it supports 64-bit executables
     24only.  Building a <quote>multi-lib</quote> system requires compiling many
    4225applications twice, once for a 32-bit system and once for a 64-bit system.
    4326This is not directly supported in LFS because it would interfere with the
    4427educational objective of providing the minimal instructions needed for a
    45 basic Linux system. Some of the LFS/BLFS editors maintain a multilib fork
     28base Linux system. Some LFS/BLFS editors maintain a multilib fork
    4629of LFS, accessible at <ulink
    4730url="https://www.linuxfromscratch.org/~thomas/multilib/index.html"/>. But
    48 that's an advanced topic.</para>
     31the multilib edition is for x86_64, and multilib is an advanced topic
     32anyway.</para>
    4933
    5034</sect1>
  • prologue/standards.xml

    raf944eb r0cbb853  
    3636        specifications are architecture specific.  There are also two trial
    3737        specifications: Gtk3 and Graphics.  LFS attempts to conform to the LSB
    38         specifications for the IA32 (32-bit x86) or AMD64 (x86_64)
    39         architectures discussed in the previous section.</para>
     38        generic specifications.  The architecture specific part of LSB does
     39        not exist for ARM64.</para>
    4040
    4141        <note><para>Many people do not agree with these requirements.
Note: See TracChangeset for help on using the changeset viewer.