⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 grub-build.html

📁 CLFS(Cross-Compiled Linux From Scratch)的文档 Version CLFS-SVN-20060417
💻 HTML
字号:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml">  <head>    <meta http-equiv="Content-Type" content=    "application/xhtml+xml; charset=iso-8859-1" />    <title>      7.12.&nbsp;GRUB-0.97    </title>    <link rel="stylesheet" href="../stylesheets/lfs.css" type="text/css" />    <meta name="generator" content="DocBook XSL Stylesheets V1.69.1" />    <link rel="stylesheet" href="../stylesheets/lfs-print.css" type=    "text/css" media="print" />  </head>  <body id="lfs" class="CLFS-SVN-20060417-x86">    <div class="navheader">      <div class="headertitles">        <h4>          Cross-Compiled Linux From Scratch - Version CLFS-SVN-20060417-x86        </h4>        <h3>          Chapter&nbsp;7.&nbsp;If You Are Going to Boot        </h3>      </div>      <ul class="headerlinks">        <li class="prev">          <a accesskey="p" href="kernel.html" title="Linux-2.6.16.5">Prev</a>          <p>            Linux-2.6.16.5          </p>        </li>        <li class="next">          <a accesskey="n" href="settingenvironment.html" title=          "Setting Up the Environment">Next</a>          <p>            Setting Up the Environment          </p>        </li>        <li class="up">          <a accesskey="u" href="chapter.html" title=          "Chapter&nbsp;7.&nbsp;If You Are Going to Boot">Up</a>.        </li>        <li class="home">          <a accesskey="h" href="../index.html" title=          "Cross-Compiled Linux From Scratch - Version CLFS-SVN-20060417-x86">          Home</a>        </li>      </ul>    </div>    <div class="wrap" lang="en" xml:lang="en">      <div class="titlepage">        <h1 class="sect1">          7.12. GRUB-0.97        </h1>      </div>      <div class="package" lang="en" xml:lang="en">        <p>          The GRUB package contains the GRand Unified Bootloader.        </p>        <div class="segmentedlist">          <div class="seglistitem">            <div class="seg">              <strong><span class="segtitle">Installation depends              on:</span></strong> <span class="seg">Autoconf, Bash, Binutils,              Coreutils, Diffutils, GCC, Glibc, Grep, Make, Ncurses, and              Sed</span>            </div>          </div>        </div>      </div>      <div class="installation" lang="en" xml:lang="en">        <div class="titlepage">          <h2 class="sect2">            7.12.1. Installation of GRUB          </h2>        </div>        <p>          This package is known to have issues when its default optimization          flags (including the <tt class="option">-march</tt> and <tt class=          "option">-mcpu</tt> options) are changed. If any environment          variables that override default optimizations have been defined,          such as <tt class="envar">CFLAGS</tt> and <tt class=          "envar">CXXFLAGS</tt>, unset them when building GRUB.        </p>        <p>          Prepare GRUB for compilation:        </p>        <pre class="userinput"><kbd class="command">./configure --prefix=/usr \   --host=${LFS_TARGET}</kbd></pre>        <p>          Compile the package:        </p>        <pre class="userinput"><kbd class="command">make</kbd></pre>        <p>          Install the package:        </p>        <pre class="userinput"><kbd class="command">make DESTDIR=${LFS} installmkdir ${LFS}/boot/grubcp ${LFS}/usr/lib/grub/i386-pc/stage{1,2} ${LFS}/boot/grub</kbd></pre>        <p>          The <tt class="filename">i386-pc</tt> directory contains a number          of <tt class="filename">*stage1_5</tt> files, different ones for          different file systems. Review the files available and copy the          appropriate ones to the <tt class="filename">${LFS}/boot/grub</tt>          directory. Most users will copy the <tt class=          "filename">e2fs_stage1_5</tt> and/or <tt class=          "filename">reiserfs_stage1_5</tt> files.        </p>      </div>      <div class="content" lang="en" xml:lang="en">        <p>          Details on this package are located in <a href=          "../final-system/grub.html#contents-grub" title=          "10.54.2.&nbsp;Contents of GRUB">Section&nbsp;10.54.2,          &ldquo;Contents of GRUB.&rdquo;</a>        </p>      </div>    </div>    <div class="navfooter">      <ul>        <li class="prev">          <a accesskey="p" href="kernel.html" title="Linux-2.6.16.5">Prev</a>          <p>            Linux-2.6.16.5          </p>        </li>        <li class="next">          <a accesskey="n" href="settingenvironment.html" title=          "Setting Up the Environment">Next</a>          <p>            Setting Up the Environment          </p>        </li>        <li class="up">          <a accesskey="u" href="chapter.html" title=          "Chapter&nbsp;7.&nbsp;If You Are Going to Boot">Up</a>.        </li>        <li class="home">          <a accesskey="h" href="../index.html" title=          "Cross-Compiled Linux From Scratch - Version CLFS-SVN-20060417-x86">          Home</a>.        </li>      </ul>    </div>  </body></html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -