INSTALL revision 1b8adde7ba7d5e04395c141c5400dc2cffd7d809
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonThis is the GRUB. Welcome.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonThis file contains instructions for compiling and installing the GRUB.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonThe Requirements
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington================
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonGRUB depends on some software packages installed into your system. If
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonyou don't have any of them, please obtain and install them before
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonconfiguring the GRUB.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Probably every recent GCC should work, but we recommend GCC 2.95 and
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington later, since you can create smaller binary images. See the web page
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington For now, the Makefiles produced by Automake depends on GNU Make. See
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington the web page <http://www.gnu.org/software/make/make.html>.
6ec499054450c5e0fd69d78961deef46985ba363Brian Wellington* GNU binutils 2.9.1.0.23 or later
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Binutils has changed the behavior of 16bit assembler between 2.9.1
6ec499054450c5e0fd69d78961deef46985ba363Brian Wellington and 2.9.1.0.x, and we support only 2.9.1.0.x and higher. In
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington particular, we recommend using binutils 2.10, since it is the only
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington public release that supports real 16bit mode. Please take a look at
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington the web page <http://sourceware.cygnus.com/binutils/>, for more
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington information. Note that you don't have to install it into any system
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington directory. See the section "Operation Controls", if you want to
6ec499054450c5e0fd69d78961deef46985ba363Brian Wellington install binutils into your own directory.
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian WellingtonIf you'd like to develop GRUB, these below are also required. Don't
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellingtonforget to specify the option `--enable-maintainer-mode' when running the
6ec499054450c5e0fd69d78961deef46985ba363Brian Wellingtonconfigure script.
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington* Texinfo 4.0 or later
6ec499054450c5e0fd69d78961deef46985ba363Brian Wellington We use some new macros in the documents, so you need a recent
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Texinfo release. See the web page
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington <http://www.gnu.org/software/texinfo/texinfo.html>.
6ec499054450c5e0fd69d78961deef46985ba363Brian Wellington* Developers: GNU Autoconf 2.5x and GNU Automake 1.7 or later
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington You should not need Automake just to compile GRUB, but you will need
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington it if you edit any of the build files (Makefile.am, configure.in,
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington etc). We use the new "per-executable flags" feature found in the
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington latest release of automake. See the web page
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington <http://www.gnu.org/software/automake/automake.html>.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonConfiguring the GRUB
90c099e88e9f16bfee9edee3ac1a51fc98843772Brian Wellington====================
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian WellingtonThe `configure' shell script attempts to guess correct values for
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonvarious system-dependent variables used during compilation. It uses
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonthose values to create a `Makefile' in each directory of the package.
90c099e88e9f16bfee9edee3ac1a51fc98843772Brian WellingtonIt may also create one or more `.h' files containing system-dependent
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellingtondefinitions. Finally, it creates a shell script `config.status' that
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonyou can run in the future to recreate the current configuration, a
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonfile `config.cache' that saves the results of its tests to speed up
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonreconfiguring, and a file `config.log' containing compiler output
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington(useful mainly for debugging `configure').
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonIf you need to do unusual things to compile the package, please try to
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonfigure out how `configure' could check whether to do them, and mail
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtondiffs or instructions to the address given in the `README' so they can
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonbe considered for the next release. If at some point `config.cache'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtoncontains results you don't want to keep, you may remove or edit it.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonThe file `configure.in' is used to create `configure' by a program
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtoncalled `autoconf'. You only need `configure.in' if you want to change
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonit or regenerate `configure' using a newer version of `autoconf'.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonBuilding the GRUB
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington=================
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonThe simplest way to compile this package is:
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington 1. `cd' to the directory containing the package's source code and
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington type `./configure' to configure the package for your system. If
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington you're using `csh' on an old version of System V, you might need
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington to type `sh ./configure' instead to prevent `csh' from trying to
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington execute `configure' itself.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Running `configure' takes awhile. While running, it prints some
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington messages telling which features it is checking for.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington 2. Type `make' to compile the package.
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington 3. Optionally, type `make check' to run any self-tests that come with
622df0afb82c1b711b5f3c272db4c4b83d09bc4aBob Halley the package.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington 4. Type `make install' to install the programs and any data files and
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington documentation.
622df0afb82c1b711b5f3c272db4c4b83d09bc4aBob Halley 5. You can remove the program binaries and object files from the
622df0afb82c1b711b5f3c272db4c4b83d09bc4aBob Halley source code directory by typing `make clean'. To also remove the
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington files that `configure' created (so you can compile the package for
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington a different kind of computer), type `make distclean'. There is
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington also a `make maintainer-clean' target, but that is intended mainly
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington for the package's developers. If you use it, you may have to get
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington all sorts of other programs in order to regenerate files that came
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington with the distribution.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonCompiling For Multiple Architectures
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington====================================
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonYou can compile the package for more than one kind of computer at the
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonsame time, by placing the object files for each architecture in their
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonown directory. `cd' to the directory where you want the object files
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonand executables to go and run the `configure' script. `configure'
6ec499054450c5e0fd69d78961deef46985ba363Brian Wellingtonautomatically checks for the source code in the directory that
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`configure' is in and in `..'.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonInstallation Names
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington==================
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonBy default, `make install' will install the package's files in
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`/usr/local/bin', `/usr/local/man', etc. You can specify an
6ec499054450c5e0fd69d78961deef46985ba363Brian Wellingtoninstallation prefix by giving `configure' the option `--prefix=PATH'.
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian WellingtonYou can specify separate installation prefixes for
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellingtonarchitecture-specific files and architecture-independent files. If
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellingtonyou give `configure' the option `--exec-prefix=PATH', the package will
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonuse PATH as the prefix for installing programs and libraries.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonDocumentation and other data files will still use the regular prefix.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonIn addition, if you use an unusual directory layout you can give
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonoptions like `--bindir=PATH' to specify different values for
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonparticular kinds of files. Run `configure --help' for a list of the
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtondirectories you can set and what kinds of files go in them.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonIf the package supports it, you can cause programs to be installed
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellingtonwith an extra prefix or suffix on their names by giving `configure'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonthe option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonPlease note, however, that the GRUB knows where it is located in the
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonfilesystem. If you have installed it in an unusual location, the
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonsystem might not work properly, or at all. The chief utility of these
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonoptions for the GRUB is to allow you to "install" in some alternate
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonlocation, and then copy these to the actual root filesystem later.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonSharing Defaults
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington================
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonIf you want to set default values for `configure' scripts to share,
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonyou can create a site shell script called `config.site' that gives
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtondefault values for variables like `CC', `cache_file', and `prefix'.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`configure' looks for `PREFIX/share/config.site' if it exists, then
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`PREFIX/etc/config.site' if it exists. Or, you can set the
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`CONFIG_SITE' environment variable to the location of the site script.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonA warning: not all `configure' scripts look for a site script.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonOperation Controls
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington==================
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington `configure' recognizes the following options to control how it
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--cache-file=FILE'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Use and save the results of the tests in FILE instead of
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington `./config.cache'. Set FILE to `/dev/null' to disable caching, for
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington debugging `configure'.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Print a summary of the options to `configure', and exit.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Do not print messages saying which checks are being made.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--srcdir=DIR'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Look for the package's source code in directory DIR. Usually
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington `configure' can determine that directory automatically.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Print the version of Autoconf used to generate the `configure'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington script, and exit.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--enable-maintainer-mode'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Enable make rules and dependencies not useful (and sometimes
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington confusing) to the casual installer. If you are a GRUB developer,
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington it is a good idea to specify this option.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--disable-ext2fs'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Omit the ext2fs support in Stage 2.
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington`--disable-fat'
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington Omit the FAT support in Stage 2.
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington`--disable-ffs'
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington Omit the FFS support in Stage 2.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--disable-minix'
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington Omit the Minix fs support in Stage 2.
d4ef65050feac78554addf6e16a06c6e2e0bd331Brian Wellington`--disable-reiserfs'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Omit the ReiserFS support in Stage 2.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--disable-vstafs'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Omit the VSTa filesystem support in Stage 2.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--disable-jfs'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Omit the JFS support in Stage 2.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--disable-xfs'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Omit the XFS support in Stage 2.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--disable-ufs2'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Omit the UFS2 support in Stage 2.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--disable-iso9660'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Omit the ISO9660 support in Stage 2.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--disable-gunzip'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Omit the decompression support in Stage 2.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--disable-md5-password'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Omit the MD5 password support in Stage2.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--with-binutils=PATH'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Search the path PATH to find binutils. If you have installed your
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington binutils executables into an unusual location where GCC doesn't
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington search by default, use this option.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--without-curses'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Don't use the curses library.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--disable-hercules'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Omit the hercules console support in Stage 2.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--disable-serial'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Omit the serial terminal support in Stage 2.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--enable-serial-speed-simulation'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Simulate the slowness of a serial device in the grub shell. This
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington option is useful for GRUB developers, as you can test the
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington performance of a terminal emulation even on pseudo terminals.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--enable-preset-menu=FILE'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Preset a menu file FILE in Stage 2. This is useful, if you cannot
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington put a configuration file on a filesystem for some reason (e.g. when
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington you need to set the default terminal to a serial terminal in an
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington embedded system).
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--enable-example-kernel'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Build the example Multiboot kernel in the directory "docs". You
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington will be able to boot the image "kernel" with GRUB.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`--disable-auto-linux-mem-opt'
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington Don't pass the "mem=" option automatically, when booting Linux.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington You can also disable the feature at run time.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington`configure' also accepts several options for the network support. See
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonthe file `netboot/README.netboot', for more information.