summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDonny Davies <woodchip@gentoo.org>2003-01-25 02:02:09 +0000
committerDonny Davies <woodchip@gentoo.org>2003-01-25 02:02:09 +0000
commitfbc421c71532645e69453be391d09a952ede2214 (patch)
tree12715665940c9977b5232068493149e29cc53e64 /sys-apps/grub
parentmove mount /boot to pkg_preinst (diff)
downloadgentoo-2-fbc421c71532645e69453be391d09a952ede2214.tar.gz
gentoo-2-fbc421c71532645e69453be391d09a952ede2214.tar.bz2
gentoo-2-fbc421c71532645e69453be391d09a952ede2214.zip
cleanup
Diffstat (limited to 'sys-apps/grub')
-rw-r--r--sys-apps/grub/files/grub-0.90/configure3608
-rw-r--r--sys-apps/grub/files/grub-0.90/grub-0.5.96.1-dont-give-mem-to-kernel.patch30
-rw-r--r--sys-apps/grub/files/grub-0.90/grub-0.5.96.1-special-raid-devices.patch17
-rw-r--r--sys-apps/grub/files/grub-0.90/grub-0.5.97-vga16.patch2066
-rw-r--r--sys-apps/grub/files/grub-0.90/grub-0.90-install.in.patch34
-rw-r--r--sys-apps/grub/files/grub-0.90/grub-0.90-installcopyonly.patch85
-rw-r--r--sys-apps/grub/files/grub-0.90/grub-0.90-passwordprompt.patch146
-rw-r--r--sys-apps/grub/files/grub-0.90/grub-0.90-vga16-keypressclear.patch36
-rw-r--r--sys-apps/grub/files/grub-0.90/grub-jfs+xfs-1.0-build.patch1454
-rw-r--r--sys-apps/grub/files/grub-0.90/grub-jfs+xfs-1.0-core.patch2430
-rw-r--r--sys-apps/grub/files/grub-0.91/grub-0.5.96.1-dont-give-mem-to-kernel.patch30
-rw-r--r--sys-apps/grub/files/grub-0.91/grub-0.5.96.1-special-raid-devices.patch17
-rw-r--r--sys-apps/grub/files/grub-0.91/grub-0.90-addsyncs.patch57
-rw-r--r--sys-apps/grub/files/grub-0.91/grub-0.90-append.patch111
-rw-r--r--sys-apps/grub/files/grub-0.91/grub-0.90-install.in.patch34
-rw-r--r--sys-apps/grub/files/grub-0.91/grub-0.90-installcopyonly.patch85
-rw-r--r--sys-apps/grub/files/grub-0.91/grub-0.90-passwordprompt.patch146
-rw-r--r--sys-apps/grub/files/grub-0.91/grub-0.90-symlinkmenulst.patch16
-rw-r--r--sys-apps/grub/files/grub-0.91/grub-0.90-vga16-keypressclear.patch36
-rw-r--r--sys-apps/grub/files/grub-0.91/grub-0.91-initrdusemem.patch107
-rw-r--r--sys-apps/grub/files/grub-0.91/grub-0.91-splashimagehelp.patch28
-rw-r--r--sys-apps/grub/files/grub-0.91/grub-0.91-vga16.patch2057
22 files changed, 0 insertions, 12630 deletions
diff --git a/sys-apps/grub/files/grub-0.90/configure b/sys-apps/grub/files/grub-0.90/configure
deleted file mode 100644
index d6b3c9391ab4..000000000000
--- a/sys-apps/grub/files/grub-0.90/configure
+++ /dev/null
@@ -1,3608 +0,0 @@
-#! /bin/sh
-
-# Guess values for system-dependent variables and create Makefiles.
-# Generated automatically using autoconf version 2.13
-# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
-#
-# This configure script is free software; the Free Software Foundation
-# gives unlimited permission to copy, distribute and modify it.
-
-# Defaults:
-ac_help=
-ac_default_prefix=/usr/local
-# Any additions from configure.in:
-ac_help="$ac_help
- --disable-dependency-tracking Speeds up one-time builds
- --enable-dependency-tracking Do not reject slow dependency extractors"
-ac_help="$ac_help
- --enable-maintainer-mode enable make rules and dependencies not useful
- (and sometimes confusing) to the casual installer"
-ac_help="$ac_help
- --with-binutils=DIR search the directory DIR to find binutils"
-ac_help="$ac_help
- --without-curses do not use curses"
-ac_help="$ac_help
- --disable-ext2fs disable ext2fs support in Stage 2"
-ac_help="$ac_help
- --disable-fat disable FAT support in Stage 2"
-ac_help="$ac_help
- --disable-ffs disable FFS support in Stage 2"
-ac_help="$ac_help
- --disable-minix disable Minix fs support in Stage 2"
-ac_help="$ac_help
- --disable-reiserfs disable ReiserFS support in Stage 2"
-ac_help="$ac_help
- --disable-jfs disable IBM JFS support in Stage 2"
-ac_help="$ac_help
- --disable-xfs disable SGI XFS support in Stage 2"
-ac_help="$ac_help
- --disable-vstafs disable VSTa FS support in Stage 2"
-ac_help="$ac_help
- --disable-gunzip disable decompression in Stage 2"
-ac_help="$ac_help
- --disable-md5-password disable MD5 password support in Stage 2"
-ac_help="$ac_help
- --disable-packet-retransmission
- turn off packet retransmission"
-ac_help="$ac_help
- --enable-pci-direct access PCI directly instead of using BIOS"
-ac_help="$ac_help
- --enable-3c509 enable 3Com509 driver"
-ac_help="$ac_help
- --enable-3c529 enable 3Com529 driver"
-ac_help="$ac_help
- --enable-3c590 enable 3Com590 driver"
-ac_help="$ac_help
- --enable-3c595 enable 3Com595 driver"
-ac_help="$ac_help
- --enable-3c90x enable 3Com90x driver"
-ac_help="$ac_help
- --enable-cs89x0 enable CS89x0 driver"
-ac_help="$ac_help
- --enable-depca enable DEPCA and EtherWORKS driver"
-ac_help="$ac_help
- --enable-eepro100 enable Etherexpress Pro/100 driver"
-ac_help="$ac_help
- --enable-epic100 enable SMC 83c170 EPIC/100 driver"
-ac_help="$ac_help
- --enable-3c507 enable 3Com507 driver"
-ac_help="$ac_help
- --enable-exos205 enable EXOS205 driver"
-ac_help="$ac_help
- --enable-ni5210 enable Racal-Interlan NI5210 driver"
-ac_help="$ac_help
- --enable-lance enable Lance PCI PCNet/32 driver"
-ac_help="$ac_help
- --enable-ne2100 enable Novell NE2100 driver"
-ac_help="$ac_help
- --enable-ni6510 enable Racal-Interlan NI6510 driver"
-ac_help="$ac_help
- --enable-3c503 enable 3Com503 driver"
-ac_help="$ac_help
- --enable-ne enable NE1000/2000 ISA driver"
-ac_help="$ac_help
- --enable-ns8390 enable NE2000 PCI driver"
-ac_help="$ac_help
- --enable-wd enable WD8003/8013, SMC8216/8416 driver"
-ac_help="$ac_help
- --enable-otulip enable old Tulip driver"
-ac_help="$ac_help
- --enable-rtl8139 enable Realtek 8139 driver"
-ac_help="$ac_help
- --enable-sk-g16 enable Schneider and Koch G16 driver"
-ac_help="$ac_help
- --enable-smc9000 enable SMC9000 driver"
-ac_help="$ac_help
- --enable-tiara enable Tiara driver"
-ac_help="$ac_help
- --enable-tulip enable Tulip driver"
-ac_help="$ac_help
- --enable-via-rhine enable Rhine-I/II driver"
-ac_help="$ac_help
- --enable-3c503-shmem use 3c503 shared memory mode"
-ac_help="$ac_help
- --enable-3c503-aui use AUI by default on 3c503 cards"
-ac_help="$ac_help
- --enable-3c509-hack make a 3c509 do bootp quicker"
-ac_help="$ac_help
- --enable-compex-rl2000-fix
- specify this if you have a Compex RL2000 PCI"
-ac_help="$ac_help
- --enable-ns8390-force-16bit
- specify this if falsely 8 bit is detected"
-ac_help="$ac_help
- --enable-smc9000-scan=LIST
- probe for SMC9000 I/O addresses using LIST"
-ac_help="$ac_help
- --enable-ne-scan=LIST probe for NE base address using LIST"
-ac_help="$ac_help
- --enable-wd-default-mem=MEM
- set the default memory location for WD/SMC"
-ac_help="$ac_help
- --enable-cs-scan=LIST probe for CS89x0 base address using LIST"
-ac_help="$ac_help
- --enable-diskless enable diskless support"
-ac_help="$ac_help
- --disable-hercules disable hercules terminal support"
-ac_help="$ac_help
- --disable-serial diable serial terminal support"
-ac_help="$ac_help
- --enable-serial-speed-simulation
- simulate the slowness of a serial device"
-ac_help="$ac_help
- --enable-preset-menu=FILE
- preset a menu file FILE in Stage 2"
-ac_help="$ac_help
- --enable-example-kernel
- build the example Multiboot kernel"
-ac_help="$ac_help
- --disable-auto-linux-mem-opt
- don't pass Linux mem= option automatically"
-ac_help="$ac_help
- --disable-vga16 disable VGA graphics interface"
-
-# Initialize some variables set by options.
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-build=NONE
-cache_file=./config.cache
-exec_prefix=NONE
-host=NONE
-no_create=
-nonopt=NONE
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-srcdir=
-target=NONE
-verbose=
-x_includes=NONE
-x_libraries=NONE
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datadir='${prefix}/share'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-libdir='${exec_prefix}/lib'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-infodir='${prefix}/info'
-mandir='${prefix}/man'
-
-# Initialize some other variables.
-subdirs=
-MFLAGS= MAKEFLAGS=
-SHELL=${CONFIG_SHELL-/bin/sh}
-# Maximum number of lines to put in a shell here document.
-ac_max_here_lines=12
-
-ac_prev=
-for ac_option
-do
-
- # If the previous option needs an argument, assign it.
- if test -n "$ac_prev"; then
- eval "$ac_prev=\$ac_option"
- ac_prev=
- continue
- fi
-
- case "$ac_option" in
- -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
- *) ac_optarg= ;;
- esac
-
- # Accept the important Cygnus configure options, so we can diagnose typos.
-
- case "$ac_option" in
-
- -bindir | --bindir | --bindi | --bind | --bin | --bi)
- ac_prev=bindir ;;
- -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
- bindir="$ac_optarg" ;;
-
- -build | --build | --buil | --bui | --bu)
- ac_prev=build ;;
- -build=* | --build=* | --buil=* | --bui=* | --bu=*)
- build="$ac_optarg" ;;
-
- -cache-file | --cache-file | --cache-fil | --cache-fi \
- | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
- ac_prev=cache_file ;;
- -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
- | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
- cache_file="$ac_optarg" ;;
-
- -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
- ac_prev=datadir ;;
- -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
- | --da=*)
- datadir="$ac_optarg" ;;
-
- -disable-* | --disable-*)
- ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
- # Reject names that are not valid shell variable names.
- if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
- { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
- fi
- ac_feature=`echo $ac_feature| sed 's/-/_/g'`
- eval "enable_${ac_feature}=no" ;;
-
- -enable-* | --enable-*)
- ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
- # Reject names that are not valid shell variable names.
- if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
- { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
- fi
- ac_feature=`echo $ac_feature| sed 's/-/_/g'`
- case "$ac_option" in
- *=*) ;;
- *) ac_optarg=yes ;;
- esac
- eval "enable_${ac_feature}='$ac_optarg'" ;;
-
- -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
- | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
- | --exec | --exe | --ex)
- ac_prev=exec_prefix ;;
- -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
- | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
- | --exec=* | --exe=* | --ex=*)
- exec_prefix="$ac_optarg" ;;
-
- -gas | --gas | --ga | --g)
- # Obsolete; use --with-gas.
- with_gas=yes ;;
-
- -help | --help | --hel | --he)
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat << EOF
-Usage: configure [options] [host]
-Options: [defaults in brackets after descriptions]
-Configuration:
- --cache-file=FILE cache test results in FILE
- --help print this message
- --no-create do not create output files
- --quiet, --silent do not print \`checking...' messages
- --version print the version of autoconf that created configure
-Directory and file names:
- --prefix=PREFIX install architecture-independent files in PREFIX
- [$ac_default_prefix]
- --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
- [same as prefix]
- --bindir=DIR user executables in DIR [EPREFIX/bin]
- --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
- --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
- --datadir=DIR read-only architecture-independent data in DIR
- [PREFIX/share]
- --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
- --sharedstatedir=DIR modifiable architecture-independent data in DIR
- [PREFIX/com]
- --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
- --libdir=DIR object code libraries in DIR [EPREFIX/lib]
- --includedir=DIR C header files in DIR [PREFIX/include]
- --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
- --infodir=DIR info documentation in DIR [PREFIX/info]
- --mandir=DIR man documentation in DIR [PREFIX/man]
- --srcdir=DIR find the sources in DIR [configure dir or ..]
- --program-prefix=PREFIX prepend PREFIX to installed program names
- --program-suffix=SUFFIX append SUFFIX to installed program names
- --program-transform-name=PROGRAM
- run sed PROGRAM on installed program names
-EOF
- cat << EOF
-Host type:
- --build=BUILD configure for building on BUILD [BUILD=HOST]
- --host=HOST configure for HOST [guessed]
- --target=TARGET configure for TARGET [TARGET=HOST]
-Features and packages:
- --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
- --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
- --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
- --x-includes=DIR X include files are in DIR
- --x-libraries=DIR X library files are in DIR
-EOF
- if test -n "$ac_help"; then
- echo "--enable and --with options recognized:$ac_help"
- fi
- exit 0 ;;
-
- -host | --host | --hos | --ho)
- ac_prev=host ;;
- -host=* | --host=* | --hos=* | --ho=*)
- host="$ac_optarg" ;;
-
- -includedir | --includedir | --includedi | --included | --include \
- | --includ | --inclu | --incl | --inc)
- ac_prev=includedir ;;
- -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
- | --includ=* | --inclu=* | --incl=* | --inc=*)
- includedir="$ac_optarg" ;;
-
- -infodir | --infodir | --infodi | --infod | --info | --inf)
- ac_prev=infodir ;;
- -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
- infodir="$ac_optarg" ;;
-
- -libdir | --libdir | --libdi | --libd)
- ac_prev=libdir ;;
- -libdir=* | --libdir=* | --libdi=* | --libd=*)
- libdir="$ac_optarg" ;;
-
- -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
- | --libexe | --libex | --libe)
- ac_prev=libexecdir ;;
- -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
- | --libexe=* | --libex=* | --libe=*)
- libexecdir="$ac_optarg" ;;
-
- -localstatedir | --localstatedir | --localstatedi | --localstated \
- | --localstate | --localstat | --localsta | --localst \
- | --locals | --local | --loca | --loc | --lo)
- ac_prev=localstatedir ;;
- -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
- | --localstate=* | --localstat=* | --localsta=* | --localst=* \
- | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
- localstatedir="$ac_optarg" ;;
-
- -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
- ac_prev=mandir ;;
- -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
- mandir="$ac_optarg" ;;
-
- -nfp | --nfp | --nf)
- # Obsolete; use --without-fp.
- with_fp=no ;;
-
- -no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c)
- no_create=yes ;;
-
- -no-recursion | --no-recursion | --no-recursio | --no-recursi \
- | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
- no_recursion=yes ;;
-
- -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
- | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
- | --oldin | --oldi | --old | --ol | --o)
- ac_prev=oldincludedir ;;
- -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
- | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
- | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
- oldincludedir="$ac_optarg" ;;
-
- -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
- ac_prev=prefix ;;
- -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
- prefix="$ac_optarg" ;;
-
- -program-prefix | --program-prefix | --program-prefi | --program-pref \
- | --program-pre | --program-pr | --program-p)
- ac_prev=program_prefix ;;
- -program-prefix=* | --program-prefix=* | --program-prefi=* \
- | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
- program_prefix="$ac_optarg" ;;
-
- -program-suffix | --program-suffix | --program-suffi | --program-suff \
- | --program-suf | --program-su | --program-s)
- ac_prev=program_suffix ;;
- -program-suffix=* | --program-suffix=* | --program-suffi=* \
- | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
- program_suffix="$ac_optarg" ;;
-
- -program-transform-name | --program-transform-name \
- | --program-transform-nam | --program-transform-na \
- | --program-transform-n | --program-transform- \
- | --program-transform | --program-transfor \
- | --program-transfo | --program-transf \
- | --program-trans | --program-tran \
- | --progr-tra | --program-tr | --program-t)
- ac_prev=program_transform_name ;;
- -program-transform-name=* | --program-transform-name=* \
- | --program-transform-nam=* | --program-transform-na=* \
- | --program-transform-n=* | --program-transform-=* \
- | --program-transform=* | --program-transfor=* \
- | --program-transfo=* | --program-transf=* \
- | --program-trans=* | --program-tran=* \
- | --progr-tra=* | --program-tr=* | --program-t=*)
- program_transform_name="$ac_optarg" ;;
-
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- silent=yes ;;
-
- -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
- ac_prev=sbindir ;;
- -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
- | --sbi=* | --sb=*)
- sbindir="$ac_optarg" ;;
-
- -sharedstatedir | --sharedstatedir | --sharedstatedi \
- | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
- | --sharedst | --shareds | --shared | --share | --shar \
- | --sha | --sh)
- ac_prev=sharedstatedir ;;
- -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
- | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
- | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
- | --sha=* | --sh=*)
- sharedstatedir="$ac_optarg" ;;
-
- -site | --site | --sit)
- ac_prev=site ;;
- -site=* | --site=* | --sit=*)
- site="$ac_optarg" ;;
-
- -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
- ac_prev=srcdir ;;
- -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
- srcdir="$ac_optarg" ;;
-
- -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
- | --syscon | --sysco | --sysc | --sys | --sy)
- ac_prev=sysconfdir ;;
- -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
- | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
- sysconfdir="$ac_optarg" ;;
-
- -target | --target | --targe | --targ | --tar | --ta | --t)
- ac_prev=target ;;
- -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
- target="$ac_optarg" ;;
-
- -v | -verbose | --verbose | --verbos | --verbo | --verb)
- verbose=yes ;;
-
- -version | --version | --versio | --versi | --vers)
- echo "configure generated by autoconf version 2.13"
- exit 0 ;;
-
- -with-* | --with-*)
- ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
- # Reject names that are not valid shell variable names.
- if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
- { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
- fi
- ac_package=`echo $ac_package| sed 's/-/_/g'`
- case "$ac_option" in
- *=*) ;;
- *) ac_optarg=yes ;;
- esac
- eval "with_${ac_package}='$ac_optarg'" ;;
-
- -without-* | --without-*)
- ac_package=`echo $ac_option|sed -e 's/-*without-//'`
- # Reject names that are not valid shell variable names.
- if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
- { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
- fi
- ac_package=`echo $ac_package| sed 's/-/_/g'`
- eval "with_${ac_package}=no" ;;
-
- --x)
- # Obsolete; use --with-x.
- with_x=yes ;;
-
- -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
- | --x-incl | --x-inc | --x-in | --x-i)
- ac_prev=x_includes ;;
- -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
- | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
- x_includes="$ac_optarg" ;;
-
- -x-libraries | --x-libraries | --x-librarie | --x-librari \
- | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
- ac_prev=x_libraries ;;
- -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
- | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
- x_libraries="$ac_optarg" ;;
-
- -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
- ;;
-
- *)
- if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
- echo "configure: warning: $ac_option: invalid host type" 1>&2
- fi
- if test "x$nonopt" != xNONE; then
- { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
- fi
- nonopt="$ac_option"
- ;;
-
- esac
-done
-
-if test -n "$ac_prev"; then
- { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
-fi
-
-trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
-
-# File descriptor usage:
-# 0 standard input
-# 1 file creation
-# 2 errors and warnings
-# 3 some systems may open it to /dev/tty
-# 4 used on the Kubota Titan
-# 6 checking for... messages and results
-# 5 compiler messages saved in config.log
-if test "$silent" = yes; then
- exec 6>/dev/null
-else
- exec 6>&1
-fi
-exec 5>./config.log
-
-echo "\
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-" 1>&5
-
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Also quote any args containing shell metacharacters.
-ac_configure_args=
-for ac_arg
-do
- case "$ac_arg" in
- -no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c) ;;
- -no-recursion | --no-recursion | --no-recursio | --no-recursi \
- | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
- *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
- ac_configure_args="$ac_configure_args '$ac_arg'" ;;
- *) ac_configure_args="$ac_configure_args $ac_arg" ;;
- esac
-done
-
-# NLS nuisances.
-# Only set these to C if already set. These must not be set unconditionally
-# because not all systems understand e.g. LANG=C (notably SCO).
-# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
-# Non-C LC_CTYPE values break the ctype check.
-if test "${LANG+set}" = set; then LANG=C; export LANG; fi
-if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
-if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
-if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -rf conftest* confdefs.h
-# AIX cpp loses on an empty file, so make sure it contains at least a newline.
-echo > confdefs.h
-
-# A filename unique to this package, relative to the directory that
-# configure is in, which we can look for to find out if srcdir is correct.
-ac_unique_file=stage2/stage2.c
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
- ac_srcdir_defaulted=yes
- # Try the directory containing this script, then its parent.
- ac_prog=$0
- ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
- test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
- srcdir=$ac_confdir
- if test ! -r $srcdir/$ac_unique_file; then
- srcdir=..
- fi
-else
- ac_srcdir_defaulted=no
-fi
-if test ! -r $srcdir/$ac_unique_file; then
- if test "$ac_srcdir_defaulted" = yes; then
- { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
- else
- { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
- fi
-fi
-srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
-
-# Prefer explicitly selected file to automatically selected ones.
-if test -z "$CONFIG_SITE"; then
- if test "x$prefix" != xNONE; then
- CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
- else
- CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
- fi
-fi
-for ac_site_file in $CONFIG_SITE; do
- if test -r "$ac_site_file"; then
- echo "loading site script $ac_site_file"
- . "$ac_site_file"
- fi
-done
-
-if test -r "$cache_file"; then
- echo "loading cache $cache_file"
- . $cache_file
-else
- echo "creating cache $cache_file"
- > $cache_file
-fi
-
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-ac_exeext=
-ac_objext=o
-if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
- # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
- if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
- ac_n= ac_c='
-' ac_t=' '
- else
- ac_n=-n ac_c= ac_t=
- fi
-else
- ac_n= ac_c='\c' ac_t=
-fi
-
-
-ac_aux_dir=
-for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
- if test -f $ac_dir/install-sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f $ac_dir/install.sh; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
-fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
-
-# Find a good install program. We prefer a C program (faster),
-# so one script is as good as another. But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# ./install, which can be erroneously created by make from ./install.sh.
-echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:685: checking for a BSD compatible install" >&5
-if test -z "$INSTALL"; then
-if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
- for ac_dir in $PATH; do
- # Account for people who put trailing slashes in PATH elements.
- case "$ac_dir/" in
- /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
- *)
- # OSF1 and SCO ODT 3.0 have their own names for install.
- # Don't use installbsd from OSF since it installs stuff as root
- # by default.
- for ac_prog in ginstall scoinst install; do
- if test -f $ac_dir/$ac_prog; then
- if test $ac_prog = install &&
- grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
- # AIX install. It has an incompatible calling convention.
- :
- else
- ac_cv_path_install="$ac_dir/$ac_prog -c"
- break 2
- fi
- fi
- done
- ;;
- esac
- done
- IFS="$ac_save_IFS"
-
-fi
- if test "${ac_cv_path_install+set}" = set; then
- INSTALL="$ac_cv_path_install"
- else
- # As a last resort, use the slow shell script. We don't cache a
- # path for INSTALL within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the path is relative.
- INSTALL="$ac_install_sh"
- fi
-fi
-echo "$ac_t""$INSTALL" 1>&6
-
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
-
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
-echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:738: checking whether build environment is sane" >&5
-# Just in case
-sleep 1
-echo timestamp > conftest.file
-# Do `set' in a subshell so we don't clobber the current shell's
-# arguments. Must try -L first in case configure is actually a
-# symlink; some systems play weird games with the mod time of symlinks
-# (eg FreeBSD returns the mod time of the symlink's containing
-# directory).
-if (
- set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
- if test "$*" = "X"; then
- # -L didn't work.
- set X `ls -t $srcdir/configure conftest.file`
- fi
- rm -f conftest.file
- if test "$*" != "X $srcdir/configure conftest.file" \
- && test "$*" != "X conftest.file $srcdir/configure"; then
-
- # If neither matched, then we have a broken ls. This can happen
- # if, for instance, CONFIG_SHELL is bash and it inherits a
- # broken ls alias from the environment. This has actually
- # happened. Such a system could not be considered "sane".
- { echo "configure: error: ls -t appears to fail. Make sure there is not a broken
-alias in your environment" 1>&2; exit 1; }
- fi
-
- test "$2" = conftest.file
- )
-then
- # Ok.
- :
-else
- { echo "configure: error: newly created file is older than distributed files!
-Check your system clock" 1>&2; exit 1; }
-fi
-echo "$ac_t""yes" 1>&6
-if test "$program_transform_name" = s,x,x,; then
- program_transform_name=
-else
- # Double any \ or $. echo might interpret backslashes.
- cat <<\EOF_SED > conftestsed
-s,\\,\\\\,g; s,\$,$$,g
-EOF_SED
- program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
- rm -f conftestsed
-fi
-test "$program_prefix" != NONE &&
- program_transform_name="s,^,${program_prefix},; $program_transform_name"
-# Use a double $ so make ignores it.
-test "$program_suffix" != NONE &&
- program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
-
-# sed with no file args requires a program.
-test "$program_transform_name" = "" && program_transform_name="s,x,x,"
-
-test x"${MISSING+set}" = xset ||
- MISSING="\${SHELL} `CDPATH=:; cd $ac_aux_dir && pwd`/missing"
-# Use eval to expand $SHELL
-if eval "$MISSING --run true"; then
- am_missing_run="$MISSING --run "
-else
- am_missing_run=
- am_backtick='`'
- echo "configure: warning: ${am_backtick}missing' script is too old or missing" 1>&2
-fi
-
-for ac_prog in gawk mawk nawk awk
-do
-# Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:810: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$AWK"; then
- ac_cv_prog_AWK="$AWK" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_AWK="$ac_prog"
- break
- fi
- done
- IFS="$ac_save_ifs"
-fi
-fi
-AWK="$ac_cv_prog_AWK"
-if test -n "$AWK"; then
- echo "$ac_t""$AWK" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
-test -n "$AWK" && break
-done
-
-echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:840: checking whether ${MAKE-make} sets \${MAKE}" >&5
-set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftestmake <<\EOF
-all:
- @echo 'ac_maketemp="${MAKE}"'
-EOF
-# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
-eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
-if test -n "$ac_maketemp"; then
- eval ac_cv_prog_make_${ac_make}_set=yes
-else
- eval ac_cv_prog_make_${ac_make}_set=no
-fi
-rm -f conftestmake
-fi
-if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- SET_MAKE=
-else
- echo "$ac_t""no" 1>&6
- SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-# Check whether --enable-dependency-tracking or --disable-dependency-tracking was given.
-if test "${enable_dependency_tracking+set}" = set; then
- enableval="$enable_dependency_tracking"
- :
-fi
-
-if test "x$enable_dependency_tracking" != xno; then
- am_depcomp="$ac_aux_dir/depcomp"
- AMDEPBACKSLASH='\'
-fi
-
-
-if test "x$enable_dependency_tracking" != xno; then
- AMDEP_TRUE=
- AMDEP_FALSE='#'
-else
- AMDEP_TRUE='#'
- AMDEP_FALSE=
-fi
-
-
-
-
-if test -d .deps || mkdir .deps 2> /dev/null || test -d .deps; then
- DEPDIR=.deps
- # We redirect because .deps might already exist and be populated.
- # In this situation we don't want to see an error.
- rmdir .deps > /dev/null 2>&1
-else
- DEPDIR=_deps
-fi
-
-
-# test to see if srcdir already configured
-if test "`CDPATH=:; cd $srcdir && pwd`" != "`pwd`" &&
- test -f $srcdir/config.status; then
- { echo "configure: error: source directory already configured; run \"make distclean\" there first" 1>&2; exit 1; }
-fi
-
-# Define the identity of the package.
-PACKAGE=grub
-VERSION=0.90
-cat >> confdefs.h <<EOF
-#define PACKAGE "$PACKAGE"
-EOF
-
-cat >> confdefs.h <<EOF
-#define VERSION "$VERSION"
-EOF
-
-
-# Autoconf 2.50 wants to disallow AM_ names. We explicitly allow
-# the ones we care about.
-
-# Some tools Automake needs.
-
-ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal"}
-
-
-AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
-
-
-AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake"}
-
-
-AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
-
-
-MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
-
-
-AMTAR=${AMTAR-"${am_missing_run}tar"}
-
-
-if test -z "$install_sh"; then
- for install_sh in "$ac_aux_dir/install-sh" \
- "$ac_aux_dir/install.sh" \
- "${am_missing_run}${ac_auxdir}/install-sh";
- do
- test -f "$install_sh" && break
- done
- # FIXME: an evil hack: we remove the SHELL invocation from
- # install_sh because automake adds it back in. Sigh.
- install_sh=`echo $install_sh | sed -e 's/\${SHELL}//'`
-fi
-
-_am_dirpart="`echo $install_sh | sed -e 's,//*[^/]*$,,'`"
-INSTALL_STRIP_PROGRAM="\${SHELL} \`CDPATH=: && cd $_am_dirpart && pwd\`/install-sh -c -s"
-
-# We need awk for the "check" target. The system "awk" is bad on
-# some platforms.
-
-
-
-
-
-
-
-# Make sure we can run config.sub.
-if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
-else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
-fi
-
-echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:970: checking host system type" >&5
-
-host_alias=$host
-case "$host_alias" in
-NONE)
- case $nonopt in
- NONE)
- if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
- else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
- fi ;;
- *) host_alias=$nonopt ;;
- esac ;;
-esac
-
-host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
-host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$host" 1>&6
-
-AM_PROG_LIBTOOL
-
-case "$host_cpu" in
-i[3456]86) host_cpu=i386 ;;
-*) { echo "configure: error: unsupported CPU type" 1>&2; exit 1; } ;;
-esac
-
-
-
-
-#
-# Options
-#
-
-echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:1005: checking whether to enable maintainer-specific portions of Makefiles" >&5
- # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
-if test "${enable_maintainer_mode+set}" = set; then
- enableval="$enable_maintainer_mode"
- USE_MAINTAINER_MODE=$enableval
-else
- USE_MAINTAINER_MODE=no
-fi
-
- echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
-
-
-if test $USE_MAINTAINER_MODE = yes; then
- MAINTAINER_MODE_TRUE=
- MAINTAINER_MODE_FALSE='#'
-else
- MAINTAINER_MODE_TRUE='#'
- MAINTAINER_MODE_FALSE=
-fi
- MAINT=$MAINTAINER_MODE_TRUE
-
-
-if test "x$enable_maintainer_mode" = xyes; then
- # Extract the first word of "perl", so it can be a program name with args.
-set dummy perl; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1031: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_path_PERL'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- case "$PERL" in
- /*)
- ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
- ;;
- ?:/*)
- ac_cv_path_PERL="$PERL" # Let the user override the test with a dos path.
- ;;
- *)
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_path_PERL="$ac_dir/$ac_word"
- break
- fi
- done
- IFS="$ac_save_ifs"
- ;;
-esac
-fi
-PERL="$ac_cv_path_PERL"
-if test -n "$PERL"; then
- echo "$ac_t""$PERL" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
- if test -z "$PERL"; then
- { echo "configure: error: perl not found" 1>&2; exit 1; }
- fi
-fi
-
-# This should be checked before AC_PROG_CC
-if test "x$CFLAGS" = x; then
- default_CFLAGS=yes
-fi
-
-#
-# Programs
-#
-
-echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:1078: checking build system type" >&5
-
-build_alias=$build
-case "$build_alias" in
-NONE)
- case $nonopt in
- NONE) build_alias=$host_alias ;;
- *) build_alias=$nonopt ;;
- esac ;;
-esac
-
-build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
-build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$build" 1>&6
-
-if test $host != $build; then
- ac_tool_prefix=${host_alias}-
-else
- ac_tool_prefix=
-fi
-
-# Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gcc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1104: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_CC="${ac_tool_prefix}gcc"
- break
- fi
- done
- IFS="$ac_save_ifs"
- test -z "$ac_cv_prog_CC" && ac_cv_prog_CC="gcc"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
-
-
-# Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1136: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_CC="gcc"
- break
- fi
- done
- IFS="$ac_save_ifs"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
-if test -z "$CC"; then
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1166: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_prog_rejected=no
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- break
- fi
- done
- IFS="$ac_save_ifs"
-if test $ac_prog_rejected = yes; then
- # We found a bogon in the path, so make sure we never use it.
- set dummy $ac_cv_prog_CC
- shift
- if test $# -gt 0; then
- # We chose a different compiler from the bogus one.
- # However, it has the same basename, so the bogon will be chosen
- # first if we set CC to just the basename; use the full file name.
- shift
- set dummy "$ac_dir/$ac_word" "$@"
- shift
- ac_cv_prog_CC="$@"
- fi
-fi
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
- if test -z "$CC"; then
- case "`uname -s`" in
- *win32* | *WIN32*)
- # Extract the first word of "cl", so it can be a program name with args.
-set dummy cl; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1217: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_CC="cl"
- break
- fi
- done
- IFS="$ac_save_ifs"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
- ;;
- esac
- fi
- test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
-fi
-
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1249: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
-
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-cat > conftest.$ac_ext << EOF
-
-#line 1260 "configure"
-#include "confdefs.h"
-
-main(){return(0);}
-EOF
-if { (eval echo configure:1265: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- ac_cv_prog_cc_works=yes
- # If we can't run a trivial program, we are probably using a cross compiler.
- if (./conftest; exit) 2>/dev/null; then
- ac_cv_prog_cc_cross=no
- else
- ac_cv_prog_cc_cross=yes
- fi
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- ac_cv_prog_cc_works=no
-fi
-rm -fr conftest*
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
-if test $ac_cv_prog_cc_works = no; then
- { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
-fi
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1291: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
-echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
-cross_compiling=$ac_cv_prog_cc_cross
-
-echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1296: checking whether we are using GNU C" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.c <<EOF
-#ifdef __GNUC__
- yes;
-#endif
-EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1305: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
- ac_cv_prog_gcc=yes
-else
- ac_cv_prog_gcc=no
-fi
-fi
-
-echo "$ac_t""$ac_cv_prog_gcc" 1>&6
-
-if test $ac_cv_prog_gcc = yes; then
- GCC=yes
-else
- GCC=
-fi
-
-ac_test_CFLAGS="${CFLAGS+set}"
-ac_save_CFLAGS="$CFLAGS"
-CFLAGS=
-echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1324: checking whether ${CC-cc} accepts -g" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- echo 'void f(){}' > conftest.c
-if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
- ac_cv_prog_cc_g=yes
-else
- ac_cv_prog_cc_g=no
-fi
-rm -f conftest*
-
-fi
-
-echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
-if test "$ac_test_CFLAGS" = set; then
- CFLAGS="$ac_save_CFLAGS"
-elif test $ac_cv_prog_cc_g = yes; then
- if test "$GCC" = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-g"
- fi
-else
- if test "$GCC" = yes; then
- CFLAGS="-O2"
- else
- CFLAGS=
- fi
-fi
-
-
-echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:1357: checking how to run the C preprocessor" >&5
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
- CPP=
-fi
-if test -z "$CPP"; then
-if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- # This must be in double quotes, not single quotes, because CPP may get
- # substituted into the Makefile and "${CC-cc}" will confuse make.
- CPP="${CC-cc} -E"
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp.
- cat > conftest.$ac_ext <<EOF
-#line 1372 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1378: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- :
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- CPP="${CC-cc} -E -traditional-cpp"
- cat > conftest.$ac_ext <<EOF
-#line 1389 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1395: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- :
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- CPP="${CC-cc} -nologo -E"
- cat > conftest.$ac_ext <<EOF
-#line 1406 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1412: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- :
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- CPP=/lib/cpp
-fi
-rm -f conftest*
-fi
-rm -f conftest*
-fi
-rm -f conftest*
- ac_cv_prog_CPP="$CPP"
-fi
- CPP="$ac_cv_prog_CPP"
-else
- ac_cv_prog_CPP="$CPP"
-fi
-echo "$ac_t""$CPP" 1>&6
-
-am_make=${MAKE-make}
-cat > confinc << 'END'
-doit:
- @echo done
-END
-# If we don't find an include directive, just comment out the code.
-echo $ac_n "checking for style of include used by $am_make""... $ac_c" 1>&6
-echo "configure:1443: checking for style of include used by $am_make" >&5
-_am_include='#'
-_am_quote=
-_am_result=none
-# First try GNU make style include.
-echo "include confinc" > confmf
-# We grep out `Entering directory' and `Leaving directory'
-# messages which can occur if `w' ends up in MAKEFLAGS.
-# In particular we don't look at `^make:' because GNU make might
-# be invoked under some other name (usually "gmake"), in which
-# case it prints its new name instead of `make'.
-if test "`$am_make -s -f confmf 2> /dev/null | fgrep -v 'ing directory'`" = "done"; then
- _am_include=include
- _am_quote=
- _am_result=GNU
-fi
-# Now try BSD make style include.
-if test "$_am_include" = "#"; then
- echo '.include "confinc"' > confmf
- if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
- _am_include=.include
- _am_quote='"'
- _am_result=BSD
- fi
-fi
-
-
-echo "$ac_t""$_am_result" 1>&6
-rm -f confinc confmf
-
-am_compiler_list=
-
-depcc="$CC"
-depcpp="$CPP"
-
-
-
-
-echo $ac_n "checking dependency style of $depcc""... $ac_c" 1>&6
-echo "configure:1482: checking dependency style of $depcc" >&5
-if eval "test \"`echo '$''{'am_cv_CC_dependencies_compiler_type'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
- # We make a subdir and do the tests there. Otherwise we can end up
- # making bogus files that we don't know about and never remove. For
- # instance it was reported that on HP-UX the gcc test will end up
- # making a dummy file named `D' -- because `-MD' means `put the output
- # in D'.
- mkdir confdir
- # Copy depcomp to subdir because otherwise we won't find it if we're
- # using a relative directory.
- cp "$am_depcomp" confdir
- cd confdir
-
- am_cv_CC_dependencies_compiler_type=none
- if test "$am_compiler_list" = ""; then
- am_compiler_list="`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`"
- fi
- for depmode in $am_compiler_list; do
- # We need to recreate these files for each test, as the compiler may
- # overwrite some of them when testing with obscure command lines.
- # This happens at least with the AIX C compiler.
- echo '#include "conftest.h"' > conftest.c
- echo 'int i;' > conftest.h
-
- case "$depmode" in
- nosideeffect)
- # after this tag, mechanisms are not by side-effect, so they'll
- # only be used when explicitly requested
- if test "x$enable_dependency_tracking" = xyes; then
- continue
- else
- break
- fi
- ;;
- none) break ;;
- esac
- # We check with `-c' and `-o' for the sake of the "dashmstdout"
- # mode. It turns out that the SunPro C++ compiler does not properly
- # handle `-M -o', and we need to detect this.
- if depmode="$depmode" \
- source=conftest.c object=conftest.o \
- depfile=conftest.Po tmpdepfile=conftest.TPo \
- $SHELL ./depcomp $depcc -c conftest.c -o conftest.o >/dev/null 2>&1 &&
- grep conftest.h conftest.Po > /dev/null 2>&1; then
- am_cv_CC_dependencies_compiler_type="$depmode"
- break
- fi
- done
-
- cd ..
- rm -rf confdir
-else
- am_cv_CC_dependencies_compiler_type=none
-fi
-
-fi
-
-echo "$ac_t""$am_cv_CC_dependencies_compiler_type" 1>&6
-CCDEPMODE="depmode=$am_cv_CC_dependencies_compiler_type"
-
-
-
-AS="$CC"
-
-
-# Check whether --with-binutils or --without-binutils was given.
-if test "${with_binutils+set}" = set; then
- withval="$with_binutils"
- :
-fi
-
-
-if test "x$with_binutils" != x; then
- # Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1561: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_path_RANLIB'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- case "$RANLIB" in
- /*)
- ac_cv_path_RANLIB="$RANLIB" # Let the user override the test with a path.
- ;;
- ?:/*)
- ac_cv_path_RANLIB="$RANLIB" # Let the user override the test with a dos path.
- ;;
- *)
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy=""$with_binutils:$PATH""
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_path_RANLIB="$ac_dir/$ac_word"
- break
- fi
- done
- IFS="$ac_save_ifs"
- test -z "$ac_cv_path_RANLIB" && ac_cv_path_RANLIB=":"
- ;;
-esac
-fi
-RANLIB="$ac_cv_path_RANLIB"
-if test -n "$RANLIB"; then
- echo "$ac_t""$RANLIB" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
-else
- # Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1598: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_RANLIB="ranlib"
- break
- fi
- done
- IFS="$ac_save_ifs"
- test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
-fi
-fi
-RANLIB="$ac_cv_prog_RANLIB"
-if test -n "$RANLIB"; then
- echo "$ac_t""$RANLIB" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
-fi
-
-# optimization flags
-if test "x$ac_cv_prog_gcc" = xyes; then
- if test "x$default_CFLAGS" = xyes; then
- CFLAGS="-g"
- # If the user specify the directory for binutils, add the option `-B'.
- if test "x$with_binutils" != x; then
- CFLAGS="-B$with_binutils/ $CFLAGS"
- fi
- STAGE1_CFLAGS="-O2"
- GRUB_CFLAGS="-O2"
- echo $ac_n "checking whether optimization for size works""... $ac_c" 1>&6
-echo "configure:1638: checking whether optimization for size works" >&5
-if eval "test \"`echo '$''{'size_flag'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
-
- saved_CFLAGS=$CFLAGS
- CFLAGS="-Os -g"
- cat > conftest.$ac_ext <<EOF
-#line 1646 "configure"
-#include "confdefs.h"
-
-int main() {
-
-; return 0; }
-EOF
-if { (eval echo configure:1653: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
- size_flag=yes
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- size_flag=no
-fi
-rm -f conftest*
- CFLAGS=$saved_CFLAGS
-
-fi
-
-echo "$ac_t""$size_flag" 1>&6
- if test "x$size_flag" = xyes; then
- STAGE2_CFLAGS="-Os"
- else
- STAGE2_CFLAGS="-O2 -fno-strength-reduce -fno-unroll-loops"
- fi
- fi
-fi
-
-
-
-
-
-# Enforce coding standards.
-CPPFLAGS="$CPPFLAGS -Wall -Wmissing-prototypes -Wunused -Wshadow"
-CPPFLAGS="$CPPFLAGS -Wpointer-arith"
-
-echo $ac_n "checking whether -Wundef works""... $ac_c" 1>&6
-echo "configure:1685: checking whether -Wundef works" >&5
-if eval "test \"`echo '$''{'undef_flag'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
-
- saved_CPPFLAGS=$CPPFLAGS
- CPPFLAGS="-Wundef"
- cat > conftest.$ac_ext <<EOF
-#line 1693 "configure"
-#include "confdefs.h"
-
-int main() {
-
-; return 0; }
-EOF
-if { (eval echo configure:1700: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
- undef_flag=yes
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- undef_flag=no
-fi
-rm -f conftest*
- CPPFLAGS=$saved_CPPFLAGS
-
-fi
-
-echo "$ac_t""$undef_flag" 1>&6
-
-# Force no alignment to save space.
-CPPFLAGS="$CPPFLAGS -malign-jumps=1 -malign-loops=1 -malign-functions=1"
-
-if test "x$undef_flag" = xyes; then
- CPPFLAGS="$CPPFLAGS -Wundef"
-fi
-
-if test "x$with_binutils" != x; then
- # Extract the first word of "objcopy", so it can be a program name with args.
-set dummy objcopy; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1727: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- case "$OBJCOPY" in
- /*)
- ac_cv_path_OBJCOPY="$OBJCOPY" # Let the user override the test with a path.
- ;;
- ?:/*)
- ac_cv_path_OBJCOPY="$OBJCOPY" # Let the user override the test with a dos path.
- ;;
- *)
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy=""$with_binutils:$PATH""
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_path_OBJCOPY="$ac_dir/$ac_word"
- break
- fi
- done
- IFS="$ac_save_ifs"
- ;;
-esac
-fi
-OBJCOPY="$ac_cv_path_OBJCOPY"
-if test -n "$OBJCOPY"; then
- echo "$ac_t""$OBJCOPY" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
-else
- # Extract the first word of "${ac_tool_prefix}objcopy", so it can be a program name with args.
-set dummy ${ac_tool_prefix}objcopy; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1763: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_OBJCOPY'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$OBJCOPY"; then
- ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_OBJCOPY="${ac_tool_prefix}objcopy"
- break
- fi
- done
- IFS="$ac_save_ifs"
- test -z "$ac_cv_prog_OBJCOPY" && ac_cv_prog_OBJCOPY="objcopy"
-fi
-fi
-OBJCOPY="$ac_cv_prog_OBJCOPY"
-if test -n "$OBJCOPY"; then
- echo "$ac_t""$OBJCOPY" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
-
-
-fi
-
-# Defined in acinclude.m4.
-
-echo $ac_n "checking if C symbols get an underscore after compilation""... $ac_c" 1>&6
-echo "configure:1797: checking if C symbols get an underscore after compilation" >&5
-if eval "test \"`echo '$''{'grub_cv_asm_uscore'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.c <<\EOF
-int
-func (int *list)
-{
- *list = 0;
- return *list;
-}
-EOF
-
-if { ac_try='${CC-cc} ${CFLAGS} -S conftest.c'; { (eval echo configure:1810: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest.s; then
- true
-else
- { echo "configure: error: ${CC-cc} failed to produce assembly code" 1>&2; exit 1; }
-fi
-
-if grep _func conftest.s >/dev/null 2>&1; then
- grub_cv_asm_uscore=yes
-else
- grub_cv_asm_uscore=no
-fi
-
-rm -f conftest*
-fi
-
-
-if test "x$grub_cv_asm_uscore" = xyes; then
- cat >> confdefs.h <<EOF
-#define HAVE_ASM_USCORE $grub_cv_asm_uscore
-EOF
-
-fi
-
-echo "$ac_t""$grub_cv_asm_uscore" 1>&6
-
-echo $ac_n "checking whether ${OBJCOPY} works for absolute addresses""... $ac_c" 1>&6
-echo "configure:1836: checking whether ${OBJCOPY} works for absolute addresses" >&5
-if eval "test \"`echo '$''{'grub_cv_prog_objcopy_absolute'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.c <<\EOF
-void
-cmain (void)
-{
- *((int *) 0x1000) = 2;
-}
-EOF
-
-if { (eval echo configure:1848: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; } && test -s conftest.o; then :
-else
- { echo "configure: error: ${CC-cc} cannot compile C source code" 1>&2; exit 1; }
-fi
-grub_cv_prog_objcopy_absolute=yes
-for link_addr in 2000 8000 7C00; do
- if { ac_try='${CC-cc} ${CFLAGS} -nostdlib -Wl,-N -Wl,-Ttext -Wl,$link_addr conftest.o -o conftest.exec'; { (eval echo configure:1854: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then :
- else
- { echo "configure: error: ${CC-cc} cannot link at address $link_addr" 1>&2; exit 1; }
- fi
- if { ac_try='${OBJCOPY-objcopy} -O binary conftest.exec conftest'; { (eval echo configure:1858: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then :
- else
- { echo "configure: error: ${OBJCOPY-objcopy} cannot create binary files" 1>&2; exit 1; }
- fi
- if test ! -f conftest.old || { ac_try='cmp -s conftest.old conftest'; { (eval echo configure:1862: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
- mv -f conftest conftest.old
- else
- grub_cv_prog_objcopy_absolute=no
- break
- fi
-done
-rm -f conftest*
-fi
-
-echo "$ac_t""$grub_cv_prog_objcopy_absolute" 1>&6
-if test "x$grub_cv_prog_objcopy_absolute" != xyes; then
- { echo "configure: error: GRUB requires a working absolute objcopy; upgrade your binutils" 1>&2; exit 1; }
-fi
-
-
-echo $ac_n "checking whether addr32 must be in the same line as the instruction""... $ac_c" 1>&6
-echo "configure:1879: checking whether addr32 must be in the same line as the instruction" >&5
-if eval "test \"`echo '$''{'grub_cv_asm_prefix_requirement'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.s <<\EOF
- .code16
-l1: addr32 movb %al, l1
-EOF
-
-if { ac_try='${CC-cc} ${CFLAGS} -c conftest.s'; { (eval echo configure:1888: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest.o; then
- grub_cv_asm_prefix_requirement=yes
-else
- grub_cv_asm_prefix_requirement=no
-fi
-
-rm -f conftest*
-fi
-
-
-if test "x$grub_cv_asm_prefix_requirement" = xyes; then
- grub_tmp_addr32="addr32"
- grub_tmp_data32="data32"
-else
- grub_tmp_addr32="addr32;"
- grub_tmp_data32="data32;"
-fi
-
-cat >> confdefs.h <<EOF
-#define ADDR32 $grub_tmp_addr32
-EOF
-
-cat >> confdefs.h <<EOF
-#define DATA32 $grub_tmp_data32
-EOF
-
-
-echo "$ac_t""$grub_cv_asm_prefix_requirement" 1>&6
-
-
-
-echo $ac_n "checking for .code16 addr32 assembler support""... $ac_c" 1>&6
-echo "configure:1920: checking for .code16 addr32 assembler support" >&5
-if eval "test \"`echo '$''{'grub_cv_asm_addr32'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.s.in <<\EOF
- .code16
-l1: @ADDR32@ movb %al, l1
-EOF
-
-if test "x$grub_cv_asm_prefix_requirement" = xyes; then
- sed -e s/@ADDR32@/addr32/ < conftest.s.in > conftest.s
-else
- sed -e s/@ADDR32@/addr32\;/ < conftest.s.in > conftest.s
-fi
-
-if { ac_try='${CC-cc} ${CFLAGS} -c conftest.s'; { (eval echo configure:1935: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest.o; then
- grub_cv_asm_addr32=yes
-else
- grub_cv_asm_addr32=no
-fi
-
-rm -f conftest*
-fi
-
-
-echo "$ac_t""$grub_cv_asm_addr32" 1>&6
-if test "x$grub_cv_asm_addr32" != xyes; then
- { echo "configure: error: GRUB requires GAS .code16 addr32 support; upgrade your binutils" 1>&2; exit 1; }
-fi
-
-
-echo $ac_n "checking whether an absolute indirect call/jump must not be prefixed with an asterisk""... $ac_c" 1>&6
-echo "configure:1952: checking whether an absolute indirect call/jump must not be prefixed with an asterisk" >&5
-if eval "test \"`echo '$''{'grub_cv_asm_absolute_without_asterisk'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.s <<\EOF
- lcall *(offset)
-offset:
- .long 0
- .word 0
-EOF
-
-if { ac_try='${CC-cc} ${CFLAGS} -c conftest.s'; { (eval echo configure:1963: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest.o; then
- grub_cv_asm_absolute_without_asterisk=no
-else
- grub_cv_asm_absolute_without_asterisk=yes
-fi
-
-rm -f conftest*
-fi
-
-
-if test "x$grub_cv_asm_absolute_without_asterisk" = xyes; then
- cat >> confdefs.h <<\EOF
-#define ABSOLUTE_WITHOUT_ASTERISK 1
-EOF
-
-fi
-
-echo "$ac_t""$grub_cv_asm_absolute_without_asterisk" 1>&6
-
-
-echo $ac_n "checking if start is defined by the compiler""... $ac_c" 1>&6
-echo "configure:1984: checking if start is defined by the compiler" >&5
-if eval "test \"`echo '$''{'grub_cv_check_start_symbol'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 1989 "configure"
-#include "confdefs.h"
-
-int main() {
-asm ("incl start")
-; return 0; }
-EOF
-if { (eval echo configure:1996: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- grub_cv_check_start_symbol=yes
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- grub_cv_check_start_symbol=no
-fi
-rm -f conftest*
-fi
-
-
-if test "x$grub_cv_check_start_symbol" = xyes; then
- cat >> confdefs.h <<\EOF
-#define HAVE_START_SYMBOL 1
-EOF
-
-fi
-
-echo "$ac_t""$grub_cv_check_start_symbol" 1>&6
-
-
-echo $ac_n "checking if _start is defined by the compiler""... $ac_c" 1>&6
-echo "configure:2020: checking if _start is defined by the compiler" >&5
-if eval "test \"`echo '$''{'grub_cv_check_uscore_start_symbol'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2025 "configure"
-#include "confdefs.h"
-
-int main() {
-asm ("incl _start")
-; return 0; }
-EOF
-if { (eval echo configure:2032: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- grub_cv_check_uscore_start_symbol=yes
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- grub_cv_check_uscore_start_symbol=no
-fi
-rm -f conftest*
-fi
-
-
-if test "x$grub_cv_check_uscore_start_symbol" = xyes; then
- cat >> confdefs.h <<\EOF
-#define HAVE_USCORE_START_SYMBOL 1
-EOF
-
-fi
-
-echo "$ac_t""$grub_cv_check_uscore_start_symbol" 1>&6
-
-if test "x$grub_cv_check_start_symbol" != "xyes" \
- -a "x$grub_cv_check_uscore_start_symbol" != "xyes"; then
- { echo "configure: error: Neither start nor _start is defined" 1>&2; exit 1; }
-fi
-
-
-echo $ac_n "checking if __bss_start is defined by the compiler""... $ac_c" 1>&6
-echo "configure:2061: checking if __bss_start is defined by the compiler" >&5
-if eval "test \"`echo '$''{'grub_cv_check_uscore_uscore_bss_start_symbol'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2066 "configure"
-#include "confdefs.h"
-
-int main() {
-asm ("incl __bss_start")
-; return 0; }
-EOF
-if { (eval echo configure:2073: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- grub_cv_check_uscore_uscore_bss_start_symbol=yes
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- grub_cv_check_uscore_uscore_bss_start_symbol=no
-fi
-rm -f conftest*
-fi
-
-
-if test "x$grub_cv_check_uscore_uscore_bss_start_symbol" = xyes; then
- cat >> confdefs.h <<\EOF
-#define HAVE_USCORE_USCORE_BSS_START_SYMBOL 1
-EOF
-
-fi
-
-echo "$ac_t""$grub_cv_check_uscore_uscore_bss_start_symbol" 1>&6
-
-
-echo $ac_n "checking if _edata is defined by the compiler""... $ac_c" 1>&6
-echo "configure:2097: checking if _edata is defined by the compiler" >&5
-if eval "test \"`echo '$''{'grub_cv_check_uscore_edata_symbol'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2102 "configure"
-#include "confdefs.h"
-
-int main() {
-asm ("incl _edata")
-; return 0; }
-EOF
-if { (eval echo configure:2109: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- grub_cv_check_uscore_edata_symbol=yes
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- grub_cv_check_uscore_edata_symbol=no
-fi
-rm -f conftest*
-fi
-
-
-if test "x$grub_cv_check_uscore_edata_symbol" = xyes; then
- cat >> confdefs.h <<\EOF
-#define HAVE_USCORE_EDATA_SYMBOL 1
-EOF
-
-fi
-
-echo "$ac_t""$grub_cv_check_uscore_edata_symbol" 1>&6
-
-
-echo $ac_n "checking if edata is defined by the compiler""... $ac_c" 1>&6
-echo "configure:2133: checking if edata is defined by the compiler" >&5
-if eval "test \"`echo '$''{'grub_cv_check_edata_symbol'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2138 "configure"
-#include "confdefs.h"
-
-int main() {
-asm ("incl edata")
-; return 0; }
-EOF
-if { (eval echo configure:2145: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- grub_cv_check_edata_symbol=yes
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- grub_cv_check_edata_symbol=no
-fi
-rm -f conftest*
-fi
-
-
-if test "x$grub_cv_check_edata_symbol" = xyes; then
- cat >> confdefs.h <<\EOF
-#define HAVE_EDATA_SYMBOL 1
-EOF
-
-fi
-
-echo "$ac_t""$grub_cv_check_edata_symbol" 1>&6
-
-if test "x$grub_cv_check_uscore_uscore_bss_start_symbol" != "xyes" \
- -a "x$grub_cv_check_uscore_edata_symbol" != "xyes" \
- -a "x$grub_cv_check_edata_symbol" != "xyes"; then
- { echo "configure: error: None of __bss_start, _edata, edata defined" 1>&2; exit 1; }
-fi
-
-
-echo $ac_n "checking if end is defined by the compiler""... $ac_c" 1>&6
-echo "configure:2175: checking if end is defined by the compiler" >&5
-if eval "test \"`echo '$''{'grub_cv_check_end_symbol'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2180 "configure"
-#include "confdefs.h"
-
-int main() {
-asm ("incl end")
-; return 0; }
-EOF
-if { (eval echo configure:2187: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- grub_cv_check_end_symbol=yes
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- grub_cv_check_end_symbol=no
-fi
-rm -f conftest*
-fi
-
-
-if test "x$grub_cv_check_end_symbol" = xyes; then
- cat >> confdefs.h <<\EOF
-#define HAVE_END_SYMBOL 1
-EOF
-
-fi
-
-echo "$ac_t""$grub_cv_check_end_symbol" 1>&6
-
-
-echo $ac_n "checking if _end is defined by the compiler""... $ac_c" 1>&6
-echo "configure:2211: checking if _end is defined by the compiler" >&5
-if eval "test \"`echo '$''{'grub_cv_check_uscore_end_symbol'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2216 "configure"
-#include "confdefs.h"
-
-int main() {
-asm ("incl _end")
-; return 0; }
-EOF
-if { (eval echo configure:2223: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- grub_cv_check_uscore_end_symbol=yes
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- grub_cv_check_uscore_end_symbol=no
-fi
-rm -f conftest*
-fi
-
-
-if test "x$grub_cv_check_uscore_end_symbol" = xyes; then
- cat >> confdefs.h <<\EOF
-#define HAVE_USCORE_END_SYMBOL 1
-EOF
-
-fi
-
-echo "$ac_t""$grub_cv_check_uscore_end_symbol" 1>&6
-
-if test "x$grub_cv_check_end_symbol" != "xyes" \
- -a "x$grub_cv_check_uscore_end_symbol" != "xyes"; then
- { echo "configure: error: Neither end nor _end is defined" 1>&2; exit 1; }
-fi
-
-# Check for curses libraries.
-# Check whether --with-curses or --without-curses was given.
-if test "${with_curses+set}" = set; then
- withval="$with_curses"
- :
-fi
-
-
-# Get the filename or the whole disk and open it.
-# Known to work on NetBSD.
-echo $ac_n "checking for opendisk in -lutil""... $ac_c" 1>&6
-echo "configure:2261: checking for opendisk in -lutil" >&5
-ac_lib_var=`echo util'_'opendisk | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- ac_save_LIBS="$LIBS"
-LIBS="-lutil $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 2269 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char opendisk();
-
-int main() {
-opendisk()
-; return 0; }
-EOF
-if { (eval echo configure:2280: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- GRUB_LIBS="$GRUB_LIBS -lutil"
- cat >> confdefs.h <<\EOF
-#define HAVE_OPENDISK 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
-fi
-
-
-# Unless the user specify --without-curses, check for curses.
-if test "x$with_curses" != "xno"; then
- echo $ac_n "checking for wgetch in -lncurses""... $ac_c" 1>&6
-echo "configure:2308: checking for wgetch in -lncurses" >&5
-ac_lib_var=`echo ncurses'_'wgetch | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- ac_save_LIBS="$LIBS"
-LIBS="-lncurses $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 2316 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char wgetch();
-
-int main() {
-wgetch()
-; return 0; }
-EOF
-if { (eval echo configure:2327: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- GRUB_LIBS="$GRUB_LIBS -lncurses"
- cat >> confdefs.h <<\EOF
-#define HAVE_LIBCURSES 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
-echo $ac_n "checking for wgetch in -lcurses""... $ac_c" 1>&6
-echo "configure:2350: checking for wgetch in -lcurses" >&5
-ac_lib_var=`echo curses'_'wgetch | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- ac_save_LIBS="$LIBS"
-LIBS="-lcurses $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 2358 "configure"
-#include "confdefs.h"
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char wgetch();
-
-int main() {
-wgetch()
-; return 0; }
-EOF
-if { (eval echo configure:2369: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- GRUB_LIBS="$GRUB_LIBS -lcurses"
- cat >> confdefs.h <<\EOF
-#define HAVE_LIBCURSES 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
-fi
-
-fi
-
-fi
-
-
-
-# Check for headers.
-for ac_hdr in string.h strings.h ncurses/curses.h ncurses.h curses.h
-do
-ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2404: checking for $ac_hdr" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2409 "configure"
-#include "confdefs.h"
-#include <$ac_hdr>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2414: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- rm -rf conftest*
- eval "ac_cv_header_$ac_safe=yes"
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_header_$ac_safe=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
- cat >> confdefs.h <<EOF
-#define $ac_tr_hdr 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
-fi
-done
-
-
-# Check for user options.
-
-# filesystems support.
-# Check whether --enable-ext2fs or --disable-ext2fs was given.
-if test "${enable_ext2fs+set}" = set; then
- enableval="$enable_ext2fs"
- :
-fi
-
-
-if test x"$enable_ext2fs" != xno; then
- FSYS_CFLAGS="$FSYS_CFLAGS -DFSYS_EXT2FS=1"
-fi
-
-# Check whether --enable-fat or --disable-fat was given.
-if test "${enable_fat+set}" = set; then
- enableval="$enable_fat"
- :
-fi
-
-
-if test x"$enable_fat" != xno; then
- FSYS_CFLAGS="$FSYS_CFLAGS -DFSYS_FAT=1"
-fi
-
-# Check whether --enable-ffs or --disable-ffs was given.
-if test "${enable_ffs+set}" = set; then
- enableval="$enable_ffs"
- :
-fi
-
-
-if test x"$enable_ffs" != xno; then
- FSYS_CFLAGS="$FSYS_CFLAGS -DFSYS_FFS=1"
-fi
-
-# Check whether --enable-minix or --disable-minix was given.
-if test "${enable_minix+set}" = set; then
- enableval="$enable_minix"
- :
-fi
-
-
-if test x"$enable_minix" != xno; then
- FSYS_CFLAGS="$FSYS_CFLAGS -DFSYS_MINIX=1"
-fi
-
-# Check whether --enable-reiserfs or --disable-reiserfs was given.
-if test "${enable_reiserfs+set}" = set; then
- enableval="$enable_reiserfs"
- :
-fi
-
-
-if test x"$enable_reiserfs" != xno; then
- FSYS_CFLAGS="$FSYS_CFLAGS -DFSYS_REISERFS=1"
-fi
-
-# Check whether --enable-jfs or --disable-jfs was given.
-if test "${enable_jfs+set}" = set; then
- enableval="$enable_jfs"
- :
-fi
-
-
-if test x"$enable_jfs" != xno; then
- FSYS_CFLAGS="$FSYS_CFLAGS -DFSYS_JFS=1"
-fi
-
-# Check whether --enable-xfs or --disable-xfs was given.
-if test "${enable_xfs+set}" = set; then
- enableval="$enable_xfs"
- :
-fi
-
-
-if test x"$enable_xfs" != xno; then
- FSYS_CFLAGS="$FSYS_CFLAGS -DFSYS_XFS=1"
-fi
-
-# Check whether --enable-vstafs or --disable-vstafs was given.
-if test "${enable_vstafs+set}" = set; then
- enableval="$enable_vstafs"
- :
-fi
-
-
-if test x"$enable_vstafs" != xno; then
- FSYS_CFLAGS="$FSYS_CFLAGS -DFSYS_VSTAFS=1"
-fi
-
-
-# Check whether --enable-gunzip or --disable-gunzip was given.
-if test "${enable_gunzip+set}" = set; then
- enableval="$enable_gunzip"
- :
-fi
-
-
-if test x"$enable_gunzip" = xno; then
- FSYS_CFLAGS="$FSYS_CFLAGS -DNO_DECOMPRESSION=1"
-fi
-
-# Check whether --enable-md5-password or --disable-md5-password was given.
-if test "${enable_md5_password+set}" = set; then
- enableval="$enable_md5_password"
- :
-fi
-
-if test "x$enable_md5_password" != xno; then
- FSYS_CFLAGS="$FSYS_CFLAGS -DUSE_MD5_PASSWORDS=1"
-fi
-
-# Check whether --enable-packet-retransmission or --disable-packet-retransmission was given.
-if test "${enable_packet_retransmission+set}" = set; then
- enableval="$enable_packet_retransmission"
- :
-fi
-
-if test "x$enable_packet_retransmission" != xno; then
- NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DCONGESTED=1"
-fi
-
-# Check whether --enable-pci-direct or --disable-pci-direct was given.
-if test "${enable_pci_direct+set}" = set; then
- enableval="$enable_pci_direct"
- :
-fi
-
-if test "x$enable_pci_direct" = xyes; then
- NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DCONFIG_PCI_DIRECT=1"
-fi
-
-# Check whether --enable-3c509 or --disable-3c509 was given.
-if test "${enable_3c509+set}" = set; then
- enableval="$enable_3c509"
- :
-fi
-
-if test "x$enable_3c509" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_3C509"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS 3c509.o"
-fi
-
-# Check whether --enable-3c529 or --disable-3c529 was given.
-if test "${enable_3c529+set}" = set; then
- enableval="$enable_3c529"
- :
-fi
-
-if test "x$enable_3c529" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_3C529=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS 3c529.o"
-fi
-
-# Check whether --enable-3c590 or --disable-3c590 was given.
-if test "${enable_3c590+set}" = set; then
- enableval="$enable_3c590"
- :
-fi
-
-if test "x$enable_3c590" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_3C590=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS 3c590.o"
-fi
-
-# Check whether --enable-3c595 or --disable-3c595 was given.
-if test "${enable_3c595+set}" = set; then
- enableval="$enable_3c595"
- :
-fi
-
-if test "x$enable_3c595" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_3C595=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS 3c595.o"
-fi
-
-# Check whether --enable-3c90x or --disable-3c90x was given.
-if test "${enable_3c90x+set}" = set; then
- enableval="$enable_3c90x"
- :
-fi
-
-if test "x$enable_3c90x" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_3C90X=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS 3c90x.o"
-fi
-
-# Check whether --enable-cs89x0 or --disable-cs89x0 was given.
-if test "${enable_cs89x0+set}" = set; then
- enableval="$enable_cs89x0"
- :
-fi
-
-if test "x$enable_cs89x0" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_CS89X0=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS cs89x0.o"
-fi
-
-# Check whether --enable-depca or --disable-depca was given.
-if test "${enable_depca+set}" = set; then
- enableval="$enable_depca"
- :
-fi
-
-if test "x$enable_depca" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_DEPCA=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS depca.o"
-fi
-
-# Check whether --enable-eepro100 or --disable-eepro100 was given.
-if test "${enable_eepro100+set}" = set; then
- enableval="$enable_eepro100"
- :
-fi
-
-if test "x$enable_eepro100" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_EEPRO100=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS eepro100.o"
-fi
-
-# Check whether --enable-epic100 or --disable-epic100 was given.
-if test "${enable_epic100+set}" = set; then
- enableval="$enable_epic100"
- :
-fi
-
-if test "x$enable_epic100" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_EPIC100=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS epic100.o"
-fi
-
-# Check whether --enable-3c507 or --disable-3c507 was given.
-if test "${enable_3c507+set}" = set; then
- enableval="$enable_3c507"
- :
-fi
-
-if test "x$enable_3c507" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_3C507=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS 3c507.o"
-fi
-
-# Check whether --enable-exos205 or --disable-exos205 was given.
-if test "${enable_exos205+set}" = set; then
- enableval="$enable_exos205"
- :
-fi
-
-if test "x$enable_exos205" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_EXOS205=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS exos205.o"
-fi
-
-# Check whether --enable-ni5210 or --disable-ni5210 was given.
-if test "${enable_ni5210+set}" = set; then
- enableval="$enable_ni5210"
- :
-fi
-
-if test "x$enable_ni5210" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_NI5210=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS ni5210.o"
-fi
-
-# Check whether --enable-lance or --disable-lance was given.
-if test "${enable_lance+set}" = set; then
- enableval="$enable_lance"
- :
-fi
-
-if test "x$enable_lance" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_LANCE=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS lance.o"
-fi
-
-# Check whether --enable-ne2100 or --disable-ne2100 was given.
-if test "${enable_ne2100+set}" = set; then
- enableval="$enable_ne2100"
- :
-fi
-
-if test "x$enable_ne2100" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_NE2100=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS ne2100.o"
-fi
-
-# Check whether --enable-ni6510 or --disable-ni6510 was given.
-if test "${enable_ni6510+set}" = set; then
- enableval="$enable_ni6510"
- :
-fi
-
-if test "x$enable_ni6510" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_NI6510=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS ni6510.o"
-fi
-
-# Check whether --enable-3c503 or --disable-3c503 was given.
-if test "${enable_3c503+set}" = set; then
- enableval="$enable_3c503"
- :
-fi
-
-if test "x$enable_3c503" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_3C503=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS 3c503.o"
-fi
-
-# Check whether --enable-ne or --disable-ne was given.
-if test "${enable_ne+set}" = set; then
- enableval="$enable_ne"
- :
-fi
-
-if test "x$enable_ne" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_NE=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS ne.o"
-fi
-
-# Check whether --enable-ns8390 or --disable-ns8390 was given.
-if test "${enable_ns8390+set}" = set; then
- enableval="$enable_ns8390"
- :
-fi
-
-if test "x$enable_ns8390" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_NS8390=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS ns8390.o"
-fi
-
-# Check whether --enable-wd or --disable-wd was given.
-if test "${enable_wd+set}" = set; then
- enableval="$enable_wd"
- :
-fi
-
-if test "x$enable_wd" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_WD=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS wd.o"
-fi
-
-# Check whether --enable-otulip or --disable-otulip was given.
-if test "${enable_otulip+set}" = set; then
- enableval="$enable_otulip"
- :
-fi
-
-if test "x$enable_otulip" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_OTULIP=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS otulip.o"
-fi
-
-# Check whether --enable-rtl8139 or --disable-rtl8139 was given.
-if test "${enable_rtl8139+set}" = set; then
- enableval="$enable_rtl8139"
- :
-fi
-
-if test "x$enable_rtl8139" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_RTL8139=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS rtl8139.o"
-fi
-
-# Check whether --enable-sk-g16 or --disable-sk-g16 was given.
-if test "${enable_sk_g16+set}" = set; then
- enableval="$enable_sk_g16"
- :
-fi
-
-if test "x$enable_sk_g16" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_SK_G16=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS sk_g16.o"
-fi
-
-# Check whether --enable-smc9000 or --disable-smc9000 was given.
-if test "${enable_smc9000+set}" = set; then
- enableval="$enable_smc9000"
- :
-fi
-
-if test "x$enable_smc9000" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_SMC9000=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS smc9000.o"
-fi
-
-# Check whether --enable-tiara or --disable-tiara was given.
-if test "${enable_tiara+set}" = set; then
- enableval="$enable_tiara"
- :
-fi
-
-if test "x$enable_tiara" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_TIARA=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS tiara.o"
-fi
-
-# Check whether --enable-tulip or --disable-tulip was given.
-if test "${enable_tulip+set}" = set; then
- enableval="$enable_tulip"
- :
-fi
-
-if test "x$enable_tulip" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_TULIP=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS tulip.o"
-fi
-
-# Check whether --enable-via-rhine or --disable-via-rhine was given.
-if test "${enable_via_rhine+set}" = set; then
- enableval="$enable_via_rhine"
- :
-fi
-
-if test "x$enable_via_rhine" = xyes; then
- NET_CFLAGS="$NET_CFLAGS -DINCLUDE_VIA_RHINE=1"
- NETBOOT_DRIVERS="$NETBOOT_DRIVERS via_rhine.o"
-fi
-
-
-
-if test "x$NET_CFLAGS" != x; then
- NETBOOT_SUPPORT_TRUE=
- NETBOOT_SUPPORT_FALSE='#'
-else
- NETBOOT_SUPPORT_TRUE='#'
- NETBOOT_SUPPORT_FALSE=
-fi
-if test "x$NET_CFLAGS" != x; then
- FSYS_CFLAGS="$FSYS_CFLAGS -DFSYS_TFTP=1"
-fi
-
-# Check whether --enable-3c503-shmem or --disable-3c503-shmem was given.
-if test "${enable_3c503_shmem+set}" = set; then
- enableval="$enable_3c503_shmem"
- :
-fi
-
-if test "x$enable_3c503_shmem" = xyes; then
- NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DT503_SHMEM=1"
-fi
-
-# Check whether --enable-3c503-aui or --disable-3c503-aui was given.
-if test "${enable_3c503_aui+set}" = set; then
- enableval="$enable_3c503_aui"
- :
-fi
-
-if test "x$enable_3c503_aui" = xyes; then
- NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DT503_AUI=1"
-fi
-
-# Check whether --enable-3c509-hack or --disable-3c509-hack was given.
-if test "${enable_3c509_hack+set}" = set; then
- enableval="$enable_3c509_hack"
- :
-fi
-
-if test "x$enable_3c509_hack" = xyes; then
- NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DT509HACK=1"
-fi
-
-# Check whether --enable-compex-rl2000-fix or --disable-compex-rl2000-fix was given.
-if test "${enable_compex_rl2000_fix+set}" = set; then
- enableval="$enable_compex_rl2000_fix"
- :
-fi
-
-if test "x$enable_compex_rl2000_fix" = xyes; then
- NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DCOMPEX_RL2000_FIX=1"
-fi
-
-# Check whether --enable-ns8390-force-16bit or --disable-ns8390-force-16bit was given.
-if test "${enable_ns8390_force_16bit+set}" = set; then
- enableval="$enable_ns8390_force_16bit"
- :
-fi
-
-if test "x$enable_ns8390_force_16bit" = xyes; then
- NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DNS8390_FORCE_16BIT=1"
-fi
-
-# Check whether --enable-smc9000-scan or --disable-smc9000-scan was given.
-if test "${enable_smc9000_scan+set}" = set; then
- enableval="$enable_smc9000_scan"
- NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DSMC9000_SCAN=$enable_smc9000_scan"
-fi
-
-
-# Check whether --enable-ne-scan or --disable-ne-scan was given.
-if test "${enable_ne_scan+set}" = set; then
- enableval="$enable_ne_scan"
- NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DNE_SCAN=$enable_ne_scan"
-else
- NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DNE_SCAN=0x280,0x300,0x320,0x340"
-fi
-
-
-# Check whether --enable-wd-default-mem or --disable-wd-default-mem was given.
-if test "${enable_wd_default_mem+set}" = set; then
- enableval="$enable_wd_default_mem"
- NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DWD_DEFAULT_MEM=$enable_wd_default_mem"
-else
- NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DWD_DEFAULT_MEM=0xCC000"
-fi
-
-
-# Check whether --enable-cs-scan or --disable-cs-scan was given.
-if test "${enable_cs_scan+set}" = set; then
- enableval="$enable_cs_scan"
- NET_EXTRAFLAGS="$NET_EXTRAFLAGS -DCS_SCAN=$enable_cs_scan"
-fi
-
-
-# Check whether --enable-diskless or --disable-diskless was given.
-if test "${enable_diskless+set}" = set; then
- enableval="$enable_diskless"
- :
-fi
-
-
-
-if test "x$enable_diskless" = xyes; then
- DISKLESS_SUPPORT_TRUE=
- DISKLESS_SUPPORT_FALSE='#'
-else
- DISKLESS_SUPPORT_TRUE='#'
- DISKLESS_SUPPORT_FALSE=
-fi
-
-# Check whether --enable-hercules or --disable-hercules was given.
-if test "${enable_hercules+set}" = set; then
- enableval="$enable_hercules"
- :
-fi
-
-
-
-if test "x$enable_hercules" != xno; then
- HERCULES_SUPPORT_TRUE=
- HERCULES_SUPPORT_FALSE='#'
-else
- HERCULES_SUPPORT_TRUE='#'
- HERCULES_SUPPORT_FALSE=
-fi
-
-# Check whether --enable-serial or --disable-serial was given.
-if test "${enable_serial+set}" = set; then
- enableval="$enable_serial"
- :
-fi
-
-
-
-if test "x$enable_serial" != xno; then
- SERIAL_SUPPORT_TRUE=
- SERIAL_SUPPORT_FALSE='#'
-else
- SERIAL_SUPPORT_TRUE='#'
- SERIAL_SUPPORT_FALSE=
-fi
-
-# Check whether --enable-serial-speed-simulation or --disable-serial-speed-simulation was given.
-if test "${enable_serial_speed_simulation+set}" = set; then
- enableval="$enable_serial_speed_simulation"
- :
-fi
-
-
-
-if test "x$enable_serial_speed_simulation" = xyes; then
- SERIAL_SPEED_SIMULATION_TRUE=
- SERIAL_SPEED_SIMULATION_FALSE='#'
-else
- SERIAL_SPEED_SIMULATION_TRUE='#'
- SERIAL_SPEED_SIMULATION_FALSE=
-fi
-
-# Sanity check.
-if test "x$enable_diskless" = xyes; then
- if test "x$NET_CFLAGS" = x; then
- { echo "configure: error: You must enable at least one network driver" 1>&2; exit 1; }
- fi
-fi
-
-# Check whether --enable-preset-menu or --disable-preset-menu was given.
-if test "${enable_preset_menu+set}" = set; then
- enableval="$enable_preset_menu"
- :
-fi
-
-if test "x$enable_preset_menu" = x; then
- :
-else
- if test -r $enable_preset_menu; then
-
-# Because early versions of GNU sed 3.x are too buggy, use a C program
-# instead of shell commands. *sigh*
-cat >conftest.c <<\EOF
-#include <stdio.h>
-
-int
-main (void)
-{
- int c;
-
- while ((c = getchar ()) != EOF)
- {
- switch (c)
- {
- case '\n':
- fputs ("\\n", stdout);
- break;
- case '\r':
- fputs ("\\r", stdout);
- break;
- case '\\':
- fputs ("\\\\", stdout);
- break;
- case '"':
- fputs ("\\\"", stdout);
- break;
- default:
- putchar (c);
- }
- }
-
- return 0;
-}
-EOF
-
-if { ac_try='${CC-cc} ${CFLAGS} conftest.c -o conftest'; { (eval echo configure:3072: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest; then
- grub_tmp_value=`./conftest < "$enable_preset_menu"`
-else
- { echo "configure: error: ${CC-cc} failed to produce an executable file" 1>&2; exit 1; }
-fi
-
-cat >> confdefs.h <<EOF
-#define PRESET_MENU_STRING "$grub_tmp_value"
-EOF
-
-rm -f conftest*
-
- else
- { echo "configure: error: Cannot read the preset menu file $enable_preset_menu" 1>&2; exit 1; }
- fi
-fi
-
-# Check whether --enable-example-kernel or --disable-example-kernel was given.
-if test "${enable_example_kernel+set}" = set; then
- enableval="$enable_example_kernel"
- :
-fi
-
-
-
-if test "x$enable_example_kernel" = xyes; then
- BUILD_EXAMPLE_KERNEL_TRUE=
- BUILD_EXAMPLE_KERNEL_FALSE='#'
-else
- BUILD_EXAMPLE_KERNEL_TRUE='#'
- BUILD_EXAMPLE_KERNEL_FALSE=
-fi
-
-# Check whether --enable-auto-linux-mem-opt or --disable-auto-linux-mem-opt was given.
-if test "${enable_auto_linux_mem_opt+set}" = set; then
- enableval="$enable_auto_linux_mem_opt"
- :
-fi
-
-if test "x$enable_auto_linux_mem_opt" = xno; then
- :
-else
- cat >> confdefs.h <<\EOF
-#define AUTO_LINUX_MEM_OPT 1
-EOF
-
-fi
-
-
-
-
-
-
-ASFLAGS='$(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(CPPFLAGS) $(CFLAGS)'
-
-
-# Check whether --enable-vga16 or --disable-vga16 was given.
-if test "${enable_vga16+set}" = set; then
- enableval="$enable_vga16"
- :
-fi
-
-
-if test x"$enable_vga16" != xno; then
- STAGE2_CFLAGS="$STAGE2_CFLAGS -DVGA16=1"
-fi
-
-trap '' 1 2 15
-cat > confcache <<\EOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs. It is not useful on other systems.
-# If it contains results you don't want to keep, you may remove or edit it.
-#
-# By default, configure uses ./config.cache as the cache file,
-# creating it if it does not exist already. You can give configure
-# the --cache-file=FILE option to use a different cache file; that is
-# what configure does when it calls configure scripts in
-# subdirectories, so they share the cache.
-# Giving --cache-file=/dev/null disables caching, for debugging configure.
-# config.status only pays attention to the cache file if you give it the
-# --recheck option to rerun configure.
-#
-EOF
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, don't put newlines in cache variables' values.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-(set) 2>&1 |
- case `(ac_space=' '; set | grep ac_space) 2>&1` in
- *ac_space=\ *)
- # `set' does not quote correctly, so add quotes (double-quote substitution
- # turns \\\\ into \\, and sed turns \\ into \).
- sed -n \
- -e "s/'/'\\\\''/g" \
- -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
- ;;
- *)
- # `set' quotes correctly as required by POSIX, so do not add quotes.
- sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
- ;;
- esac >> confcache
-if cmp -s $cache_file confcache; then
- :
-else
- if test -w $cache_file; then
- echo "updating cache $cache_file"
- cat confcache > $cache_file
- else
- echo "not updating unwritable cache $cache_file"
- fi
-fi
-rm -f confcache
-
-trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-# Any assignment to VPATH causes Sun make to only execute
-# the first set of double-colon rules, so remove it if not needed.
-# If there is a colon in the path, we need to keep it.
-if test "x$srcdir" = x.; then
- ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
-fi
-
-trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
-
-DEFS=-DHAVE_CONFIG_H
-
-# Without the "./", some shells look in PATH for config.status.
-: ${CONFIG_STATUS=./config.status}
-
-echo creating $CONFIG_STATUS
-rm -f $CONFIG_STATUS
-cat > $CONFIG_STATUS <<EOF
-#! /bin/sh
-# Generated automatically by configure.
-# Run this file to recreate the current configuration.
-# This directory was configured as follows,
-# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
-#
-# $0 $ac_configure_args
-#
-# Compiler output produced by configure, useful for debugging
-# configure, is in ./config.log if it exists.
-
-ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
-for ac_option
-do
- case "\$ac_option" in
- -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
- echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
- exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
- -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
- echo "$CONFIG_STATUS generated by autoconf version 2.13"
- exit 0 ;;
- -help | --help | --hel | --he | --h)
- echo "\$ac_cs_usage"; exit 0 ;;
- *) echo "\$ac_cs_usage"; exit 1 ;;
- esac
-done
-
-ac_given_srcdir=$srcdir
-ac_given_INSTALL="$INSTALL"
-
-trap 'rm -fr `echo "Makefile stage1/Makefile stage2/Makefile docs/Makefile \
- lib/Makefile util/Makefile grub/Makefile \
- netboot/Makefile util/grub-image util/grub-install \
- util/grub-md5-crypt config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
-EOF
-cat >> $CONFIG_STATUS <<EOF
-
-# Protect against being on the right side of a sed subst in config.status.
-sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
- s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
-$ac_vpsub
-$extrasub
-s%@SHELL@%$SHELL%g
-s%@CFLAGS@%$CFLAGS%g
-s%@CPPFLAGS@%$CPPFLAGS%g
-s%@CXXFLAGS@%$CXXFLAGS%g
-s%@FFLAGS@%$FFLAGS%g
-s%@DEFS@%$DEFS%g
-s%@LDFLAGS@%$LDFLAGS%g
-s%@LIBS@%$LIBS%g
-s%@exec_prefix@%$exec_prefix%g
-s%@prefix@%$prefix%g
-s%@program_transform_name@%$program_transform_name%g
-s%@bindir@%$bindir%g
-s%@sbindir@%$sbindir%g
-s%@libexecdir@%$libexecdir%g
-s%@datadir@%$datadir%g
-s%@sysconfdir@%$sysconfdir%g
-s%@sharedstatedir@%$sharedstatedir%g
-s%@localstatedir@%$localstatedir%g
-s%@libdir@%$libdir%g
-s%@includedir@%$includedir%g
-s%@oldincludedir@%$oldincludedir%g
-s%@infodir@%$infodir%g
-s%@mandir@%$mandir%g
-s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
-s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
-s%@INSTALL_DATA@%$INSTALL_DATA%g
-s%@PACKAGE@%$PACKAGE%g
-s%@VERSION@%$VERSION%g
-s%@ACLOCAL@%$ACLOCAL%g
-s%@AUTOCONF@%$AUTOCONF%g
-s%@AUTOMAKE@%$AUTOMAKE%g
-s%@AUTOHEADER@%$AUTOHEADER%g
-s%@MAKEINFO@%$MAKEINFO%g
-s%@AMTAR@%$AMTAR%g
-s%@install_sh@%$install_sh%g
-s%@INSTALL_STRIP_PROGRAM@%$INSTALL_STRIP_PROGRAM%g
-s%@AWK@%$AWK%g
-s%@SET_MAKE@%$SET_MAKE%g
-s%@AMDEP_TRUE@%$AMDEP_TRUE%g
-s%@AMDEP_FALSE@%$AMDEP_FALSE%g
-s%@AMDEPBACKSLASH@%$AMDEPBACKSLASH%g
-s%@DEPDIR@%$DEPDIR%g
-s%@host@%$host%g
-s%@host_alias@%$host_alias%g
-s%@host_cpu@%$host_cpu%g
-s%@host_vendor@%$host_vendor%g
-s%@host_os@%$host_os%g
-s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
-s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
-s%@MAINT@%$MAINT%g
-s%@PERL@%$PERL%g
-s%@build@%$build%g
-s%@build_alias@%$build_alias%g
-s%@build_cpu@%$build_cpu%g
-s%@build_vendor@%$build_vendor%g
-s%@build_os@%$build_os%g
-s%@CC@%$CC%g
-s%@CPP@%$CPP%g
-s%@_am_include@%$_am_include%g
-s%@_am_quote@%$_am_quote%g
-s%@CCDEPMODE@%$CCDEPMODE%g
-s%@AS@%$AS%g
-s%@RANLIB@%$RANLIB%g
-s%@STAGE1_CFLAGS@%$STAGE1_CFLAGS%g
-s%@STAGE2_CFLAGS@%$STAGE2_CFLAGS%g
-s%@GRUB_CFLAGS@%$GRUB_CFLAGS%g
-s%@OBJCOPY@%$OBJCOPY%g
-s%@GRUB_LIBS@%$GRUB_LIBS%g
-s%@NETBOOT_SUPPORT_TRUE@%$NETBOOT_SUPPORT_TRUE%g
-s%@NETBOOT_SUPPORT_FALSE@%$NETBOOT_SUPPORT_FALSE%g
-s%@DISKLESS_SUPPORT_TRUE@%$DISKLESS_SUPPORT_TRUE%g
-s%@DISKLESS_SUPPORT_FALSE@%$DISKLESS_SUPPORT_FALSE%g
-s%@HERCULES_SUPPORT_TRUE@%$HERCULES_SUPPORT_TRUE%g
-s%@HERCULES_SUPPORT_FALSE@%$HERCULES_SUPPORT_FALSE%g
-s%@SERIAL_SUPPORT_TRUE@%$SERIAL_SUPPORT_TRUE%g
-s%@SERIAL_SUPPORT_FALSE@%$SERIAL_SUPPORT_FALSE%g
-s%@SERIAL_SPEED_SIMULATION_TRUE@%$SERIAL_SPEED_SIMULATION_TRUE%g
-s%@SERIAL_SPEED_SIMULATION_FALSE@%$SERIAL_SPEED_SIMULATION_FALSE%g
-s%@BUILD_EXAMPLE_KERNEL_TRUE@%$BUILD_EXAMPLE_KERNEL_TRUE%g
-s%@BUILD_EXAMPLE_KERNEL_FALSE@%$BUILD_EXAMPLE_KERNEL_FALSE%g
-s%@FSYS_CFLAGS@%$FSYS_CFLAGS%g
-s%@NET_CFLAGS@%$NET_CFLAGS%g
-s%@NET_EXTRAFLAGS@%$NET_EXTRAFLAGS%g
-s%@NETBOOT_DRIVERS@%$NETBOOT_DRIVERS%g
-s%@ASFLAGS@%$ASFLAGS%g
-
-CEOF
-EOF
-
-cat >> $CONFIG_STATUS <<\EOF
-
-# Split the substitutions into bite-sized pieces for seds with
-# small command number limits, like on Digital OSF/1 and HP-UX.
-ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
-ac_file=1 # Number of current file.
-ac_beg=1 # First line for current file.
-ac_end=$ac_max_sed_cmds # Line after last line for current file.
-ac_more_lines=:
-ac_sed_cmds=""
-while $ac_more_lines; do
- if test $ac_beg -gt 1; then
- sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
- else
- sed "${ac_end}q" conftest.subs > conftest.s$ac_file
- fi
- if test ! -s conftest.s$ac_file; then
- ac_more_lines=false
- rm -f conftest.s$ac_file
- else
- if test -z "$ac_sed_cmds"; then
- ac_sed_cmds="sed -f conftest.s$ac_file"
- else
- ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
- fi
- ac_file=`expr $ac_file + 1`
- ac_beg=$ac_end
- ac_end=`expr $ac_end + $ac_max_sed_cmds`
- fi
-done
-if test -z "$ac_sed_cmds"; then
- ac_sed_cmds=cat
-fi
-EOF
-
-cat >> $CONFIG_STATUS <<EOF
-
-CONFIG_FILES=\${CONFIG_FILES-"Makefile stage1/Makefile stage2/Makefile docs/Makefile \
- lib/Makefile util/Makefile grub/Makefile \
- netboot/Makefile util/grub-image util/grub-install \
- util/grub-md5-crypt"}
-EOF
-cat >> $CONFIG_STATUS <<\EOF
-for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
- # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
- case "$ac_file" in
- *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
- ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- *) ac_file_in="${ac_file}.in" ;;
- esac
-
- # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
-
- # Remove last slash and all that follows it. Not all systems have dirname.
- ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
- if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
- # The file is in a subdirectory.
- test ! -d "$ac_dir" && mkdir "$ac_dir"
- ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
- # A "../" for each directory in $ac_dir_suffix.
- ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
- else
- ac_dir_suffix= ac_dots=
- fi
-
- case "$ac_given_srcdir" in
- .) srcdir=.
- if test -z "$ac_dots"; then top_srcdir=.
- else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
- /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
- *) # Relative path.
- srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
- top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
-
- case "$ac_given_INSTALL" in
- [/$]*) INSTALL="$ac_given_INSTALL" ;;
- *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
- esac
-
- echo creating "$ac_file"
- rm -f "$ac_file"
- configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
- case "$ac_file" in
- *Makefile*) ac_comsub="1i\\
-# $configure_input" ;;
- *) ac_comsub= ;;
- esac
-
- ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
- sed -e "$ac_comsub
-s%@configure_input@%$configure_input%g
-s%@srcdir@%$srcdir%g
-s%@top_srcdir@%$top_srcdir%g
-s%@INSTALL@%$INSTALL%g
-" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
-fi; done
-rm -f conftest.s*
-
-# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
-# NAME is the cpp macro being defined and VALUE is the value it is being given.
-#
-# ac_d sets the value in "#define NAME VALUE" lines.
-ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
-ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
-ac_dC='\3'
-ac_dD='%g'
-# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
-ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
-ac_uB='\([ ]\)%\1#\2define\3'
-ac_uC=' '
-ac_uD='\4%g'
-# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
-ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
-ac_eB='$%\1#\2define\3'
-ac_eC=' '
-ac_eD='%g'
-
-if test "${CONFIG_HEADERS+set}" != set; then
-EOF
-cat >> $CONFIG_STATUS <<EOF
- CONFIG_HEADERS="config.h"
-EOF
-cat >> $CONFIG_STATUS <<\EOF
-fi
-for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
- # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
- case "$ac_file" in
- *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
- ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- *) ac_file_in="${ac_file}.in" ;;
- esac
-
- echo creating $ac_file
-
- rm -f conftest.frag conftest.in conftest.out
- ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
- cat $ac_file_inputs > conftest.in
-
-EOF
-
-# Transform confdefs.h into a sed script conftest.vals that substitutes
-# the proper values into config.h.in to produce config.h. And first:
-# Protect against being on the right side of a sed subst in config.status.
-# Protect against being in an unquoted here document in config.status.
-rm -f conftest.vals
-cat > conftest.hdr <<\EOF
-s/[\\&%]/\\&/g
-s%[\\$`]%\\&%g
-s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
-s%ac_d%ac_u%gp
-s%ac_u%ac_e%gp
-EOF
-sed -n -f conftest.hdr confdefs.h > conftest.vals
-rm -f conftest.hdr
-
-# This sed command replaces #undef with comments. This is necessary, for
-# example, in the case of _POSIX_SOURCE, which is predefined and required
-# on some systems where configure will not decide to define it.
-cat >> conftest.vals <<\EOF
-s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
-EOF
-
-# Break up conftest.vals because some shells have a limit on
-# the size of here documents, and old seds have small limits too.
-
-rm -f conftest.tail
-while :
-do
- ac_lines=`grep -c . conftest.vals`
- # grep -c gives empty output for an empty file on some AIX systems.
- if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
- # Write a limited-size here document to conftest.frag.
- echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
- sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
- echo 'CEOF
- sed -f conftest.frag conftest.in > conftest.out
- rm -f conftest.in
- mv conftest.out conftest.in
-' >> $CONFIG_STATUS
- sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
- rm -f conftest.vals
- mv conftest.tail conftest.vals
-done
-rm -f conftest.vals
-
-cat >> $CONFIG_STATUS <<\EOF
- rm -f conftest.frag conftest.h
- echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
- cat conftest.in >> conftest.h
- rm -f conftest.in
- if cmp -s $ac_file conftest.h 2>/dev/null; then
- echo "$ac_file is unchanged"
- rm -f conftest.h
- else
- # Remove last slash and all that follows it. Not all systems have dirname.
- ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
- if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
- # The file is in a subdirectory.
- test ! -d "$ac_dir" && mkdir "$ac_dir"
- fi
- rm -f $ac_file
- mv conftest.h $ac_file
- fi
-fi; done
-
-EOF
-cat >> $CONFIG_STATUS <<EOF
-am_indx=1
- for am_file in config.h; do
- case " $CONFIG_HEADERS " in
- *" $am_file "*)
- echo timestamp > `echo $am_file | sed 's%:.*%%;s%[^/]*$%%'`stamp-h$am_indx
- ;;
- esac
- am_indx=\`expr \$am_indx + 1\`
- done
-AMDEP_TRUE="$AMDEP_TRUE"
-ac_aux_dir="$ac_aux_dir"
-
-EOF
-cat >> $CONFIG_STATUS <<\EOF
-test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
-
-test x"$AMDEP_TRUE" != x"" ||
-for mf in $CONFIG_FILES; do
- case "$mf" in
- Makefile) dirpart=.;;
- */Makefile) dirpart=`echo "$mf" | sed -e 's|/[^/]*$||'`;;
- *) continue;;
- esac
- grep '^DEP_FILES *= *[^ #]' < "$mf" > /dev/null || continue
- # Extract the definition of DEP_FILES from the Makefile without
- # running `make'.
- DEPDIR=`sed -n -e '/^DEPDIR = / s///p' < "$mf"`
- test -z "$DEPDIR" && continue
- # When using ansi2knr, U may be empty or an underscore; expand it
- U=`sed -n -e '/^U = / s///p' < "$mf"`
- test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR"
- # We invoke sed twice because it is the simplest approach to
- # changing $(DEPDIR) to its actual value in the expansion.
- for file in `sed -n -e '
- /^DEP_FILES = .*\\\\$/ {
- s/^DEP_FILES = //
- :loop
- s/\\\\$//
- p
- n
- /\\\\$/ b loop
- p
- }
- /^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \
- sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
- # Make sure the directory exists.
- test -f "$dirpart/$file" && continue
- fdir=`echo "$file" | sed -e 's|/[^/]*$||'`
- $ac_aux_dir/mkinstalldirs "$dirpart/$fdir" > /dev/null 2>&1
- # echo "creating $dirpart/$file"
- echo '# dummy' > "$dirpart/$file"
- done
-done
-
-
-exit 0
-EOF
-chmod +x $CONFIG_STATUS
-rm -fr confdefs* $ac_clean_files
-test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
-
diff --git a/sys-apps/grub/files/grub-0.90/grub-0.5.96.1-dont-give-mem-to-kernel.patch b/sys-apps/grub/files/grub-0.90/grub-0.5.96.1-dont-give-mem-to-kernel.patch
deleted file mode 100644
index dd3a60d12835..000000000000
--- a/sys-apps/grub/files/grub-0.90/grub-0.5.96.1-dont-give-mem-to-kernel.patch
+++ /dev/null
@@ -1,30 +0,0 @@
---- grub-0.5.96.1/stage2/boot.c.pix Mon Oct 16 16:42:08 2000
-+++ grub-0.5.96.1/stage2/boot.c Fri Feb 23 16:40:29 2001
-@@ -322,7 +322,18 @@
-
- while (((int) dest) < CL_MY_END_ADDR && *src)
- *(dest++) = *(src++);
--
-+
-+/* don't add ``mem='' for 2.4 kernels :
-+
-+Newer machines have several regions of reserved memory outside and
-+inside these regions. grub's actions are suicide on newer laptops,
-+and machines like servers with lots of memory. Laptops have special
-+sections of memory above 1MB which must be reserved... Ditto for
-+ACPI tables. Using mem=XXX completely eliminates any information
-+that the BIOS has provided to the OS.
-+
-+*/
-+#if 0
- /* Add a mem option automatically only if the user doesn't
- specify it explicitly. */
- if (! grub_strstr (arg, "mem=")
-@@ -337,6 +348,7 @@
- dest = convert_to_ascii (dest, 'u', (extended_memory + 0x400));
- *(dest++) = 'K';
- }
-+#endif
-
- *dest = 0;
- }
diff --git a/sys-apps/grub/files/grub-0.90/grub-0.5.96.1-special-raid-devices.patch b/sys-apps/grub/files/grub-0.90/grub-0.5.96.1-special-raid-devices.patch
deleted file mode 100644
index 15176e7c19da..000000000000
--- a/sys-apps/grub/files/grub-0.90/grub-0.5.96.1-special-raid-devices.patch
+++ /dev/null
@@ -1,17 +0,0 @@
---- grub-0.5.96.1/lib/device.c.pix Mon Oct 16 16:41:54 2000
-+++ grub-0.5.96.1/lib/device.c Tue Apr 3 12:01:41 2001
-@@ -616,7 +616,13 @@
- if (strcmp (dev + strlen(dev) - 5, "/disc") == 0)
- strcat (dev + strlen(dev) - 5, "/part");
- }
-- sprintf (dev + strlen(dev), "%d", ((partition >> 16) & 0xFF) + 1);
-+
-+ sprintf (dev + strlen(dev), "%s%d",
-+ /* Compaq smart and others */
-+ (strncmp(dev, "/dev/ida/", 9) == 0 ||
-+ strncmp(dev, "/dev/cciss/", 11) == 0 ||
-+ strncmp(dev, "/dev/rd/", 8) == 0) ? "p" : "",
-+ ((partition >> 16) & 0xFF) + 1);
-
- /* Open the partition. */
- fd = open (dev, O_RDWR);
diff --git a/sys-apps/grub/files/grub-0.90/grub-0.5.97-vga16.patch b/sys-apps/grub/files/grub-0.90/grub-0.5.97-vga16.patch
deleted file mode 100644
index ab5455fdff92..000000000000
--- a/sys-apps/grub/files/grub-0.90/grub-0.5.97-vga16.patch
+++ /dev/null
@@ -1,2066 +0,0 @@
-diff -ur grub.bak/ChangeLog grub/ChangeLog
---- grub.bak/ChangeLog Thu Jun 21 22:32:55 2001
-+++ grub/ChangeLog Sun Jun 24 23:44:19 2001
-@@ -1331,6 +1331,18 @@
- [!STAGE1_5] (CMDLINE_WIDTH): New macro.
- [!STAGE1_5] (CMDLINE_MARGIN): Likewise.
- * stage2/shared.h (TERMINAL_DUMB): Likewise.
-+
-+2000-08-29 Paulo César Pereira de Andrade <pcpa@conectiva.com.br>
-+
-+ * configure.in: Added --disable-vga16 option, in case user does not
-+ want the new VGA graphics interface.
-+ * stage2/asm.S: Added some new functions, for graphics operations,
-+ and renamed several functions to allow wrapping them.
-+ * stage2/stage2.c: Main changes for VGA16 support.
-+ * stage2/char_io.c: Modified calls of grub_putchar to putchar
-+ * stage2/disk_io.c: Same as for char_io.c
-+ * stage2/cmdline.c: Also, the same as for char_io.c
-+ * stage2/shared.h: Definitions for externs and wrapping functions.
-
- 2000-08-28 OKUJI Yoshinori <okuji@gnu.org>
-
-Only in grub: ChangeLog.vga16
-diff -ur grub.bak/configure.in grub/configure.in
---- grub.bak/configure.in Thu Jun 21 22:32:56 2001
-+++ grub/configure.in Sun Jun 24 23:44:19 2001
-@@ -18,6 +18,7 @@
- AC_PREREQ(2.13)
-
- AC_CANONICAL_HOST
-+AM_PROG_LIBTOOL
-
- case "$host_cpu" in
- i[[3456]]86) host_cpu=i386 ;;
-@@ -564,6 +565,12 @@
- AC_SUBST(NET_EXTRAFLAGS)
- AC_SUBST(NETBOOT_DRIVERS)
-
-+AC_ARG_ENABLE(vga16,
-+ [ --disable-vga16 disable VGA graphics interface])
-+
-+if test x"$enable_vga16" != xno; then
-+ STAGE2_CFLAGS="$STAGE2_CFLAGS -DVGA16=1"
-+fi
-
- dnl Output.
- AC_OUTPUT([Makefile stage1/Makefile stage2/Makefile docs/Makefile \
-Only in grub: configure.in.vga16
-diff -ur grub.bak/stage2/asm.S grub/stage2/asm.S
---- grub.bak/stage2/asm.S Tue Feb 27 07:59:00 2001
-+++ grub/stage2/asm.S Sun Jun 24 23:44:19 2001
-@@ -1857,7 +1857,7 @@
- * %cl = cursor ending scanline
- */
-
--ENTRY(nocursor)
-+ENTRY(grub_nocursor)
- push %ebp
- push %ebx /* save EBX */
-
-@@ -1943,7 +1943,7 @@
-
-
- /*
-- * console_set_attrib(attr) : Sets the character attributes for character at
-+ * grub_set_attrib(attr) : Sets the character attributes for character at
- * current cursor position.
- *
- * Bitfields for character's display attribute:
-@@ -1977,7 +1977,7 @@
- * %cx = count to display (???, possible side-effects!!)
- */
-
--ENTRY(console_set_attrib)
-+ENTRY(grub_set_attrib)
- push %ebp
- push %ebx
-
-@@ -2001,6 +2001,263 @@
- pop %ebp
- ret
-
-+#ifdef VGA16
-+VARIABLE(cursorX)
-+.word 0
-+VARIABLE(cursorY)
-+.word 0
-+VARIABLE(cursorWidth)
-+.word 0
-+VARIABLE(cursorHeight)
-+.word 0
-+VARIABLE(cursorCount)
-+.word 0
-+VARIABLE(cursorBuf)
-+.byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
-+
-+/*
-+ * set_int1c_handler(void)
-+ */
-+ENTRY(set_int1c_handler)
-+ pushl %edi
-+
-+ /* save the original int1c handler */
-+ movl $0x70, %edi
-+ movw (%edi), %ax
-+ movw %ax, ABS(int1c_offset)
-+ movw 2(%edi), %ax
-+ movw %ax, ABS(int1c_segment)
-+
-+ /* save the new int1c handler */
-+ movw $ABS(int1c_handler), %ax
-+ movw %ax, (%edi)
-+ xorw %ax, %ax
-+ movw %ax, 2(%edi)
-+
-+ popl %edi
-+ ret
-+
-+
-+/*
-+ * unset_int1c_handler(void)
-+ */
-+ENTRY(unset_int1c_handler)
-+ pushl %edi
-+
-+ /* check if int1c_handler is set */
-+ movl $0x70, %edi
-+ movw $ABS(int1c_handler), %ax
-+ cmpw %ax, (%edi)
-+ jne int1c_1
-+ xorw %ax, %ax
-+ cmpw %ax, 2(%edi)
-+ jne int1c_1
-+
-+ /* restore the original */
-+ movw ABS(int1c_offset), %ax
-+ movw %ax, (%edi)
-+ movw ABS(int1c_segment), %ax
-+ movw %ax, 2(%edi)
-+
-+int1c_1:
-+ popl %edi
-+ ret
-+
-+/*
-+ * blinks graphics cursor
-+ */
-+ .code16
-+write_data:
-+ movw $0, %ax
-+ movw %ax, %ds
-+
-+ mov $0xA000, %ax /* video in es:di */
-+ mov %ax, %es
-+ mov $80, %ax
-+ movw $ABS(cursorY), %si
-+ mov %ds:(%si), %bx
-+ mul %bx
-+ movw $ABS(cursorX), %si
-+ mov %ds:(%si), %bx
-+ shr $3, %bx /* %bx /= 8 */
-+ add %bx, %ax
-+ mov %ax, %di
-+
-+ movw $ABS(cursorBuf), %si /* fontBuf in ds:si */
-+
-+ /* prepare for data moving */
-+ mov $16, %dx /* altura da fonte */
-+ mov $80, %bx /* bytes por linha */
-+
-+write_loop:
-+ movb %ds:(%si), %al
-+ xorb $0xff, %al
-+ movb %al, %ds:(%si) /* invert cursorBuf */
-+ movb %al, %es:(%di) /* write to video */
-+ add %bx, %di
-+ inc %si
-+ dec %dx
-+ jg write_loop
-+ ret
-+
-+int1c_handler:
-+ pusha
-+ mov $0, %ax
-+ mov %ax, %ds
-+ mov $ABS(cursorCount), %si
-+ mov %ds:(%si), %ax
-+ inc %ax
-+ mov %ax, %ds:(%si)
-+ cmp $9, %ax
-+ jne int1c_done
-+
-+ mov $0, %ax
-+ mov %ax, %ds:(%si)
-+/*
-+ movw $0x3c4, %dx
-+ movb $0x020f, %ax
-+ outw %ax, %dx
-+*/
-+ call write_data
-+
-+int1c_done:
-+ popa
-+ iret
-+ /* call previous int1c handler */
-+ /* ljmp */
-+ .byte 0xea
-+int1c_offset: .word 0
-+int1c_segment: .word 0
-+ .code32
-+
-+
-+ENTRY(get_font)
-+ push %ebp
-+ push %ebx
-+ push %ecx
-+ push %edx
-+
-+ call EXT_C(prot_to_real)
-+ .code16
-+
-+ movw $0x1130, %ax
-+ movb $6, %bh /* font 8x16 */
-+ int $0x10
-+ movw %bp, %dx
-+ movw %es, %cx
-+
-+ DATA32 call EXT_C(real_to_prot)
-+ .code32
-+
-+ xorl %eax, %eax
-+ movw %cx, %ax
-+ shll $4, %eax
-+ movw %dx, %ax
-+
-+ pop %edx
-+ pop %ecx
-+ pop %ebx
-+ pop %ebp
-+ ret
-+
-+/*
-+ * set_videomode(mode)
-+ * BIOS call "INT 10H Function 0h" to set video mode
-+ * Call with %ah = 0x0
-+ * %al = video mode
-+ */
-+ENTRY(set_videomode)
-+ push %ebp
-+ push %ebx
-+ push %ecx
-+
-+ movb 0x10(%esp), %cl
-+
-+ call EXT_C(prot_to_real)
-+ .code16
-+
-+ xorw %bx, %bx
-+ movb $0xf, %ah
-+ int $0x10 /* Get Current Video mode */
-+ movb %al, %ch
-+ xorb %ah, %ah
-+ movb %cl, %al
-+ int $0x10 /* Set Video mode */
-+
-+ DATA32 call EXT_C(real_to_prot)
-+ .code32
-+
-+ xorb %ah, %ah
-+ movb %ch, %al
-+
-+ pop %ecx
-+ pop %ebx
-+ pop %ebp
-+ ret
-+
-+/*
-+ * set_palette(index, red, green, blue)
-+ * BIOS call "INT 10H Function 10h" to set individual dac register
-+ * Call with %ah = 0x10
-+ * %bx = register number
-+ * %ch = new value for green (0-63)
-+ * %cl = new value for blue (0-63)
-+ * %dh = new value for red (0-63)
-+ */
-+
-+ENTRY(set_palette)
-+ push %ebp
-+ push %eax
-+ push %ebx
-+ push %ecx
-+ push %edx
-+
-+ movw $0x3c8, %bx /* address write mode register */
-+
-+ /* wait vertical retrace */
-+
-+ movw $0x3da, %dx
-+l1b: inb %dx, %al /* wait vertical active display */
-+ test $8, %al
-+ jnz l1b
-+
-+l2b: inb %dx, %al /* wait vertical retrace */
-+ test $8, %al
-+ jnz l2b
-+
-+ mov %bx, %dx
-+ movb 0x18(%esp), %al /* index */
-+ outb %al, %dx
-+ inc %dx
-+
-+ movb 0x1c(%esp), %al /* red */
-+ outb %al, %dx
-+
-+ movb 0x20(%esp), %al /* green */
-+ outb %al, %dx
-+
-+ movb 0x24(%esp), %al /* blue */
-+ outb %al, %dx
-+
-+ movw 0x18(%esp), %bx
-+
-+ call EXT_C(prot_to_real)
-+ .code16
-+
-+ movb %bl, %bh
-+ movw $0x1000, %ax
-+ int $0x10
-+
-+ DATA32 call EXT_C(real_to_prot)
-+ .code32
-+
-+ pop %edx
-+ pop %ecx
-+ pop %ebx
-+ pop %eax
-+ pop %ebp
-+ ret
-+#endif
-
- /*
- * getrtsecs()
-Only in grub/stage2: asm.S.vga16
-diff -ur grub.bak/stage2/builtins.c grub/stage2/builtins.c
---- grub.bak/stage2/builtins.c Thu Jun 21 19:15:02 2001
-+++ grub/stage2/builtins.c Sun Jun 24 23:44:19 2001
-@@ -133,6 +133,36 @@
- grub_printf ("[%d,%d,%d]", sector, offset, length);
- }
-
-+#ifdef VGA16
-+/* background */
-+static int
-+background_func(char *arg, int flags)
-+{
-+ if (grub_strlen(arg) == 6) {
-+ int r = ((hex(arg[0]) << 4) | hex(arg[1])) >> 2;
-+ int g = ((hex(arg[2]) << 4) | hex(arg[3])) >> 2;
-+ int b = ((hex(arg[4]) << 4) | hex(arg[5])) >> 2;
-+
-+ background = (r << 16) | (g << 8) | b;
-+ if (vga_inited)
-+ set_palette(0, r, g, b);
-+ return (0);
-+ }
-+
-+ return (1);
-+}
-+
-+static struct builtin builtin_background =
-+{
-+ "background",
-+ background_func,
-+ BUILTIN_CMDLINE | BUILTIN_MENU,
-+ "background RRGGBB",
-+ "Sets the background color when in graphics mode."
-+ "RR is red, GG is green, and BB blue. Numbers must be in hexadecimal."
-+};
-+#endif /* VGA16 */
-+
-
- /* blocklist */
- static int
-@@ -394,6 +424,40 @@
- #endif /* SUPPORT_NETBOOT */
-
-
-+#ifdef VGA16
-+
-+/* foreground */
-+static int
-+border_func(char *arg, int flags)
-+{
-+ if (grub_strlen(arg) == 6) {
-+ int r = ((hex(arg[0]) << 4) | hex(arg[1])) >> 2;
-+ int g = ((hex(arg[2]) << 4) | hex(arg[3])) >> 2;
-+ int b = ((hex(arg[4]) << 4) | hex(arg[5])) >> 2;
-+
-+ border = (r << 16) | (g << 8) | b;
-+ if (vga_inited)
-+ set_palette(0x11, r, g, b);
-+
-+ return (0);
-+ }
-+
-+ return (1);
-+}
-+
-+static struct builtin builtin_border =
-+{
-+ "border",
-+ border_func,
-+ BUILTIN_CMDLINE | BUILTIN_MENU,
-+ "border RRGGBB",
-+ "Sets the border video color when in graphics mode."
-+ "RR is red, GG is green, and BB blue. Numbers must be in hexadecimal."
-+};
-+
-+#endif /* VGA16 */
-+
-+
- /* cat */
- static int
- cat_func (char *arg, int flags)
-@@ -404,7 +468,7 @@
- return 1;
-
- while (grub_read (&c, 1))
-- grub_putchar (c);
-+ putchar (c);
-
- grub_close ();
- return 0;
-@@ -958,6 +1022,44 @@
- return 0;
- }
-
-+
-+#ifdef VGA16
-+/* display */
-+static int
-+display_func(char *arg, int flags)
-+{
-+ int i;
-+
-+ for (i = 0; i < MAX_DISPLAYS; i++) {
-+ if (grub_strcmp(arg, display_entries[i].name) == 0)
-+ break;
-+ }
-+
-+ if (i >= MAX_DISPLAYS)
-+ return (1);
-+
-+ display_idx = i;
-+ if (display->End)
-+ (*display->End)();
-+ display = &display_entries[display_idx];
-+
-+ /* Restart cmain */
-+ grub_longjmp (restart_env, 0);
-+ /*NOTREACHED*/
-+
-+ return (0);
-+}
-+
-+static struct builtin builtin_display =
-+{
-+ "display",
-+ display_func,
-+ BUILTIN_CMDLINE,
-+ "display MODEL",
-+ "Changes display type. Available modes are \"text\" and \"vga16\"."
-+};
-+#endif /* VGA16 */
-+
- static struct builtin builtin_displaymem =
- {
- "displaymem",
-@@ -1233,6 +1335,39 @@
- " the devices which contain the file."
- };
-
-+#ifdef VGA16
-+
-+/* foreground */
-+static int
-+foreground_func(char *arg, int flags)
-+{
-+ if (grub_strlen(arg) == 6) {
-+ int r = ((hex(arg[0]) << 4) | hex(arg[1])) >> 2;
-+ int g = ((hex(arg[2]) << 4) | hex(arg[3])) >> 2;
-+ int b = ((hex(arg[4]) << 4) | hex(arg[5])) >> 2;
-+
-+ foreground = (r << 16) | (g << 8) | b;
-+ if (vga_inited)
-+ set_palette(15, r, g, b);
-+
-+ return (0);
-+ }
-+
-+ return (1);
-+}
-+
-+static struct builtin builtin_foreground =
-+{
-+ "foreground",
-+ foreground_func,
-+ BUILTIN_CMDLINE | BUILTIN_MENU,
-+ "foreground RRGGBB",
-+ "Sets the foreground color when in graphics mode."
-+ "RR is red, GG is green, and BB blue. Numbers must be in hexadecimal."
-+};
-+
-+#endif /* VGA16 */
-+
-
- /* fstest */
- static int
-@@ -1385,12 +1520,13 @@
-
-
- /* help */
--#define MAX_SHORT_DOC_LEN 39
--#define MAX_LONG_DOC_LEN 66
-
- static int
- help_func (char *arg, int flags)
- {
-+ int MAX_SHORT_DOC_LEN = (view_x1 - view_x0 + 1) / 2 - 1;
-+ int MAX_LONG_DOC_LEN = (view_x1 - view_x0) - 14;
-+
- if (! *arg)
- {
- /* Invoked with no argument. Print the list of the short docs. */
-@@ -1413,13 +1549,13 @@
- len = MAX_SHORT_DOC_LEN - 1;
-
- for (i = 0; i < len; i++)
-- grub_putchar ((*builtin)->short_doc[i]);
-+ putchar ((*builtin)->short_doc[i]);
-
- for (; i < MAX_SHORT_DOC_LEN; i++)
-- grub_putchar (' ');
-+ putchar (' ');
-
- if (! left)
-- grub_putchar ('\n');
-+ putchar ('\n');
-
- left = ! left;
- }
-@@ -1469,8 +1605,8 @@
-
- grub_printf (" ");
- for (i = 0; i < len; i++)
-- grub_putchar (*doc++);
-- grub_putchar ('\n');
-+ putchar (*doc++);
-+ putchar ('\n');
- }
- }
- }
-@@ -3144,6 +3280,74 @@
- "Save the current entry as the default boot entry."
- };
-
-+#ifdef VGA16
-+/*splashimage*/
-+static int
-+splashimage_func(char *arg, int flags)
-+{
-+ if (strlen(arg) > 63)
-+ return (1);
-+ if (flags == BUILTIN_CMDLINE) {
-+ if (!grub_open(arg))
-+ return (1);
-+ grub_close();
-+ }
-+
-+ if (flags == BUILTIN_CMDLINE || !splash_set) {
-+ strcpy(splashimage, arg);
-+ splash_set = 1;
-+ }
-+
-+ if (flags == BUILTIN_CMDLINE && vga_inited) {
-+ display->End();
-+ display->Begin();
-+ cls();
-+/* grub_longjmp(restart_env, 0);*/
-+ }
-+
-+ return (0);
-+}
-+
-+static struct builtin builtin_splashimage =
-+{
-+ "splashimage",
-+ splashimage_func,
-+ BUILTIN_CMDLINE | BUILTIN_MENU,
-+ "splashimage FILE",
-+ "Load FILE as the background image when in graphics mode."
-+};
-+
-+/*shade*/
-+static int
-+shade_func(char *arg, int flags)
-+{
-+ int new_shade;
-+
-+ if (!arg || safe_parse_maxint(&arg, &new_shade) == 0)
-+ return (1);
-+
-+ if (shade != new_shade) {
-+ shade = new_shade;
-+ if (flags == BUILTIN_CMDLINE && vga_inited) {
-+ display->End();
-+ display->Begin();
-+ cls();
-+ }
-+ }
-+
-+ return (0);
-+}
-+
-+static struct builtin builtin_shade =
-+{
-+ "shade",
-+ shade_func,
-+ BUILTIN_CMDLINE | BUILTIN_MENU,
-+ "shade INTEGER",
-+ "If set to 0, disables the use of shaded text, else enables it."
-+};
-+#endif /* VGA16 */
-+
-
- #ifdef SUPPORT_SERIAL
- /* serial */
-@@ -4420,16 +4624,79 @@
- "Probe VBE information. If the mode number MODE is specified, show only"
- "the information about only the mode."
- };
--
-+
-+#ifdef VGA16
-
-+/* viewport */
-+static int
-+viewport_func (char *arg, int flags)
-+{
-+ int i;
-+ int x0 = 80, y0 = 25, x1 = 0, y1 = 0;
-+ int *pos[4] = { &x0, &y0, &x1, &y1 };
-+ extern int viewport_set;
-+
-+ if (!arg)
-+ return (1);
-+ for (i = 0; i < 4; i++) {
-+ if (!*arg)
-+ return (1);
-+ while (*arg && (*arg == ' ' || *arg == '\t'))
-+ ++arg;
-+ if (!safe_parse_maxint(&arg, pos[i]))
-+ return (1);
-+ while (*arg && (*arg != ' ' && *arg != '\t'))
-+ ++arg;
-+ }
-+
-+ x1 += x0;
-+ y1 += y0;
-+
-+ /* minimum size is 60 colums and 16 rows */
-+ if (x0 > x1 - 60 || y0 > y1 - 16 || x0 < 0 || y0 < 0 || x1 > 80 || y1 > 30)
-+ return (1);
-+
-+ viewport_set = 1;
-+ view_x0 = x0;
-+ view_y0 = y0;
-+ view_x1 = x1;
-+ view_y1 = y1;
-+
-+ if (flags == BUILTIN_CMDLINE && vga_inited) {
-+ display->End();
-+ display->Begin();
-+ cls();
-+ }
-+
-+ return (0);
-+}
-+
-+static struct builtin builtin_viewport =
-+{
-+ "viewport",
-+ viewport_func,
-+ BUILTIN_CMDLINE | BUILTIN_MENU,
-+ "viewport x y width height",
-+ "Changes grub internals to output text in the window defined by"
-+ " four parameters. The x and y parameters are 0 based. This option"
-+ " only works with the vga interface."
-+};
-+#endif /* VGA16 */
-+
- /* The table of builtin commands. Sorted in dictionary order. */
- struct builtin *builtin_table[] =
- {
-+#ifdef VGA16
-+ &builtin_background,
-+#endif /* VGA16 */
- &builtin_blocklist,
- &builtin_boot,
- #ifdef SUPPORT_NETBOOT
- &builtin_bootp,
- #endif /* SUPPORT_NETBOOT */
-+#ifdef VGA16
-+ &builtin_border,
-+#endif /* VGA16 */
- &builtin_cat,
- &builtin_chainloader,
- &builtin_cmp,
-@@ -4443,11 +4710,17 @@
- #ifdef SUPPORT_NETBOOT
- &builtin_dhcp,
- #endif /* SUPPORT_NETBOOT */
-+#ifdef VGA16
-+ &builtin_display,
-+#endif /* VGA16 */
- &builtin_displayapm,
- &builtin_displaymem,
- &builtin_embed,
- &builtin_fallback,
- &builtin_find,
-+#ifdef VGA16
-+ &builtin_foreground,
-+#endif /* VGA16 */
- &builtin_fstest,
- &builtin_geometry,
- &builtin_halt,
-@@ -4490,6 +4763,10 @@
- #endif /* SUPPORT_SERIAL */
- &builtin_setkey,
- &builtin_setup,
-+#ifdef VGA16
-+ &builtin_shade,
-+ &builtin_splashimage,
-+#endif /* VGA16 */
- #if defined(SUPPORT_SERIAL) || defined(SUPPORT_HERCULES)
- &builtin_terminal,
- #endif /* SUPPORT_SERIAL || SUPPORT_HERCULES */
-@@ -4503,5 +4780,8 @@
- &builtin_unhide,
- &builtin_uppermem,
- &builtin_vbeprobe,
-+#ifdef VGA16
-+ &builtin_viewport,
-+#endif /* VGA16 */
- 0
- };
-Only in grub/stage2: builtins.c.vga16
-diff -ur grub.bak/stage2/char_io.c grub/stage2/char_io.c
---- grub.bak/stage2/char_io.c Thu Jun 21 22:32:56 2001
-+++ grub/stage2/char_io.c Sun Jun 24 23:44:19 2001
-@@ -263,8 +263,8 @@
-
- /* XXX: These should be defined in shared.h, but I leave these here,
- until this code is freezed. */
--#define CMDLINE_WIDTH 78
--#define CMDLINE_MARGIN 10
-+ int CMDLINE_WIDTH = (view_x1 - view_x0) - 2;
-+ int CMDLINE_MARGIN = 10;
-
- int xpos, lpos, c, section;
- /* The length of PROMPT. */
-@@ -314,7 +314,7 @@
- {
- int y = getxy () & 0xFF;
-
-- gotoxy (xpos, y);
-+ gotoxy (xpos + view_x0, y);
- }
- # ifdef SUPPORT_SERIAL
- else if (! (terminal & TERMINAL_DUMB) && (count > 4))
-@@ -326,7 +326,7 @@
- int i;
-
- for (i = 0; i < count; i++)
-- grub_putchar ('\b');
-+ putchar ('\b');
- }
- # endif /* SUPPORT_SERIAL */
- }
-@@ -352,7 +352,7 @@
- {
- int y = getxy () & 0xFF;
-
-- gotoxy (xpos, y);
-+ gotoxy (xpos + view_x0, y);
- }
- # ifdef SUPPORT_SERIAL
- else if (! (terminal & TERMINAL_DUMB) && (count > 4))
-@@ -366,9 +366,9 @@
- for (i = lpos - count; i < lpos; i++)
- {
- if (! echo_char)
-- grub_putchar (buf[i]);
-+ putchar (buf[i]);
- else
-- grub_putchar (echo_char);
-+ putchar (echo_char);
- }
- }
- # endif /* SUPPORT_SERIAL */
-@@ -395,7 +395,7 @@
- /* From the start to the end. */
- len = CMDLINE_WIDTH;
- pos = 0;
-- grub_putchar ('\r');
-+ putchar ('\r');
-
- /* If SECTION is the first section, print the prompt, otherwise,
- print `<'. */
-@@ -407,7 +407,7 @@
- }
- else
- {
-- grub_putchar ('<');
-+ putchar ('<');
- len--;
- pos++;
- }
-@@ -443,9 +443,9 @@
- for (i = start; i < start + len && i < llen; i++)
- {
- if (! echo_char)
-- grub_putchar (buf[i]);
-+ putchar (buf[i]);
- else
-- grub_putchar (echo_char);
-+ putchar (echo_char);
-
- pos++;
- }
-@@ -453,7 +453,7 @@
- /* Fill up the rest of the line with spaces. */
- for (; i < start + len; i++)
- {
-- grub_putchar (' ');
-+ putchar (' ');
- pos++;
- }
-
-@@ -462,9 +462,9 @@
- if (pos == CMDLINE_WIDTH)
- {
- if (start + len < llen)
-- grub_putchar ('>');
-+ putchar ('>');
- else
-- grub_putchar (' ');
-+ putchar (' ');
-
- pos++;
- }
-@@ -478,7 +478,7 @@
- {
- int y = getxy () & 0xFF;
-
-- gotoxy (xpos, y);
-+ gotoxy (xpos + view_x0, y);
- }
- # ifdef SUPPORT_SERIAL
- else if (! (terminal & TERMINAL_SERIAL) && (pos - xpos > 4))
-@@ -488,7 +488,7 @@
- else
- {
- for (i = 0; i < pos - xpos; i++)
-- grub_putchar ('\b');
-+ putchar ('\b');
- }
- # endif /* SUPPORT_SERIAL */
- }
-@@ -497,7 +497,7 @@
- void cl_init (void)
- {
- /* Distinguish us from other lines and error messages! */
-- grub_putchar ('\n');
-+ putchar ('\n');
-
- /* Print full line and set position here. */
- cl_refresh (1, 0);
-@@ -628,7 +628,7 @@
- /* There are more than one candidates, so print
- the list. */
-
-- grub_putchar ('\n');
-+ putchar ('\n');
- /* Enable the auto fill mode temporarily. */
- auto_fill = 1;
- print_completions (is_filename, 0);
-@@ -770,7 +770,7 @@
- }
- }
-
-- grub_putchar ('\n');
-+ putchar ('\n');
-
- /* If ECHO_CHAR is NUL, remove the leading spaces. */
- lpos = 0;
-@@ -1116,7 +1116,7 @@
- {
- /* Fold a line only if AUTO_FILL is true. */
- if (auto_fill && col >= 79)
-- grub_putchar ('\n');
-+ putchar ('\n');
-
- col++;
- }
-@@ -1139,7 +1139,7 @@
-
- #ifndef STAGE1_5
- void
--gotoxy (int x, int y)
-+grub_gotoxy (int x, int y)
- {
- if (terminal & TERMINAL_CONSOLE)
- console_gotoxy (x, y);
-@@ -1163,7 +1163,7 @@
- #endif /* SUPPORT_SERIAL */
-
- int
--getxy (void)
-+grub_getxy (void)
- {
- int ret = 0;
-
-@@ -1268,7 +1268,7 @@
- #endif /* SUPPORT_SERIAL */
-
- void
--cls (void)
-+grub_cls (void)
- {
- if (terminal & TERMINAL_CONSOLE)
- console_cls ();
-@@ -1289,7 +1289,7 @@
- {
- /* If the terminal is dumb, there is no way to clean the terminal. */
- if (terminal & TERMINAL_DUMB)
-- grub_putchar ('\n');
-+ putchar ('\n');
- else
- grub_printf ("\e[H\e[J");
- }
-Only in grub/stage2: char_io.c.vga16
-diff -ur grub.bak/stage2/cmdline.c grub/stage2/cmdline.c
---- grub.bak/stage2/cmdline.c Tue Oct 17 09:37:27 2000
-+++ grub/stage2/cmdline.c Sun Jun 24 23:44:19 2001
-@@ -126,7 +126,7 @@
- init_page ();
- #ifdef SUPPORT_DISKLESS
- print_network_configuration ();
-- grub_putchar ('\n');
-+ putchar ('\n');
- #endif
- print_cmdline_message (forever);
-
-Only in grub/stage2: cmdline.c.vga16
-diff -ur grub.bak/stage2/disk_io.c grub/stage2/disk_io.c
---- grub.bak/stage2/disk_io.c Thu Jun 21 22:32:56 2001
-+++ grub/stage2/disk_io.c Sun Jun 24 23:44:19 2001
-@@ -1243,7 +1243,7 @@
- }
-
- if (! is_completion)
-- grub_putchar ('\n');
-+ putchar ('\n');
-
- print_error ();
- do_completion = 0;
-@@ -1310,7 +1310,7 @@
- }
-
- if (! is_completion)
-- grub_putchar ('\n');
-+ putchar ('\n');
- }
- else
- {
-@@ -1384,7 +1384,7 @@
- }
-
- if (! is_completion)
-- grub_putchar ('\n');
-+ putchar ('\n');
- }
- else
- errnum = ERR_BAD_FILENAME;
-Only in grub/stage2: disk_io.c.vga16
-diff -ur grub.bak/stage2/shared.h grub/stage2/shared.h
---- grub.bak/stage2/shared.h Thu Jun 21 22:32:56 2001
-+++ grub/stage2/shared.h Sun Jun 24 23:44:43 2001
-@@ -45,6 +45,12 @@
- # define RAW_SEG(x) (x)
- #endif
-
-+#if defined(VGA16)
-+#if defined(GRUB_UTIL) || defined(STAGE1_5)
-+#undef VGA16
-+#endif
-+#endif
-+
- /*
- * Integer sizes
- */
-@@ -362,8 +368,10 @@
- #define isspace grub_isspace
- #define printf grub_printf
- #define sprintf grub_sprintf
-+#ifndef VGA16
- #undef putchar
- #define putchar grub_putchar
-+#endif
- #define strncat grub_strncat
- #define strstr grub_strstr
- #define memcmp grub_memcmp
-@@ -378,6 +386,9 @@
- /*
- * Below this should be ONLY defines and other constructs for C code.
- */
-+#ifdef VGA16
-+#define VIDEO 0xA0000
-+#endif
-
- /* multiboot stuff */
-
-@@ -763,26 +774,26 @@
- int currticks (void);
-
- /* Clear the screen. */
--void cls (void);
-+void grub_cls (void);
-
- /* The console part of cls. */
- void console_cls (void);
-
- #ifndef GRUB_UTIL
- /* Turn off cursor. */
--void nocursor (void);
-+void grub_nocursor (void);
- #endif
-
- /* Get the current cursor position (where 0,0 is the top left hand
- corner of the screen). Returns packed values, (RET >> 8) is x,
- (RET & 0xff) is y. */
--int getxy (void);
-+int grub_getxy (void);
-
- /* The console part of getxy. */
- int console_getxy (void);
-
- /* Set the cursor position. */
--void gotoxy (int x, int y);
-+void grub_gotoxy (int x, int y);
-
- /* The console part of gotoxy. */
- void console_gotoxy (int x, int y);
-@@ -812,8 +823,64 @@
- constants defined above. */
- void set_attrib (int attr);
-
-+extern int view_x0, view_y0, view_x1, view_y1;
-+#ifdef VGA16
-+#define MAX_DISPLAYS 2
-+
-+#define cls() (display->Cls ? (*display->Cls)() : 0)
-+#define gotoxy(x, y) (display->Gotoxy ? (*display->Gotoxy)(x, y) : 0)
-+#define putchar(c) (display->Putchar ? (*display->Putchar)(c) : 0)
-+#define console_set_attrib(a) (display->SetAttrib ? (*display->SetAttrib)(a) : 0)
-+#define getxy() (display->Getxy ? (*display->Getxy)() : 0)
-+#define nocursor() (display->Nocursor ? (*display->Nocursor)() : 0)
-+struct display_entry {
-+ char *name;
-+ int (*Begin)(void);
-+ void (*End)(void);
-+ void (*Cls)(void);
-+ void (*Gotoxy)(int x, int y);
-+ void (*Putchar)(int ch);
-+ void (*SetAttrib)(int attr);
-+ int (*Getxy)(void);
-+ void (*Nocursor)(void);
-+};
-+struct display_entry display_entries[MAX_DISPLAYS + 1];
-+extern struct display_entry *display;
-+
-+extern int vga_inited, foreground, background, shade, border;
-+extern int display_idx, splash_set;
-+extern short cursorX, cursorY, cursorWidth, cursorHeight;
-+extern char cursorBuf[16], splashimage[64];
-+
-+int vga16_begin(void);
-+void vga16_end(void);
-+void vga16_cls(void);
-+void vga16_gotoxy(int x, int y);
-+void vga16_putchar(int ch);
-+int vga16_getxy(void);
-+void vga16_nocursor(void);
-+void vga16_set_attrib(int attr);
-+
-+int read_image();
-+void set_palette(int index, int red, int green, int blue);
-+void *get_font(void);
-+/* return previous video mode */
-+int set_videomode(int mode);
-+
-+int hex(int);
-+void set_int1c_handler();
-+void unset_int1c_handler();
-+void cursor(int state);
-+#else
-+#define cls grub_cls
-+#define gotoxy grub_gotoxy
-+#define console_set_attrib grub_set_attrib
-+#define getxy grub_getxy
-+#define nocursor grub_nocursor
-+#endif
-+
- /* The console part of set_attrib. */
--void console_set_attrib (int attr);
-+void grub_set_attrib (int attr);
-
- /* Low-level disk I/O */
- int get_diskinfo (int drive, struct geometry *geometry);
-Only in grub/stage2: shared.h.vga16
-diff -ur grub.bak/stage2/stage2.c grub/stage2/stage2.c
---- grub.bak/stage2/stage2.c Fri May 25 03:57:57 2001
-+++ grub/stage2/stage2.c Sun Jun 24 23:44:19 2001
-@@ -20,7 +20,12 @@
-
- #include "shared.h"
-
-+int view_x0 = 0, view_y0 = 0, view_x1 = 80, view_y1 = 25;
- grub_jmp_buf restart_env;
-+#ifdef VGA16
-+int vga_disabled = 0, viewport_set = 0;
-+int sx0, sy0, sx1, sy1;
-+#endif
-
- #ifdef PRESET_MENU_STRING
-
-@@ -96,12 +101,12 @@
- }
- #endif /* SUPPORT_SERIAL */
-
-- gotoxy (77, y + 1);
-+ gotoxy (view_x1 - 3, y + 1);
-
- if (first)
-- grub_putchar (disp_up);
-+ putchar (disp_up);
- else
-- grub_putchar (' ');
-+ putchar (' ');
-
- menu_entries = get_entry (menu_entries, first, 0);
-
-@@ -109,13 +114,13 @@
- {
- int j = 0;
-
-- gotoxy (3, y + i);
-+ gotoxy (view_x0 + 3, y + i);
-
- while (*menu_entries)
- {
-- if (j < 71)
-+ if (j < (view_x1 - view_x0) - 9)
- {
-- grub_putchar (*menu_entries);
-+ putchar (*menu_entries);
- j++;
- }
-
-@@ -125,16 +130,16 @@
- if (*(menu_entries - 1))
- menu_entries++;
-
-- for (; j < 71; j++)
-- grub_putchar (' ');
-+ for (; j < (view_x1 - view_x0) - 9; j++)
-+ putchar (' ');
- }
-
-- gotoxy (77, y + size);
-+ gotoxy (view_x0 + 3, y + size);
-
- if (*menu_entries)
-- grub_putchar (disp_down);
-+ putchar (disp_down);
- else
-- grub_putchar (' ');
-+ putchar (' ');
- }
-
-
-@@ -198,10 +203,10 @@
- )
- # endif
- {
-- for (i = 0; i < 14; i++)
-+ for (i = 0; i < 12; i++)
- {
- int j;
-- for (j = 0; j < 75; j++)
-+ for (j = view_x0; j < (view_x1 - view_x0) - 5; j++)
- {
- gotoxy (j + 1, i + y);
- set_attrib (normal_color);
-@@ -210,33 +215,33 @@
- }
- #endif
-
-- gotoxy (1, y);
-+ gotoxy (view_x0 + 1, y);
-
-- grub_putchar (disp_ul);
-- for (i = 0; i < 73; i++)
-- grub_putchar (disp_horiz);
-- grub_putchar (disp_ur);
-+ putchar (disp_ul);
-+ for (i = view_x0; i < view_x1 - 7; i++)
-+ putchar (disp_horiz);
-+ putchar (disp_ur);
-
- i = 1;
-
- while (1)
- {
-- gotoxy (1, y + i);
-+ gotoxy (view_x0 + 1, y + i);
-
- if (i > size)
- break;
-
-- grub_putchar (disp_vert);
-- gotoxy (75, y + i);
-- grub_putchar (disp_vert);
-+ putchar (disp_vert);
-+ gotoxy (view_x1 - 5, y + i);
-+ putchar (disp_vert);
-
- i++;
- }
-
-- grub_putchar (disp_ll);
-- for (i = 0; i < 73; i++)
-- grub_putchar (disp_horiz);
-- grub_putchar (disp_lr);
-+ putchar (disp_ll);
-+ for (i = view_x0; i < view_x1 - 7; i++)
-+ putchar (disp_horiz);
-+ putchar (disp_lr);
- }
-
- static void
-@@ -248,27 +253,27 @@
- if (terminal & TERMINAL_SERIAL)
- {
- menu_entries = get_entry (menu_entries, entryno, 0);
-- gotoxy (2, y);
-- grub_putchar (' ');
-- for (x = 3; x < 75; x++)
-+ gotoxy (view_x0 + 2, y);
-+ putchar (' ');
-+ for (x = view_x0 + 3; x < view_x1 - 5; x++)
- {
-- if (*menu_entries && x < 71)
-- grub_putchar (*menu_entries++);
-+ if (*menu_entries && x < view_x1 - 9)
-+ putchar (*menu_entries++);
- else
-- grub_putchar (' ');
-+ putchar (' ');
- }
- }
- else
- #endif /* SUPPORT_SERIAL */
- {
-- for (x = 2; x < 75; x++)
-+ for (x = view_x0 + 2; x < view_x1 - 5; x++)
- {
- gotoxy (x, y);
- set_attrib (attr);
- }
- }
-
-- gotoxy (74, y);
-+ gotoxy (view_x1 - 6, y);
- }
-
- /* Set the attribute of the line Y to normal state. */
-@@ -321,7 +326,8 @@
- invariant for TERMINAL_DUMB: first_entry == 0 */
- if (! (terminal & TERMINAL_DUMB))
- {
-- while (entryno > 11)
-+ errnum = ERR_NONE;
-+ while (entryno > 9)
- {
- first_entry++;
- entryno--;
-@@ -386,7 +392,7 @@
- #endif /* ! GRUB_UTIL */
-
- if (! (terminal & TERMINAL_DUMB))
-- print_border (3, 12);
-+ print_border (3 + view_y0, 12);
-
- #ifdef GRUB_UTIL
- /* In the grub shell, always use ACS_*. */
-@@ -442,10 +448,10 @@
- grub_printf ("\n\nThe selected entry is %d ", entryno);
- else
- {
-- print_entries (3, 12, first_entry, menu_entries);
-+ print_entries (view_y0 + 3, 12, first_entry, menu_entries);
-
- /* highlight initial line */
-- set_line_highlight (4 + entryno, first_entry + entryno,
-+ set_line_highlight (view_y0 + 4 + entryno, first_entry + entryno,
- menu_entries);
- }
- }
-@@ -474,9 +480,9 @@
- entryno, grub_timeout);
- else
- {
-- gotoxy (3, 22);
-+ gotoxy (view_x0 + 3, view_y1 - 3);
- printf ("The highlighted entry will be booted automatically in %d seconds. ", grub_timeout);
-- gotoxy (74, 4 + entryno);
-+ gotoxy (view_x0 - 6, view_y0 + 4 + entryno);
- }
-
- grub_timeout--;
-@@ -502,12 +508,12 @@
- if (terminal & TERMINAL_DUMB)
- grub_putchar ('\r');
- else
-- gotoxy (3, 22);
-+ gotoxy (view_x0 + 3, 22);
- printf (" ");
- grub_timeout = -1;
- fallback_entry = -1;
- if (! (terminal & TERMINAL_DUMB))
-- gotoxy (74, 4 + entryno);
-+ gotoxy (view_x1 - 6, view_x0 + 4 + entryno);
- }
-
- /* We told them above (at least in SUPPORT_SERIAL) to use
-@@ -523,17 +529,17 @@
- {
- if (entryno > 0)
- {
-- set_line_normal (4 + entryno, first_entry + entryno,
-+ set_line_normal (view_y0 + 4 + entryno, first_entry + entryno,
- menu_entries);
- entryno--;
-- set_line_highlight (4 + entryno, first_entry + entryno,
-+ set_line_highlight (view_y0 + 4 + entryno, first_entry + entryno,
- menu_entries);
- }
- else if (first_entry > 0)
- {
- first_entry--;
-- print_entries (3, 12, first_entry, menu_entries);
-- set_line_highlight (4, first_entry + entryno,
-+ print_entries (view_y0 + 3, 12, first_entry, menu_entries);
-+ set_line_highlight (view_y0 + 4, first_entry + entryno,
- menu_entries);
- }
- }
-@@ -545,17 +551,17 @@
- else
- if (entryno < 11)
- {
-- set_line_normal (4 + entryno, first_entry + entryno,
-+ set_line_normal (view_y0 + 4 + entryno, first_entry + entryno,
- menu_entries);
- entryno++;
-- set_line_highlight (4 + entryno, first_entry + entryno,
-+ set_line_highlight (view_y0 + 4 + entryno, first_entry + entryno,
- menu_entries);
- }
- else if (num_entries > 12 + first_entry)
- {
- first_entry++;
-- print_entries (3, 12, first_entry, menu_entries);
-- set_line_highlight (15, first_entry + entryno, menu_entries);
-+ print_entries (view_y0 + 3, 12, first_entry, menu_entries);
-+ set_line_highlight (view_y0 + 15, first_entry + entryno, menu_entries);
- }
- }
-
-@@ -569,7 +575,7 @@
- if ((c == 'd') || (c == 'o') || (c == 'O'))
- {
- if (! (terminal & TERMINAL_DUMB))
-- set_line_normal (4 + entryno, first_entry + entryno,
-+ set_line_normal (view_y0 + 4 + entryno, first_entry + entryno,
- menu_entries);
-
- /* insert after is almost exactly like insert before */
-@@ -627,8 +633,8 @@
- }
- else
- {
-- print_entries (3, 12, first_entry, menu_entries);
-- set_line_highlight (4 + entryno, first_entry + entryno,
-+ print_entries (view_y0 + 3, 12, first_entry, menu_entries);
-+ set_line_highlight (view_y0 + 4 + entryno, first_entry + entryno,
- menu_entries);
- }
- }
-@@ -651,7 +657,7 @@
- if (terminal & TERMINAL_DUMB)
- grub_printf ("\r ");
- else
-- gotoxy (1, 21);
-+ gotoxy (view_x0 + 1, view_y1 + 21);
-
- /* Wipe out the previously entered password */
- memset (entered, 0, sizeof (entered));
-@@ -798,6 +804,11 @@
- while (1)
- {
- cls ();
-+#ifdef VGA16
-+ if (display->End)
-+ (*display->End)();
-+ display = &display_entries[0];
-+#endif
-
- if (config_entries)
- printf (" Booting \'%s\'\n\n",
-@@ -827,6 +838,16 @@
- break;
- }
-
-+#ifdef VGA16
-+ if (display_idx >= 0)
-+ display = &display_entries[display_idx];
-+ else if (!vga_disabled)
-+ display = &display_entries[1];
-+
-+ if (!display->Begin || !(*display->Begin)())
-+ display = &display_entries[0];
-+#endif
-+
- show_menu = 1;
- goto restart;
- }
-@@ -891,6 +912,560 @@
- return pos;
- }
-
-+#ifdef VGA16
-+struct display_entry display_entries[MAX_DISPLAYS + 1] = {
-+ {"text", 0, 0, grub_cls, grub_gotoxy, grub_putchar, grub_set_attrib,
-+ grub_getxy, grub_nocursor},
-+ {"vga16",
-+ vga16_begin, vga16_end, vga16_cls, vga16_gotoxy, vga16_putchar,
-+ vga16_set_attrib, vga16_getxy, vga16_nocursor},
-+ {0, 0, 0, 0, 0, 0, 0, 0, 0}
-+};
-+struct display_entry *display;
-+int display_idx = -1;
-+
-+/* default vga palette */
-+char vga16pal[16][3] = {
-+ { 0, 0, 0},
-+ { 0, 0, 42},
-+ { 0, 42, 0},
-+ { 0, 42, 42},
-+ {42, 0, 0},
-+ {42, 0, 42},
-+ {42, 21, 0},
-+ {42, 42, 42},
-+ {21, 21, 21},
-+ {21, 21, 63},
-+ {21, 63, 21},
-+ {21, 63, 63},
-+ {63, 21, 21},
-+ {63, 21, 63},
-+ {63, 63, 21},
-+ {63, 63, 63},
-+};
-+
-+int fontx, fonty;
-+unsigned char *font8x16;
-+int saved_videomode, no_scroll = 0, no_cursor = 0, shade = 1, vga_inited = 0;
-+unsigned short text[80 * 30];
-+int foreground = (63 << 16) | (63 << 8) | (63), background = 0, border = 0;
-+int splash_set;
-+char splashimage[64];
-+#define VSHADOW VSHADOW1
-+unsigned char VSHADOW1[38400];
-+unsigned char VSHADOW2[38400];
-+unsigned char VSHADOW4[38400];
-+unsigned char VSHADOW8[38400];
-+
-+static inline void
-+outb(unsigned short port, unsigned char val)
-+{
-+ __asm __volatile ("outb %0,%1"::"a" (val), "d" (port));
-+}
-+
-+static void
-+ModeReg(int value)
-+{
-+ outb(0x3ce, 5);
-+ outb(0x3cf, value);
-+}
-+
-+static void
-+MapMask(int value)
-+{
-+ outb(0x3c4, 2);
-+ outb(0x3c5, value);
-+}
-+
-+/* set/reset register */
-+static void
-+SetRes(int value)
-+{
-+ outb(0x3ce, 0);
-+ outb(0x3cf, value);
-+}
-+
-+/* enable set/reset register */
-+static void
-+ESetRes(int value)
-+{
-+ outb(0x3ce, 1);
-+ outb(0x3cf, value);
-+}
-+
-+static void
-+ReadMap(int value)
-+{
-+ outb(0x3ce, 4);
-+ outb(0x3cf, value);
-+}
-+
-+/* bit mask register */
-+static void
-+BitMask(int value)
-+{
-+ outb(0x3ce, 8);
-+ outb(0x3cf, value);
-+}
-+
-+void
-+grub_memcpy(void *dest, const void *src, int len)
-+{
-+ int i;
-+ register char *d = (char*)dest, *s = (char*)src;
-+
-+ for (i = 0; i < len; i++)
-+ d[i] = s[i];
-+}
-+
-+int
-+hex(int v)
-+{
-+ if (v >= 'A' && v <= 'F')
-+ return (v - 'A' + 10);
-+ if (v >= 'a' && v <= 'f')
-+ return (v - 'a' + 10);
-+ return (v - '0');
-+}
-+
-+static void
-+SetXY(int col, int row)
-+{
-+ if (col >= view_x0 && col < view_x1) {
-+ fontx = col;
-+ cursorX = col << 3;
-+ }
-+ if (row >= view_y0 && row < view_y1) {
-+ fonty = row;
-+ cursorY = row << 4;
-+ }
-+}
-+
-+void
-+cursor(int set)
-+{
-+ unsigned char *pat, *mem, *ptr, chr[16 << 2];
-+ int i, ch, invert, offset;
-+
-+ if (set && (no_cursor || no_scroll))
-+ return;
-+
-+ offset = cursorY * 80 + fontx;
-+ ch = text[fonty * 80 + fontx] & 0xff;
-+ invert = (text[fonty * 80 + fontx] & 0xff00) != 0;
-+ pat = font8x16 + (ch << 4);
-+
-+ mem = (unsigned char*)VIDEO + offset;
-+
-+ if (!set) {
-+ for (i = 0; i < 16; i++) {
-+ unsigned char mask = pat[i];
-+
-+ if (!invert) {
-+ chr[i ] = ((unsigned char*)VSHADOW1)[offset];
-+ chr[16 + i] = ((unsigned char*)VSHADOW2)[offset];
-+ chr[32 + i] = ((unsigned char*)VSHADOW4)[offset];
-+ chr[48 + i] = ((unsigned char*)VSHADOW8)[offset];
-+
-+ if (shade) {
-+ if (ch == DISP_VERT || ch == DISP_LL ||
-+ ch == DISP_UR || ch == DISP_LR) {
-+ unsigned char pmask = ~(pat[i] >> 1);
-+
-+ chr[i ] &= pmask;
-+ chr[16 + i] &= pmask;
-+ chr[32 + i] &= pmask;
-+ chr[48 + i] &= pmask;
-+ }
-+ if (i > 0 && ch != DISP_VERT) {
-+ unsigned char pmask = ~(pat[i - 1] >> 1);
-+
-+ chr[i ] &= pmask;
-+ chr[16 + i] &= pmask;
-+ chr[32 + i] &= pmask;
-+ chr[48 + i] &= pmask;
-+ if (ch == DISP_HORIZ || ch == DISP_UR || ch == DISP_LR) {
-+ pmask = ~pat[i - 1];
-+
-+ chr[i ] &= pmask;
-+ chr[16 + i] &= pmask;
-+ chr[32 + i] &= pmask;
-+ chr[48 + i] &= pmask;
-+ }
-+ }
-+ }
-+ chr[i ] |= mask;
-+ chr[16 + i] |= mask;
-+ chr[32 + i] |= mask;
-+ chr[48 + i] |= mask;
-+
-+ offset += 80;
-+ }
-+ else {
-+ chr[i ] = mask;
-+ chr[16 + i] = mask;
-+ chr[32 + i] = mask;
-+ chr[48 + i] = mask;
-+ }
-+ }
-+ }
-+ else {
-+ MapMask(15);
-+ ptr = mem;
-+ for (i = 0; i < 16; i++, ptr += 80) {
-+ cursorBuf[i] = pat[i];
-+ *ptr = ~pat[i];
-+ }
-+ return;
-+ }
-+
-+ offset = 0;
-+ for (i = 1; i < 16; i <<= 1, offset += 16) {
-+ int j;
-+
-+ MapMask(i);
-+ ptr = mem;
-+ for (j = 0; j < 16; j++, ptr += 80)
-+ *ptr = chr[j + offset];
-+ }
-+
-+ MapMask(15);
-+}
-+
-+int
-+read_image(void)
-+{
-+ char buf[32], pal[16];
-+ unsigned char c, base, mask, *s1, *s2, *s4, *s8;
-+ unsigned i, len, idx, colors, x, y, width, height;
-+
-+ if (!grub_open(splashimage))
-+ return (0);
-+
-+ /* read header */
-+ if (!grub_read((char*)&buf, 10) || grub_memcmp(buf, "/* XPM */\n", 10)) {
-+ grub_close();
-+ return (0);
-+ }
-+
-+ /* parse info */
-+ while (grub_read(&c, 1)) {
-+ if (c == '"')
-+ break;
-+ }
-+
-+ while (grub_read(&c, 1) && (c == ' ' || c == '\t'))
-+ ;
-+
-+ i = 0;
-+ width = c - '0';
-+ while (grub_read(&c, 1)) {
-+ if (c >= '0' && c <= '9')
-+ width = width * 10 + c - '0';
-+ else
-+ break;
-+ }
-+ while (grub_read(&c, 1) && (c == ' ' || c == '\t'))
-+ ;
-+
-+ height = c - '0';
-+ while (grub_read(&c, 1)) {
-+ if (c >= '0' && c <= '9')
-+ height = height * 10 + c - '0';
-+ else
-+ break;
-+ }
-+ while (grub_read(&c, 1) && (c == ' ' || c == '\t'))
-+ ;
-+
-+ colors = c - '0';
-+ while (grub_read(&c, 1)) {
-+ if (c >= '0' && c <= '9')
-+ colors = colors * 10 + c - '0';
-+ else
-+ break;
-+ }
-+
-+ base = 0;
-+ while (grub_read(&c, 1) && c != '"')
-+ ;
-+
-+ /* palette */
-+ for (i = 0, idx = 1; i < colors; i++) {
-+ len = 0;
-+
-+ while (grub_read(&c, 1) && c != '"')
-+ ;
-+ grub_read(&c, 1); /* char */
-+ base = c;
-+ grub_read(buf, 4); /* \t c # */
-+
-+ while (grub_read(&c, 1) && c != '"') {
-+ if (len < sizeof(buf))
-+ buf[len++] = c;
-+ }
-+
-+ if (len == 6 && idx < 15) {
-+ int r = ((hex(buf[0]) << 4) | hex(buf[1])) >> 2;
-+ int g = ((hex(buf[2]) << 4) | hex(buf[3])) >> 2;
-+ int b = ((hex(buf[4]) << 4) | hex(buf[5])) >> 2;
-+
-+ pal[idx] = base;
-+ set_palette(idx, r, g, b);
-+ ++idx;
-+ }
-+ }
-+
-+ x = y = len = 0;
-+
-+ s1 = (unsigned char*)VSHADOW1;
-+ s2 = (unsigned char*)VSHADOW2;
-+ s4 = (unsigned char*)VSHADOW4;
-+ s8 = (unsigned char*)VSHADOW8;
-+
-+ for (i = 0; i < 38400; i++)
-+ s1[i] = s2[i] = s4[i] = s8[i] = 0;
-+
-+ /* parse xpm data */
-+ while (y < height) {
-+ while (1) {
-+ if (!grub_read(&c, 1)) {
-+ grub_close();
-+ return (0);
-+ }
-+ if (c == '"')
-+ break;
-+ }
-+
-+ while (grub_read(&c, 1) && c != '"') {
-+ for (i = 1; i < 15; i++)
-+ if (pal[i] == c) {
-+ c = i;
-+ break;
-+ }
-+
-+ mask = 0x80 >> (x & 7);
-+ if (c & 1)
-+ s1[len + (x >> 3)] |= mask;
-+ if (c & 2)
-+ s2[len + (x >> 3)] |= mask;
-+ if (c & 4)
-+ s4[len + (x >> 3)] |= mask;
-+ if (c & 8)
-+ s8[len + (x >> 3)] |= mask;
-+
-+ if (++x >= 640) {
-+ x = 0;
-+
-+ if (y < 480)
-+ len += 80;
-+ ++y;
-+ }
-+ }
-+ }
-+
-+ grub_close();
-+
-+ set_palette(0, (background >> 16), (background >> 8) & 63, background & 63);
-+ set_palette(15, (foreground >> 16), (foreground >> 8) & 63, foreground & 63);
-+
-+ set_palette(0x11, (border >> 16), (border >> 8) & 63, border & 63);
-+
-+ return (1);
-+}
-+
-+int
-+vga16_begin(void)
-+{
-+ if (vga_inited)
-+ return (1);
-+
-+ if (!*splashimage)
-+ grub_strcpy(splashimage, "/boot/grub/splash.xpm");
-+
-+ saved_videomode = set_videomode(0x12);
-+ if (!read_image()) {
-+ set_videomode(saved_videomode);
-+ return (0);
-+ }
-+
-+ font8x16 = (unsigned char*)get_font();
-+
-+ cursorWidth = 8;
-+ cursorHeight = 16;
-+
-+ set_int1c_handler();
-+
-+ view_x0 = sx0;
-+ view_y0 = sy0;
-+ view_x1 = sx1;
-+ view_y1 = sy1;
-+
-+ return (vga_inited = 1);
-+}
-+
-+void
-+vga16_end(void)
-+{
-+ if (vga_inited) {
-+ unset_int1c_handler();
-+ set_videomode(saved_videomode);
-+ vga_inited = 0;
-+ no_cursor = 0;
-+ }
-+
-+ sx0 = view_x0;
-+ sy0 = view_y0;
-+ sx1 = view_x1;
-+ sy1 = view_y1;
-+ view_x0 = 0;
-+ view_x1 = 80;
-+ view_y0 = 0;
-+ view_y1 = 25;
-+}
-+
-+void
-+vga16_cls(void)
-+{
-+ int i;
-+ unsigned char *mem, *s1, *s2, *s4, *s8;
-+
-+ SetXY(view_x0, view_y0);
-+
-+ mem = (unsigned char*)VIDEO;
-+ s1 = (unsigned char*)VSHADOW1;
-+ s2 = (unsigned char*)VSHADOW2;
-+ s4 = (unsigned char*)VSHADOW4;
-+ s8 = (unsigned char*)VSHADOW8;
-+
-+ for (i = 0; i < 80 * 30; i++)
-+ text[i] = ' ';
-+
-+ BitMask(0xff);
-+
-+ /* plano 1 */
-+ MapMask(1);
-+ grub_memcpy(mem, s1, 38400);
-+
-+ /* plano 2 */
-+ MapMask(2);
-+ grub_memcpy(mem, s2, 38400);
-+
-+ /* plano 3 */
-+ MapMask(4);
-+ grub_memcpy(mem, s4, 38400);
-+
-+ /* plano 4 */
-+ MapMask(8);
-+ grub_memcpy(mem, s8, 38400);
-+
-+ MapMask(15);
-+
-+ if (no_cursor) {
-+ no_cursor = 0;
-+ set_int1c_handler();
-+ }
-+}
-+
-+void
-+vga16_gotoxy(int x, int y)
-+{
-+ cursor(0);
-+
-+ SetXY(x, y);
-+
-+ cursor(1);
-+}
-+
-+static void
-+scroll(void)
-+{
-+ int i, j;
-+
-+ if (no_scroll)
-+ return;
-+
-+ no_scroll = 1;
-+
-+ for (j = view_y0 + 1; j < view_y1; j++) {
-+ gotoxy(view_x0, j - 1);
-+ for (i = view_x0; i < view_x1; i++)
-+ putchar(text[j * 80 + i]);
-+ }
-+
-+ gotoxy(view_x0, view_y1 - 1);
-+ for (i = view_x0; i < view_x1; i++)
-+ putchar(' ');
-+
-+ SetXY(view_x0, view_y1 - 1);
-+
-+ no_scroll = 0;
-+}
-+
-+void
-+vga16_putchar(int ch)
-+{
-+ ch &= 0xff;
-+
-+ cursor(0);
-+
-+ if (ch == '\n') {
-+ SetXY(view_x0, fonty);
-+ if (fonty + 1 < view_y1)
-+ SetXY(view_x0, fonty + 1);
-+ else
-+ scroll();
-+ cursor(1);
-+ return;
-+ }
-+ else if (ch == '\r') {
-+ SetXY(view_x0, fonty);
-+ cursor(1);
-+ return;
-+ }
-+
-+ text[fonty * 80 + fontx] = ch;
-+
-+ cursor(0);
-+
-+ if ((fontx + 1) >= view_x1) {
-+ SetXY(view_x0, fonty);
-+ if (fonty + 1 < view_y1)
-+ SetXY(view_x0, fonty + 1);
-+ else
-+ scroll();
-+ }
-+ else
-+ SetXY(fontx + 1, fonty);
-+
-+ cursor(1);
-+}
-+
-+int
-+vga16_getxy()
-+{
-+ return ((fontx << 8) | fonty);
-+}
-+
-+void
-+vga16_nocursor()
-+{
-+ if (!no_cursor) {
-+ no_cursor = 1;
-+ unset_int1c_handler();
-+ cursor(0);
-+ }
-+}
-+
-+void
-+vga16_set_attrib(int attrib)
-+{
-+ text[fonty * 80 + fontx] &= 0x00ff;
-+ if (attrib & 0xf0)
-+ text[fonty * 80 + fontx] |= 0x100;
-+ cursor(0);
-+}
-+#endif
-
- /* This is the starting function in C. */
- void
-@@ -900,6 +1475,14 @@
- char *config_entries, *menu_entries;
- char *kill_buf = (char *) KILL_BUF;
-
-+#ifdef VGA16
-+ /* Make sure it points to a valid entry */
-+ display = &display_entries[0];
-+
-+ if (ASCII_CHAR(checkkey()) == 0x1b)
-+ vga_disabled = 1;
-+#endif
-+
- /* Initialize the environment for restarting Stage 2. */
- grub_setjmp (restart_env);
-
-@@ -1038,6 +1621,29 @@
- grub_close ();
- }
-
-+#ifdef VGA16
-+ if (display_idx >= 0)
-+ display = &display_entries[display_idx];
-+ else if (!vga_disabled) {
-+ display = &display_entries[1];
-+ }
-+ if (!viewport_set)
-+ view_y1 = 30;
-+ sx0 = view_x0;
-+ sy0 = view_y0;
-+ sx1 = view_x1;
-+ sy1 = view_y1;
-+
-+ if (!display->Begin || !(*display->Begin)())
-+ display = &display_entries[0];
-+
-+ if (!vga_inited) {
-+ sx0 = sy0 = view_x0 = view_y0 = 0;
-+ sx1 = view_x1 = 80;
-+ sy1 = view_y1 = 25;
-+ }
-+#endif
-+
- if (! num_entries)
- {
- /* If no acceptable config file, goto command-line, starting
-Only in grub/stage2: stage2.c.vga16
diff --git a/sys-apps/grub/files/grub-0.90/grub-0.90-install.in.patch b/sys-apps/grub/files/grub-0.90/grub-0.90-install.in.patch
deleted file mode 100644
index c714196a4402..000000000000
--- a/sys-apps/grub/files/grub-0.90/grub-0.90-install.in.patch
+++ /dev/null
@@ -1,34 +0,0 @@
---- grub-0.90/util/grub-install.in~ Wed Feb 28 06:19:39 2001
-+++ grub-0.90/util/grub-install.in Thu Jul 19 16:01:12 2001
-@@ -224,6 +224,15 @@
- test -d "$bootdir" || mkdir "$bootdir" || exit 1
- test -d "$grubdir" || mkdir "$grubdir" || exit 1
-
-+# Copy the GRUB images to the GRUB directory.
-+for file in ${grubdir}/stage1 ${grubdir}/stage2 ${grubdir}/*stage1_5; do
-+ rm -f $file || exit 1
-+done
-+for file in \
-+ ${pkgdatadir}/stage1 ${pkgdatadir}/stage2 ${pkgdatadir}/*stage1_5; do
-+ cp -f $file ${grubdir} || exit 1
-+done
-+
- # If --recheck is specified, remove the device map, if present.
- if test $recheck = yes; then
- rm -f $device_map
-@@ -297,15 +306,6 @@
- EOF
- exit 1
- fi
--
--# Copy the GRUB images to the GRUB directory.
--for file in ${grubdir}/stage1 ${grubdir}/stage2 ${grubdir}/*stage1_5; do
-- rm -f $file || exit 1
--done
--for file in \
-- ${pkgdatadir}/stage1 ${pkgdatadir}/stage2 ${pkgdatadir}/*stage1_5; do
-- cp -f $file ${grubdir} || exit 1
--done
-
- # Create a safe temporary file.
- test -x /bin/tempfile && log_file=`tempfile --prefix=grub`
diff --git a/sys-apps/grub/files/grub-0.90/grub-0.90-installcopyonly.patch b/sys-apps/grub/files/grub-0.90/grub-0.90-installcopyonly.patch
deleted file mode 100644
index 1083ab507e71..000000000000
--- a/sys-apps/grub/files/grub-0.90/grub-0.90-installcopyonly.patch
+++ /dev/null
@@ -1,85 +0,0 @@
---- grub-0.90/util/grub-install.in~ Thu Jul 19 18:42:58 2001
-+++ grub-0.90/util/grub-install.in Thu Jul 19 18:43:12 2001
-@@ -38,6 +38,7 @@
- force_lba=
- recheck=no
- debug=no
-+justcopy=no
-
- # Usage: usage
- # Print the usage.
-@@ -149,6 +150,17 @@
- fi
- }
-
-+copy_images() {
-+ # Copy the GRUB images to the GRUB directory.
-+ for file in ${grubdir}/stage1 ${grubdir}/stage2 ${grubdir}/*stage1_5; do
-+ rm -f $file || exit 1
-+ done
-+ for file in \
-+ ${pkgdatadir}/stage1 ${pkgdatadir}/stage2 ${pkgdatadir}/*stage1_5; do
-+ cp -f $file ${grubdir} || exit 1
-+ done
-+}
-+
- # Check the arguments.
- for option in "$@"; do
- case "$option" in
-@@ -166,6 +178,8 @@
- force_lba="--force-lba" ;;
- --recheck)
- recheck=yes ;;
-+ --just-copy)
-+ justcopy=yes ;;
- # This is an undocumented feature...
- --debug)
- debug=yes ;;
-@@ -179,12 +193,6 @@
- esac
- done
-
--if test "x$install_device" = x; then
-- echo "install_device not specified." 1>&2
-- usage
-- exit 1
--fi
--
- # If the debugging feature is enabled, print commands.
- if test $debug = yes; then
- set -x
-@@ -195,6 +203,18 @@
- grubdir=${bootdir}/grub
- device_map=${grubdir}/device.map
-
-+# if they just want the images copied, copy the images and then exit
-+if test $justcopy = yes; then
-+ copy_images
-+ exit 0
-+fi
-+
-+if test "x$install_device" = x; then
-+ echo "install_device not specified." 1>&2
-+ usage
-+ exit 1
-+fi
-+
- # Check if GRUB is installed
- if test -f "$grub_shell"; then
- :
-@@ -224,14 +244,7 @@
- test -d "$bootdir" || mkdir "$bootdir" || exit 1
- test -d "$grubdir" || mkdir "$grubdir" || exit 1
-
--# Copy the GRUB images to the GRUB directory.
--for file in ${grubdir}/stage1 ${grubdir}/stage2 ${grubdir}/*stage1_5; do
-- rm -f $file || exit 1
--done
--for file in \
-- ${pkgdatadir}/stage1 ${pkgdatadir}/stage2 ${pkgdatadir}/*stage1_5; do
-- cp -f $file ${grubdir} || exit 1
--done
-+copy_images
-
- # If --recheck is specified, remove the device map, if present.
- if test $recheck = yes; then
diff --git a/sys-apps/grub/files/grub-0.90/grub-0.90-passwordprompt.patch b/sys-apps/grub/files/grub-0.90/grub-0.90-passwordprompt.patch
deleted file mode 100644
index 47810a9ca9b9..000000000000
--- a/sys-apps/grub/files/grub-0.90/grub-0.90-passwordprompt.patch
+++ /dev/null
@@ -1,146 +0,0 @@
-diff -ur grub-0.90/stage2/stage2.c grub/stage2/stage2.c
---- grub-0.90/stage2/stage2.c Thu Jul 19 01:58:59 2001
-+++ grub/stage2/stage2.c Thu Jul 19 01:59:11 2001
-@@ -316,6 +316,7 @@
- char *cur_entry = 0;
- int disp_up = DISP_UP;
- int disp_down = DISP_DOWN;
-+ int ask_pass = 0;
-
- /*
- * Main loop for menu UI.
-@@ -423,8 +424,72 @@
- grub_printf ("\n\
- Use the %c and %c keys to select which entry is highlighted.\n",
- disp_up, disp_down);
--
-- if (! auth && password)
-+
-+ if (! auth && password && ask_pass)
-+ {
-+ /* Do password check here! */
-+ char entered[32];
-+ char *pptr = password;
-+
-+ /* we've asked, so don't ask again */
-+ ask_pass = 0;
-+
-+ if (terminal & TERMINAL_DUMB)
-+ grub_printf ("\n\nThe selected entry is %d ", entryno);
-+ else
-+ {
-+ print_entries (view_y0 + 3, 12, first_entry, menu_entries);
-+ /* highlight initial line */
-+ set_line_highlight (view_y0 + 4 + entryno, first_entry + entryno,
-+ menu_entries);
-+ }
-+
-+ /* Wipe out the previously entered password */
-+ memset (entered, 0, sizeof (entered));
-+ gotoxy (view_x0 + 1, view_y0 + 16);
-+ get_cmdline (" Password: ", entered, 31, '*', 0);
-+
-+ while (! isspace (*pptr) && *pptr)
-+ pptr++;
-+
-+ /* Make sure that PASSWORD is NUL-terminated. */
-+ *pptr++ = 0;
-+
-+ if (! check_password (entered, password, password_type))
-+ {
-+ char *new_file = config_file;
-+
-+ while (isspace (*pptr))
-+ pptr++;
-+
-+ /* If *PPTR is NUL, then allow the user to use
-+ privileged instructions, otherwise, load
-+ another configuration file. */
-+ if (*pptr != 0)
-+ {
-+ while ((*(new_file++) = *(pptr++)) != 0)
-+ ;
-+
-+ /* Make sure that the user will not have
-+ authority in the next configuration. */
-+ auth = 0;
-+ return;
-+ }
-+ else
-+ {
-+ /* Now the user is superhuman. */
-+ auth = 1;
-+ goto restart;
-+ }
-+ }
-+ else
-+ {
-+ printf (" Failed!\n Press any key to continue...");
-+ getkey ();
-+ goto restart;
-+ }
-+ }
-+ else if (! auth && password)
- {
- printf ("\
- Press enter to boot the selected OS or \'p\' to enter a\n\
-@@ -637,57 +702,8 @@
- {
- if (c == 'p')
- {
-- /* Do password check here! */
-- char entered[32];
-- char *pptr = password;
--
-- if (terminal & TERMINAL_DUMB)
-- grub_printf ("\r ");
-- else
-- gotoxy (view_x0 + 1, view_y1 + 21);
--
-- /* Wipe out the previously entered password */
-- memset (entered, 0, sizeof (entered));
-- get_cmdline (" Password: ", entered, 31, '*', 0);
--
-- while (! isspace (*pptr) && *pptr)
-- pptr++;
--
-- /* Make sure that PASSWORD is NUL-terminated. */
-- *pptr++ = 0;
--
-- if (! check_password (entered, password, password_type))
-- {
-- char *new_file = config_file;
-- while (isspace (*pptr))
-- pptr++;
--
-- /* If *PPTR is NUL, then allow the user to use
-- privileged instructions, otherwise, load
-- another configuration file. */
-- if (*pptr != 0)
-- {
-- while ((*(new_file++) = *(pptr++)) != 0)
-- ;
--
-- /* Make sure that the user will not have
-- authority in the next configuration. */
-- auth = 0;
-- return;
-- }
-- else
-- {
-- /* Now the user is superhuman. */
-- auth = 1;
-- goto restart;
-- }
-- }
-- else
-- {
-- printf ("Failed!\n Press any key to continue...");
-- getkey ();
-- goto restart;
-- }
-+ ask_pass = 1;
-+ goto restart;
- }
- }
- else
diff --git a/sys-apps/grub/files/grub-0.90/grub-0.90-vga16-keypressclear.patch b/sys-apps/grub/files/grub-0.90/grub-0.90-vga16-keypressclear.patch
deleted file mode 100644
index e1678344ba12..000000000000
--- a/sys-apps/grub/files/grub-0.90/grub-0.90-vga16-keypressclear.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-diff -ur grub/stage2/stage2.c grub-0.90/stage2/stage2.c
---- grub/stage2/stage2.c Thu Jul 19 01:43:41 2001
-+++ grub-0.90/stage2/stage2.c Thu Jul 19 01:50:23 2001
-@@ -503,19 +503,6 @@
-
- c = translate_keycode (getkey ());
-
-- if (grub_timeout >= 0)
-- {
-- if (terminal & TERMINAL_DUMB)
-- grub_putchar ('\r');
-- else
-- gotoxy (view_x0 + 3, 22);
-- printf (" ");
-- grub_timeout = -1;
-- fallback_entry = -1;
-- if (! (terminal & TERMINAL_DUMB))
-- gotoxy (view_x1 - 6, view_x0 + 4 + entryno);
-- }
--
- /* We told them above (at least in SUPPORT_SERIAL) to use
- '^' or 'v' so accept these keys. */
- if (c == 16 || c == '^')
-@@ -792,6 +779,12 @@
- }
- #endif
- }
-+ if (grub_timeout >= 0)
-+ {
-+ grub_timeout = -1;
-+ fallback_entry = -1;
-+ goto restart;
-+ }
- }
- }
-
diff --git a/sys-apps/grub/files/grub-0.90/grub-jfs+xfs-1.0-build.patch b/sys-apps/grub/files/grub-0.90/grub-jfs+xfs-1.0-build.patch
deleted file mode 100644
index 8c4b2c835600..000000000000
--- a/sys-apps/grub/files/grub-0.90/grub-jfs+xfs-1.0-build.patch
+++ /dev/null
@@ -1,1454 +0,0 @@
-diff -urN --exclude-from=xlist-build grub-0.90/configure grub-0.90.jfs+xfs/configure
---- grub-0.90/configure Fri Jul 6 21:56:44 2001
-+++ grub-0.90.jfs+xfs/configure Thu Aug 23 18:21:27 2001
-@@ -32,6 +32,10 @@
- ac_help="$ac_help
- --disable-reiserfs disable ReiserFS support in Stage 2"
- ac_help="$ac_help
-+ --disable-jfs disable IBM JFS support in Stage 2"
-+ac_help="$ac_help
-+ --disable-xfs disable SGI XFS support in Stage 2"
-+ac_help="$ac_help
- --disable-vstafs disable VSTa FS support in Stage 2"
- ac_help="$ac_help
- --disable-gunzip disable decompression in Stage 2"
-@@ -675,7 +679,7 @@
- # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
- # ./install, which can be erroneously created by make from ./install.sh.
- echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
--echo "configure:679: checking for a BSD compatible install" >&5
-+echo "configure:683: checking for a BSD compatible install" >&5
- if test -z "$INSTALL"; then
- if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-@@ -728,7 +732,7 @@
- test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
- echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
--echo "configure:732: checking whether build environment is sane" >&5
-+echo "configure:736: checking whether build environment is sane" >&5
- # Just in case
- sleep 1
- echo timestamp > conftest.file
-@@ -800,7 +804,7 @@
- # Extract the first word of "$ac_prog", so it can be a program name with args.
- set dummy $ac_prog; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
--echo "configure:804: checking for $ac_word" >&5
-+echo "configure:808: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -830,7 +834,7 @@
- done
-
- echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
--echo "configure:834: checking whether ${MAKE-make} sets \${MAKE}" >&5
-+echo "configure:838: checking whether ${MAKE-make} sets \${MAKE}" >&5
- set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
- if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-@@ -960,7 +964,7 @@
- fi
-
- echo $ac_n "checking host system type""... $ac_c" 1>&6
--echo "configure:964: checking host system type" >&5
-+echo "configure:968: checking host system type" >&5
-
- host_alias=$host
- case "$host_alias" in
-@@ -994,7 +998,7 @@
- #
-
- echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
--echo "configure:998: checking whether to enable maintainer-specific portions of Makefiles" >&5
-+echo "configure:1002: checking whether to enable maintainer-specific portions of Makefiles" >&5
- # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
- if test "${enable_maintainer_mode+set}" = set; then
- enableval="$enable_maintainer_mode"
-@@ -1020,7 +1024,7 @@
- # Extract the first word of "perl", so it can be a program name with args.
- set dummy perl; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
--echo "configure:1024: checking for $ac_word" >&5
-+echo "configure:1028: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_path_PERL'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1067,7 +1071,7 @@
- #
-
- echo $ac_n "checking build system type""... $ac_c" 1>&6
--echo "configure:1071: checking build system type" >&5
-+echo "configure:1075: checking build system type" >&5
-
- build_alias=$build
- case "$build_alias" in
-@@ -1093,7 +1097,7 @@
- # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
- set dummy ${ac_tool_prefix}gcc; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
--echo "configure:1097: checking for $ac_word" >&5
-+echo "configure:1101: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1125,7 +1129,7 @@
- # Extract the first word of "gcc", so it can be a program name with args.
- set dummy gcc; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
--echo "configure:1129: checking for $ac_word" >&5
-+echo "configure:1133: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1155,7 +1159,7 @@
- # Extract the first word of "cc", so it can be a program name with args.
- set dummy cc; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
--echo "configure:1159: checking for $ac_word" >&5
-+echo "configure:1163: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1206,7 +1210,7 @@
- # Extract the first word of "cl", so it can be a program name with args.
- set dummy cl; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
--echo "configure:1210: checking for $ac_word" >&5
-+echo "configure:1214: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1238,7 +1242,7 @@
- fi
-
- echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
--echo "configure:1242: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
-+echo "configure:1246: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
-
- ac_ext=c
- # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-@@ -1249,12 +1253,12 @@
-
- cat > conftest.$ac_ext << EOF
-
--#line 1253 "configure"
-+#line 1257 "configure"
- #include "confdefs.h"
-
- main(){return(0);}
- EOF
--if { (eval echo configure:1258: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:1262: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- ac_cv_prog_cc_works=yes
- # If we can't run a trivial program, we are probably using a cross compiler.
- if (./conftest; exit) 2>/dev/null; then
-@@ -1280,12 +1284,12 @@
- { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
- fi
- echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
--echo "configure:1284: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
-+echo "configure:1288: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
- echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
- cross_compiling=$ac_cv_prog_cc_cross
-
- echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
--echo "configure:1289: checking whether we are using GNU C" >&5
-+echo "configure:1293: checking whether we are using GNU C" >&5
- if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1294,7 +1298,7 @@
- yes;
- #endif
- EOF
--if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1298: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
-+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1302: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
- ac_cv_prog_gcc=yes
- else
- ac_cv_prog_gcc=no
-@@ -1313,7 +1317,7 @@
- ac_save_CFLAGS="$CFLAGS"
- CFLAGS=
- echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
--echo "configure:1317: checking whether ${CC-cc} accepts -g" >&5
-+echo "configure:1321: checking whether ${CC-cc} accepts -g" >&5
- if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1346,7 +1350,7 @@
-
-
- echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
--echo "configure:1350: checking how to run the C preprocessor" >&5
-+echo "configure:1354: checking how to run the C preprocessor" >&5
- # On Suns, sometimes $CPP names a directory.
- if test -n "$CPP" && test -d "$CPP"; then
- CPP=
-@@ -1361,13 +1365,13 @@
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp.
- cat > conftest.$ac_ext <<EOF
--#line 1365 "configure"
-+#line 1369 "configure"
- #include "confdefs.h"
- #include <assert.h>
- Syntax Error
- EOF
- ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
--{ (eval echo configure:1371: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-+{ (eval echo configure:1375: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
- ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
- if test -z "$ac_err"; then
- :
-@@ -1378,13 +1382,13 @@
- rm -rf conftest*
- CPP="${CC-cc} -E -traditional-cpp"
- cat > conftest.$ac_ext <<EOF
--#line 1382 "configure"
-+#line 1386 "configure"
- #include "confdefs.h"
- #include <assert.h>
- Syntax Error
- EOF
- ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
--{ (eval echo configure:1388: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-+{ (eval echo configure:1392: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
- ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
- if test -z "$ac_err"; then
- :
-@@ -1395,13 +1399,13 @@
- rm -rf conftest*
- CPP="${CC-cc} -nologo -E"
- cat > conftest.$ac_ext <<EOF
--#line 1399 "configure"
-+#line 1403 "configure"
- #include "confdefs.h"
- #include <assert.h>
- Syntax Error
- EOF
- ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
--{ (eval echo configure:1405: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-+{ (eval echo configure:1409: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
- ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
- if test -z "$ac_err"; then
- :
-@@ -1432,7 +1436,7 @@
- END
- # If we don't find an include directive, just comment out the code.
- echo $ac_n "checking for style of include used by $am_make""... $ac_c" 1>&6
--echo "configure:1436: checking for style of include used by $am_make" >&5
-+echo "configure:1440: checking for style of include used by $am_make" >&5
- _am_include='#'
- _am_quote=
- _am_result=none
-@@ -1471,7 +1475,7 @@
-
-
- echo $ac_n "checking dependency style of $depcc""... $ac_c" 1>&6
--echo "configure:1475: checking dependency style of $depcc" >&5
-+echo "configure:1479: checking dependency style of $depcc" >&5
- if eval "test \"`echo '$''{'am_cv_CC_dependencies_compiler_type'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1550,7 +1554,7 @@
- # Extract the first word of "ranlib", so it can be a program name with args.
- set dummy ranlib; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
--echo "configure:1554: checking for $ac_word" >&5
-+echo "configure:1558: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_path_RANLIB'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1587,7 +1591,7 @@
- # Extract the first word of "ranlib", so it can be a program name with args.
- set dummy ranlib; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
--echo "configure:1591: checking for $ac_word" >&5
-+echo "configure:1595: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1627,7 +1631,7 @@
- STAGE1_CFLAGS="-O2"
- GRUB_CFLAGS="-O2"
- echo $ac_n "checking whether optimization for size works""... $ac_c" 1>&6
--echo "configure:1631: checking whether optimization for size works" >&5
-+echo "configure:1635: checking whether optimization for size works" >&5
- if eval "test \"`echo '$''{'size_flag'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1635,14 +1639,14 @@
- saved_CFLAGS=$CFLAGS
- CFLAGS="-Os -g"
- cat > conftest.$ac_ext <<EOF
--#line 1639 "configure"
-+#line 1643 "configure"
- #include "confdefs.h"
-
- int main() {
-
- ; return 0; }
- EOF
--if { (eval echo configure:1646: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:1650: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
- size_flag=yes
- else
-@@ -1674,7 +1678,7 @@
- CPPFLAGS="$CPPFLAGS -Wpointer-arith"
-
- echo $ac_n "checking whether -Wundef works""... $ac_c" 1>&6
--echo "configure:1678: checking whether -Wundef works" >&5
-+echo "configure:1682: checking whether -Wundef works" >&5
- if eval "test \"`echo '$''{'undef_flag'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1682,14 +1686,14 @@
- saved_CPPFLAGS=$CPPFLAGS
- CPPFLAGS="-Wundef"
- cat > conftest.$ac_ext <<EOF
--#line 1686 "configure"
-+#line 1690 "configure"
- #include "confdefs.h"
-
- int main() {
-
- ; return 0; }
- EOF
--if { (eval echo configure:1693: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-+if { (eval echo configure:1697: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
- undef_flag=yes
- else
-@@ -1716,7 +1720,7 @@
- # Extract the first word of "objcopy", so it can be a program name with args.
- set dummy objcopy; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
--echo "configure:1720: checking for $ac_word" >&5
-+echo "configure:1724: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_path_OBJCOPY'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1752,7 +1756,7 @@
- # Extract the first word of "${ac_tool_prefix}objcopy", so it can be a program name with args.
- set dummy ${ac_tool_prefix}objcopy; ac_word=$2
- echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
--echo "configure:1756: checking for $ac_word" >&5
-+echo "configure:1760: checking for $ac_word" >&5
- if eval "test \"`echo '$''{'ac_cv_prog_OBJCOPY'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1786,7 +1790,7 @@
- # Defined in acinclude.m4.
-
- echo $ac_n "checking if C symbols get an underscore after compilation""... $ac_c" 1>&6
--echo "configure:1790: checking if C symbols get an underscore after compilation" >&5
-+echo "configure:1794: checking if C symbols get an underscore after compilation" >&5
- if eval "test \"`echo '$''{'grub_cv_asm_uscore'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1799,7 +1803,7 @@
- }
- EOF
-
--if { ac_try='${CC-cc} ${CFLAGS} -S conftest.c'; { (eval echo configure:1803: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest.s; then
-+if { ac_try='${CC-cc} ${CFLAGS} -S conftest.c'; { (eval echo configure:1807: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest.s; then
- true
- else
- { echo "configure: error: ${CC-cc} failed to produce assembly code" 1>&2; exit 1; }
-@@ -1825,7 +1829,7 @@
- echo "$ac_t""$grub_cv_asm_uscore" 1>&6
-
- echo $ac_n "checking whether ${OBJCOPY} works for absolute addresses""... $ac_c" 1>&6
--echo "configure:1829: checking whether ${OBJCOPY} works for absolute addresses" >&5
-+echo "configure:1833: checking whether ${OBJCOPY} works for absolute addresses" >&5
- if eval "test \"`echo '$''{'grub_cv_prog_objcopy_absolute'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1837,21 +1841,21 @@
- }
- EOF
-
--if { (eval echo configure:1841: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; } && test -s conftest.o; then :
-+if { (eval echo configure:1845: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; } && test -s conftest.o; then :
- else
- { echo "configure: error: ${CC-cc} cannot compile C source code" 1>&2; exit 1; }
- fi
- grub_cv_prog_objcopy_absolute=yes
- for link_addr in 2000 8000 7C00; do
-- if { ac_try='${CC-cc} ${CFLAGS} -nostdlib -Wl,-N -Wl,-Ttext -Wl,$link_addr conftest.o -o conftest.exec'; { (eval echo configure:1847: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then :
-+ if { ac_try='${CC-cc} ${CFLAGS} -nostdlib -Wl,-N -Wl,-Ttext -Wl,$link_addr conftest.o -o conftest.exec'; { (eval echo configure:1851: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then :
- else
- { echo "configure: error: ${CC-cc} cannot link at address $link_addr" 1>&2; exit 1; }
- fi
-- if { ac_try='${OBJCOPY-objcopy} -O binary conftest.exec conftest'; { (eval echo configure:1851: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then :
-+ if { ac_try='${OBJCOPY-objcopy} -O binary conftest.exec conftest'; { (eval echo configure:1855: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then :
- else
- { echo "configure: error: ${OBJCOPY-objcopy} cannot create binary files" 1>&2; exit 1; }
- fi
-- if test ! -f conftest.old || { ac_try='cmp -s conftest.old conftest'; { (eval echo configure:1855: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
-+ if test ! -f conftest.old || { ac_try='cmp -s conftest.old conftest'; { (eval echo configure:1859: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
- mv -f conftest conftest.old
- else
- grub_cv_prog_objcopy_absolute=no
-@@ -1868,7 +1872,7 @@
-
-
- echo $ac_n "checking whether addr32 must be in the same line as the instruction""... $ac_c" 1>&6
--echo "configure:1872: checking whether addr32 must be in the same line as the instruction" >&5
-+echo "configure:1876: checking whether addr32 must be in the same line as the instruction" >&5
- if eval "test \"`echo '$''{'grub_cv_asm_prefix_requirement'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1877,7 +1881,7 @@
- l1: addr32 movb %al, l1
- EOF
-
--if { ac_try='${CC-cc} ${CFLAGS} -c conftest.s'; { (eval echo configure:1881: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest.o; then
-+if { ac_try='${CC-cc} ${CFLAGS} -c conftest.s'; { (eval echo configure:1885: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest.o; then
- grub_cv_asm_prefix_requirement=yes
- else
- grub_cv_asm_prefix_requirement=no
-@@ -1909,7 +1913,7 @@
-
-
- echo $ac_n "checking for .code16 addr32 assembler support""... $ac_c" 1>&6
--echo "configure:1913: checking for .code16 addr32 assembler support" >&5
-+echo "configure:1917: checking for .code16 addr32 assembler support" >&5
- if eval "test \"`echo '$''{'grub_cv_asm_addr32'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1924,7 +1928,7 @@
- sed -e s/@ADDR32@/addr32\;/ < conftest.s.in > conftest.s
- fi
-
--if { ac_try='${CC-cc} ${CFLAGS} -c conftest.s'; { (eval echo configure:1928: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest.o; then
-+if { ac_try='${CC-cc} ${CFLAGS} -c conftest.s'; { (eval echo configure:1932: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest.o; then
- grub_cv_asm_addr32=yes
- else
- grub_cv_asm_addr32=no
-@@ -1941,7 +1945,7 @@
-
-
- echo $ac_n "checking whether an absolute indirect call/jump must not be prefixed with an asterisk""... $ac_c" 1>&6
--echo "configure:1945: checking whether an absolute indirect call/jump must not be prefixed with an asterisk" >&5
-+echo "configure:1949: checking whether an absolute indirect call/jump must not be prefixed with an asterisk" >&5
- if eval "test \"`echo '$''{'grub_cv_asm_absolute_without_asterisk'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
-@@ -1952,7 +1956,7 @@
- .word 0
- EOF
-
--if { ac_try='${CC-cc} ${CFLAGS} -c conftest.s'; { (eval echo configure:1956: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest.o; then
-+if { ac_try='${CC-cc} ${CFLAGS} -c conftest.s'; { (eval echo configure:1960: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest.o; then
- grub_cv_asm_absolute_without_asterisk=no
- else
- grub_cv_asm_absolute_without_asterisk=yes
-@@ -1973,19 +1977,19 @@
-
-
- echo $ac_n "checking if start is defined by the compiler""... $ac_c" 1>&6
--echo "configure:1977: checking if start is defined by the compiler" >&5
-+echo "configure:1981: checking if start is defined by the compiler" >&5
- if eval "test \"`echo '$''{'grub_cv_check_start_symbol'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
- cat > conftest.$ac_ext <<EOF
--#line 1982 "configure"
-+#line 1986 "configure"
- #include "confdefs.h"
-
- int main() {
- asm ("incl start")
- ; return 0; }
- EOF
--if { (eval echo configure:1989: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:1993: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- grub_cv_check_start_symbol=yes
- else
-@@ -2009,19 +2013,19 @@
-
-
- echo $ac_n "checking if _start is defined by the compiler""... $ac_c" 1>&6
--echo "configure:2013: checking if _start is defined by the compiler" >&5
-+echo "configure:2017: checking if _start is defined by the compiler" >&5
- if eval "test \"`echo '$''{'grub_cv_check_uscore_start_symbol'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
- cat > conftest.$ac_ext <<EOF
--#line 2018 "configure"
-+#line 2022 "configure"
- #include "confdefs.h"
-
- int main() {
- asm ("incl _start")
- ; return 0; }
- EOF
--if { (eval echo configure:2025: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:2029: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- grub_cv_check_uscore_start_symbol=yes
- else
-@@ -2050,19 +2054,19 @@
-
-
- echo $ac_n "checking if __bss_start is defined by the compiler""... $ac_c" 1>&6
--echo "configure:2054: checking if __bss_start is defined by the compiler" >&5
-+echo "configure:2058: checking if __bss_start is defined by the compiler" >&5
- if eval "test \"`echo '$''{'grub_cv_check_uscore_uscore_bss_start_symbol'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
- cat > conftest.$ac_ext <<EOF
--#line 2059 "configure"
-+#line 2063 "configure"
- #include "confdefs.h"
-
- int main() {
- asm ("incl __bss_start")
- ; return 0; }
- EOF
--if { (eval echo configure:2066: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:2070: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- grub_cv_check_uscore_uscore_bss_start_symbol=yes
- else
-@@ -2086,19 +2090,19 @@
-
-
- echo $ac_n "checking if _edata is defined by the compiler""... $ac_c" 1>&6
--echo "configure:2090: checking if _edata is defined by the compiler" >&5
-+echo "configure:2094: checking if _edata is defined by the compiler" >&5
- if eval "test \"`echo '$''{'grub_cv_check_uscore_edata_symbol'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
- cat > conftest.$ac_ext <<EOF
--#line 2095 "configure"
-+#line 2099 "configure"
- #include "confdefs.h"
-
- int main() {
- asm ("incl _edata")
- ; return 0; }
- EOF
--if { (eval echo configure:2102: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:2106: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- grub_cv_check_uscore_edata_symbol=yes
- else
-@@ -2122,19 +2126,19 @@
-
-
- echo $ac_n "checking if edata is defined by the compiler""... $ac_c" 1>&6
--echo "configure:2126: checking if edata is defined by the compiler" >&5
-+echo "configure:2130: checking if edata is defined by the compiler" >&5
- if eval "test \"`echo '$''{'grub_cv_check_edata_symbol'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
- cat > conftest.$ac_ext <<EOF
--#line 2131 "configure"
-+#line 2135 "configure"
- #include "confdefs.h"
-
- int main() {
- asm ("incl edata")
- ; return 0; }
- EOF
--if { (eval echo configure:2138: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:2142: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- grub_cv_check_edata_symbol=yes
- else
-@@ -2164,19 +2168,19 @@
-
-
- echo $ac_n "checking if end is defined by the compiler""... $ac_c" 1>&6
--echo "configure:2168: checking if end is defined by the compiler" >&5
-+echo "configure:2172: checking if end is defined by the compiler" >&5
- if eval "test \"`echo '$''{'grub_cv_check_end_symbol'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
- cat > conftest.$ac_ext <<EOF
--#line 2173 "configure"
-+#line 2177 "configure"
- #include "confdefs.h"
-
- int main() {
- asm ("incl end")
- ; return 0; }
- EOF
--if { (eval echo configure:2180: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:2184: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- grub_cv_check_end_symbol=yes
- else
-@@ -2200,19 +2204,19 @@
-
-
- echo $ac_n "checking if _end is defined by the compiler""... $ac_c" 1>&6
--echo "configure:2204: checking if _end is defined by the compiler" >&5
-+echo "configure:2208: checking if _end is defined by the compiler" >&5
- if eval "test \"`echo '$''{'grub_cv_check_uscore_end_symbol'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
- cat > conftest.$ac_ext <<EOF
--#line 2209 "configure"
-+#line 2213 "configure"
- #include "confdefs.h"
-
- int main() {
- asm ("incl _end")
- ; return 0; }
- EOF
--if { (eval echo configure:2216: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:2220: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- grub_cv_check_uscore_end_symbol=yes
- else
-@@ -2250,7 +2254,7 @@
- # Get the filename or the whole disk and open it.
- # Known to work on NetBSD.
- echo $ac_n "checking for opendisk in -lutil""... $ac_c" 1>&6
--echo "configure:2254: checking for opendisk in -lutil" >&5
-+echo "configure:2258: checking for opendisk in -lutil" >&5
- ac_lib_var=`echo util'_'opendisk | sed 'y%./+-%__p_%'`
- if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-@@ -2258,7 +2262,7 @@
- ac_save_LIBS="$LIBS"
- LIBS="-lutil $LIBS"
- cat > conftest.$ac_ext <<EOF
--#line 2262 "configure"
-+#line 2266 "configure"
- #include "confdefs.h"
- /* Override any gcc2 internal prototype to avoid an error. */
- /* We use char because int might match the return type of a gcc2
-@@ -2269,7 +2273,7 @@
- opendisk()
- ; return 0; }
- EOF
--if { (eval echo configure:2273: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:2277: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=yes"
- else
-@@ -2297,7 +2301,7 @@
- # Unless the user specify --without-curses, check for curses.
- if test "x$with_curses" != "xno"; then
- echo $ac_n "checking for wgetch in -lncurses""... $ac_c" 1>&6
--echo "configure:2301: checking for wgetch in -lncurses" >&5
-+echo "configure:2305: checking for wgetch in -lncurses" >&5
- ac_lib_var=`echo ncurses'_'wgetch | sed 'y%./+-%__p_%'`
- if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-@@ -2305,7 +2309,7 @@
- ac_save_LIBS="$LIBS"
- LIBS="-lncurses $LIBS"
- cat > conftest.$ac_ext <<EOF
--#line 2309 "configure"
-+#line 2313 "configure"
- #include "confdefs.h"
- /* Override any gcc2 internal prototype to avoid an error. */
- /* We use char because int might match the return type of a gcc2
-@@ -2316,7 +2320,7 @@
- wgetch()
- ; return 0; }
- EOF
--if { (eval echo configure:2320: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:2324: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=yes"
- else
-@@ -2339,7 +2343,7 @@
- else
- echo "$ac_t""no" 1>&6
- echo $ac_n "checking for wgetch in -lcurses""... $ac_c" 1>&6
--echo "configure:2343: checking for wgetch in -lcurses" >&5
-+echo "configure:2347: checking for wgetch in -lcurses" >&5
- ac_lib_var=`echo curses'_'wgetch | sed 'y%./+-%__p_%'`
- if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-@@ -2347,7 +2351,7 @@
- ac_save_LIBS="$LIBS"
- LIBS="-lcurses $LIBS"
- cat > conftest.$ac_ext <<EOF
--#line 2351 "configure"
-+#line 2355 "configure"
- #include "confdefs.h"
- /* Override any gcc2 internal prototype to avoid an error. */
- /* We use char because int might match the return type of a gcc2
-@@ -2358,7 +2362,7 @@
- wgetch()
- ; return 0; }
- EOF
--if { (eval echo configure:2362: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-+if { (eval echo configure:2366: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_lib_$ac_lib_var=yes"
- else
-@@ -2393,17 +2397,17 @@
- do
- ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
- echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
--echo "configure:2397: checking for $ac_hdr" >&5
-+echo "configure:2401: checking for $ac_hdr" >&5
- if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
- cat > conftest.$ac_ext <<EOF
--#line 2402 "configure"
-+#line 2406 "configure"
- #include "confdefs.h"
- #include <$ac_hdr>
- EOF
- ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
--{ (eval echo configure:2407: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-+{ (eval echo configure:2411: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
- ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
- if test -z "$ac_err"; then
- rm -rf conftest*
-@@ -2488,6 +2492,28 @@
- FSYS_CFLAGS="$FSYS_CFLAGS -DFSYS_REISERFS=1"
- fi
-
-+# Check whether --enable-jfs or --disable-jfs was given.
-+if test "${enable_jfs+set}" = set; then
-+ enableval="$enable_jfs"
-+ :
-+fi
-+
-+
-+if test x"$enable_jfs" != xno; then
-+ FSYS_CFLAGS="$FSYS_CFLAGS -DFSYS_JFS=1"
-+fi
-+
-+# Check whether --enable-xfs or --disable-xfs was given.
-+if test "${enable_xfs+set}" = set; then
-+ enableval="$enable_xfs"
-+ :
-+fi
-+
-+
-+if test x"$enable_xfs" != xno; then
-+ FSYS_CFLAGS="$FSYS_CFLAGS -DFSYS_XFS=1"
-+fi
-+
- # Check whether --enable-vstafs or --disable-vstafs was given.
- if test "${enable_vstafs+set}" = set; then
- enableval="$enable_vstafs"
-@@ -3039,7 +3065,7 @@
- }
- EOF
-
--if { ac_try='${CC-cc} ${CFLAGS} conftest.c -o conftest'; { (eval echo configure:3043: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest; then
-+if { ac_try='${CC-cc} ${CFLAGS} conftest.c -o conftest'; { (eval echo configure:3069: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } && test -s conftest; then
- grub_tmp_value=`./conftest < "$enable_preset_menu"`
- else
- { echo "configure: error: ${CC-cc} failed to produce an executable file" 1>&2; exit 1; }
-diff -urN --exclude-from=xlist-build grub-0.90/docs/Makefile.in grub-0.90.jfs+xfs/docs/Makefile.in
---- grub-0.90/docs/Makefile.in Thu Jul 5 15:29:56 2001
-+++ grub-0.90.jfs+xfs/docs/Makefile.in Thu Aug 23 18:21:23 2001
-@@ -284,11 +284,11 @@
- done
-
- mostlyclean-aminfo:
-- -rm -f grub.aux grub.cp grub.cps grub.dvi grub.fn grub.ky grub.log grub.pg \
-- grub.ps grub.toc grub.tp grub.vr multiboot.aux multiboot.cp \
-- multiboot.cps multiboot.dvi multiboot.fn multiboot.ky \
-- multiboot.log multiboot.pg multiboot.ps multiboot.toc \
-- multiboot.tp multiboot.vr
-+ -rm -f grub.aux grub.cp grub.dvi grub.fn grub.ky grub.log grub.pg grub.ps \
-+ grub.toc grub.tp grub.vr multiboot.aux multiboot.cp \
-+ multiboot.dvi multiboot.fn multiboot.ky multiboot.log \
-+ multiboot.pg multiboot.ps multiboot.toc multiboot.tp \
-+ multiboot.vr
-
- maintainer-clean-aminfo:
- cd $(srcdir) && \
-diff -urN --exclude-from=xlist-build grub-0.90/stage2/Makefile.in grub-0.90.jfs+xfs/stage2/Makefile.in
---- grub-0.90/stage2/Makefile.in Wed Jul 4 11:33:48 2001
-+++ grub-0.90.jfs+xfs/stage2/Makefile.in Thu Aug 23 18:21:23 2001
-@@ -93,7 +93,7 @@
-
- # For dist target.
- noinst_HEADERS = apic.h defs.h dir.h disk_inode.h disk_inode_ffs.h \
-- fat.h filesys.h freebsd.h fs.h hercules.h i386-elf.h \
-+ fat.h jfs.h xfs.h filesys.h freebsd.h fs.h hercules.h i386-elf.h \
- imgact_aout.h mb_header.h mb_info.h md5.h pc_slice.h serial.h \
- shared.h smp-imps.h nbi.h vstafs.h
-
-@@ -106,32 +106,37 @@
- noinst_LIBRARIES = libgrub.a
- libgrub_a_SOURCES = boot.c builtins.c common.c char_io.c cmdline.c \
- disk_io.c gunzip.c fsys_ffs.c fsys_ext2fs.c fsys_fat.c \
-- fsys_minix.c fsys_reiserfs.c fsys_vstafs.c stage2.c md5.c
-+ fsys_minix.c fsys_reiserfs.c fsys_jfs.c fsys_xfs.c fsys_vstafs.c \
-+ stage2.c md5.c
-
- libgrub_a_CFLAGS = $(GRUB_CFLAGS) -I$(top_srcdir)/lib \
- -DGRUB_UTIL=1 -DFSYS_EXT2FS=1 -DFSYS_FAT=1 -DFSYS_FFS=1 \
-- -DFSYS_MINIX=1 -DFSYS_REISERFS=1 -DFSYS_VSTAFS=1 \
-- -DSUPPORT_SERIAL=1 -DSUPPORT_HERCULES=1 -fwritable-strings
-+ -DFSYS_MINIX=1 -DFSYS_REISERFS=1 -DFSYS_JFS=1 -DFSYS_XFS=1 \
-+ -DFSYS_VSTAFS=1 -DSUPPORT_SERIAL=1 -DSUPPORT_HERCULES=1 \
-+ -fwritable-strings
-
-
- EXTRA_PROGRAMS = nbloader.exec pxeloader.exec diskless.exec
-
- @DISKLESS_SUPPORT_TRUE@pkgdata_DATA = stage2 e2fs_stage1_5 fat_stage1_5 ffs_stage1_5 \
--@DISKLESS_SUPPORT_TRUE@ minix_stage1_5 reiserfs_stage1_5 vstafs_stage1_5 nbgrub pxegrub
-+@DISKLESS_SUPPORT_TRUE@ minix_stage1_5 reiserfs_stage1_5 jfs_stage1_5 xfs_stage1_5 \
-+@DISKLESS_SUPPORT_TRUE@ vstafs_stage1_5 nbgrub pxegrub
-
- @DISKLESS_SUPPORT_FALSE@pkgdata_DATA = stage2 e2fs_stage1_5 fat_stage1_5 ffs_stage1_5 \
--@DISKLESS_SUPPORT_FALSE@ minix_stage1_5 reiserfs_stage1_5 vstafs_stage1_5
-+@DISKLESS_SUPPORT_FALSE@ minix_stage1_5 reiserfs_stage1_5 jfs_stage1_5 xfs_stage1_5 \
-+@DISKLESS_SUPPORT_FALSE@ vstafs_stage1_5
-
- @DISKLESS_SUPPORT_TRUE@noinst_DATA = pre_stage2 start nbloader pxeloader diskless
- @DISKLESS_SUPPORT_FALSE@noinst_DATA = pre_stage2 start
- @DISKLESS_SUPPORT_TRUE@noinst_PROGRAMS = pre_stage2.exec start.exec e2fs_stage1_5.exec \
- @DISKLESS_SUPPORT_TRUE@ fat_stage1_5.exec ffs_stage1_5.exec minix_stage1_5.exec \
--@DISKLESS_SUPPORT_TRUE@ reiserfs_stage1_5.exec vstafs_stage1_5.exec nbloader.exec \
--@DISKLESS_SUPPORT_TRUE@ pxeloader.exec diskless.exec
-+@DISKLESS_SUPPORT_TRUE@ reiserfs_stage1_5.exec jfs_stage1_5.exec xfs_stage1_5.exec \
-+@DISKLESS_SUPPORT_TRUE@ vstafs_stage1_5.exec nbloader.exec pxeloader.exec diskless.exec
-
- @DISKLESS_SUPPORT_FALSE@noinst_PROGRAMS = pre_stage2.exec start.exec e2fs_stage1_5.exec \
- @DISKLESS_SUPPORT_FALSE@ fat_stage1_5.exec ffs_stage1_5.exec minix_stage1_5.exec \
--@DISKLESS_SUPPORT_FALSE@ reiserfs_stage1_5.exec vstafs_stage1_5.exec
-+@DISKLESS_SUPPORT_FALSE@ reiserfs_stage1_5.exec jfs_stage1_5.exec xfs_stage1_5.exec \
-+@DISKLESS_SUPPORT_FALSE@ vstafs_stage1_5.exec
-
- MOSTLYCLEANFILES = $(noinst_PROGRAMS)
-
-@@ -160,7 +165,8 @@
- pre_stage2_exec_SOURCES = asm.S bios.c boot.c builtins.c common.c \
- char_io.c cmdline.c disk_io.c gunzip.c fsys_ext2fs.c \
- fsys_fat.c fsys_ffs.c fsys_minix.c fsys_reiserfs.c \
-- fsys_vstafs.c hercules.c serial.c smp-imps.c stage2.c md5.c
-+ fsys_jfs.c fsys_xfs.c fsys_vstafs.c hercules.c serial.c \
-+ smp-imps.c stage2.c md5.c
-
- pre_stage2_exec_CFLAGS = $(STAGE2_COMPILE) $(FSYS_CFLAGS)
- pre_stage2_exec_ASFLAGS = $(STAGE2_COMPILE) $(FSYS_CFLAGS)
-@@ -237,6 +243,30 @@
-
- reiserfs_stage1_5_exec_LDFLAGS = $(STAGE1_5_LINK)
-
-+# For jfs_stage1_5 target.
-+jfs_stage1_5_exec_SOURCES = start.S asm.S common.c char_io.c \
-+ disk_io.c stage1_5.c fsys_jfs.c bios.c
-+
-+jfs_stage1_5_exec_CFLAGS = $(STAGE1_5_COMPILE) -DFSYS_JFS=1 \
-+ -DNO_BLOCK_FILES=1
-+
-+jfs_stage1_5_exec_ASFLAGS = $(STAGE1_5_COMPILE) -DFSYS_JFS=1 \
-+ -DNO_BLOCK_FILES=1
-+
-+jfs_stage1_5_exec_LDFLAGS = $(STAGE1_5_LINK)
-+
-+# For xfs_stage1_5 target.
-+xfs_stage1_5_exec_SOURCES = start.S asm.S common.c char_io.c \
-+ disk_io.c stage1_5.c fsys_xfs.c bios.c
-+
-+xfs_stage1_5_exec_CFLAGS = $(STAGE1_5_COMPILE) -DFSYS_XFS=1 \
-+ -DNO_BLOCK_FILES=1
-+
-+xfs_stage1_5_exec_ASFLAGS = $(STAGE1_5_COMPILE) -DFSYS_XFS=1 \
-+ -DNO_BLOCK_FILES=1
-+
-+xfs_stage1_5_exec_LDFLAGS = $(STAGE1_5_LINK)
-+
- # For vstafs_stage1_5 target.
- vstafs_stage1_5_exec_SOURCES = start.S asm.S common.c char_io.c \
- disk_io.c stage1_5.c fsys_vstafs.c bios.c
-@@ -285,21 +315,23 @@
- libgrub_a-disk_io.$(OBJEXT) libgrub_a-gunzip.$(OBJEXT) \
- libgrub_a-fsys_ffs.$(OBJEXT) libgrub_a-fsys_ext2fs.$(OBJEXT) \
- libgrub_a-fsys_fat.$(OBJEXT) libgrub_a-fsys_minix.$(OBJEXT) \
-- libgrub_a-fsys_reiserfs.$(OBJEXT) \
-- libgrub_a-fsys_vstafs.$(OBJEXT) libgrub_a-stage2.$(OBJEXT) \
-- libgrub_a-md5.$(OBJEXT)
-+ libgrub_a-fsys_reiserfs.$(OBJEXT) libgrub_a-fsys_jfs.$(OBJEXT) \
-+ libgrub_a-fsys_xfs.$(OBJEXT) libgrub_a-fsys_vstafs.$(OBJEXT) \
-+ libgrub_a-stage2.$(OBJEXT) libgrub_a-md5.$(OBJEXT)
- libgrub_a_OBJECTS = $(am_libgrub_a_OBJECTS)
- EXTRA_PROGRAMS = nbloader.exec pxeloader.exec diskless.exec
- @DISKLESS_SUPPORT_TRUE@noinst_PROGRAMS = pre_stage2.exec start.exec \
- @DISKLESS_SUPPORT_TRUE@ e2fs_stage1_5.exec fat_stage1_5.exec \
- @DISKLESS_SUPPORT_TRUE@ ffs_stage1_5.exec minix_stage1_5.exec \
--@DISKLESS_SUPPORT_TRUE@ reiserfs_stage1_5.exec \
--@DISKLESS_SUPPORT_TRUE@ vstafs_stage1_5.exec nbloader.exec \
--@DISKLESS_SUPPORT_TRUE@ pxeloader.exec diskless.exec
-+@DISKLESS_SUPPORT_TRUE@ reiserfs_stage1_5.exec jfs_stage1_5.exec \
-+@DISKLESS_SUPPORT_TRUE@ xfs_stage1_5.exec vstafs_stage1_5.exec \
-+@DISKLESS_SUPPORT_TRUE@ nbloader.exec pxeloader.exec \
-+@DISKLESS_SUPPORT_TRUE@ diskless.exec
- @DISKLESS_SUPPORT_FALSE@noinst_PROGRAMS = pre_stage2.exec start.exec \
- @DISKLESS_SUPPORT_FALSE@ e2fs_stage1_5.exec fat_stage1_5.exec \
- @DISKLESS_SUPPORT_FALSE@ ffs_stage1_5.exec minix_stage1_5.exec \
- @DISKLESS_SUPPORT_FALSE@ reiserfs_stage1_5.exec \
-+@DISKLESS_SUPPORT_FALSE@ jfs_stage1_5.exec xfs_stage1_5.exec \
- @DISKLESS_SUPPORT_FALSE@ vstafs_stage1_5.exec
- PROGRAMS = $(noinst_PROGRAMS)
-
-@@ -313,6 +345,8 @@
- diskless_exec-fsys_ffs.$(OBJEXT) \
- diskless_exec-fsys_minix.$(OBJEXT) \
- diskless_exec-fsys_reiserfs.$(OBJEXT) \
-+ diskless_exec-fsys_jfs.$(OBJEXT) \
-+ diskless_exec-fsys_xfs.$(OBJEXT) \
- diskless_exec-fsys_vstafs.$(OBJEXT) \
- diskless_exec-hercules.$(OBJEXT) diskless_exec-serial.$(OBJEXT) \
- diskless_exec-smp-imps.$(OBJEXT) diskless_exec-stage2.$(OBJEXT) \
-@@ -352,6 +386,17 @@
- ffs_stage1_5_exec_OBJECTS = $(am_ffs_stage1_5_exec_OBJECTS)
- ffs_stage1_5_exec_LDADD = $(LDADD)
- ffs_stage1_5_exec_DEPENDENCIES =
-+am_jfs_stage1_5_exec_OBJECTS = jfs_stage1_5_exec-start.$(OBJEXT) \
-+ jfs_stage1_5_exec-asm.$(OBJEXT) \
-+ jfs_stage1_5_exec-common.$(OBJEXT) \
-+ jfs_stage1_5_exec-char_io.$(OBJEXT) \
-+ jfs_stage1_5_exec-disk_io.$(OBJEXT) \
-+ jfs_stage1_5_exec-stage1_5.$(OBJEXT) \
-+ jfs_stage1_5_exec-fsys_jfs.$(OBJEXT) \
-+ jfs_stage1_5_exec-bios.$(OBJEXT)
-+jfs_stage1_5_exec_OBJECTS = $(am_jfs_stage1_5_exec_OBJECTS)
-+jfs_stage1_5_exec_LDADD = $(LDADD)
-+jfs_stage1_5_exec_DEPENDENCIES =
- am_minix_stage1_5_exec_OBJECTS = minix_stage1_5_exec-start.$(OBJEXT) \
- minix_stage1_5_exec-asm.$(OBJEXT) \
- minix_stage1_5_exec-common.$(OBJEXT) \
-@@ -380,6 +425,8 @@
- pre_stage2_exec-fsys_ffs.$(OBJEXT) \
- pre_stage2_exec-fsys_minix.$(OBJEXT) \
- pre_stage2_exec-fsys_reiserfs.$(OBJEXT) \
-+ pre_stage2_exec-fsys_jfs.$(OBJEXT) \
-+ pre_stage2_exec-fsys_xfs.$(OBJEXT) \
- pre_stage2_exec-fsys_vstafs.$(OBJEXT) \
- pre_stage2_exec-hercules.$(OBJEXT) \
- pre_stage2_exec-serial.$(OBJEXT) \
-@@ -420,6 +467,17 @@
- vstafs_stage1_5_exec_OBJECTS = $(am_vstafs_stage1_5_exec_OBJECTS)
- vstafs_stage1_5_exec_LDADD = $(LDADD)
- vstafs_stage1_5_exec_DEPENDENCIES =
-+am_xfs_stage1_5_exec_OBJECTS = xfs_stage1_5_exec-start.$(OBJEXT) \
-+ xfs_stage1_5_exec-asm.$(OBJEXT) \
-+ xfs_stage1_5_exec-common.$(OBJEXT) \
-+ xfs_stage1_5_exec-char_io.$(OBJEXT) \
-+ xfs_stage1_5_exec-disk_io.$(OBJEXT) \
-+ xfs_stage1_5_exec-stage1_5.$(OBJEXT) \
-+ xfs_stage1_5_exec-fsys_xfs.$(OBJEXT) \
-+ xfs_stage1_5_exec-bios.$(OBJEXT)
-+xfs_stage1_5_exec_OBJECTS = $(am_xfs_stage1_5_exec_OBJECTS)
-+xfs_stage1_5_exec_LDADD = $(LDADD)
-+xfs_stage1_5_exec_DEPENDENCIES =
- SCRIPTS = $(noinst_SCRIPTS)
-
-
-@@ -439,9 +497,11 @@
- @AMDEP_TRUE@ $(DEPDIR)/diskless_exec-fsys_ext2fs.Po \
- @AMDEP_TRUE@ $(DEPDIR)/diskless_exec-fsys_fat.Po \
- @AMDEP_TRUE@ $(DEPDIR)/diskless_exec-fsys_ffs.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/diskless_exec-fsys_jfs.Po \
- @AMDEP_TRUE@ $(DEPDIR)/diskless_exec-fsys_minix.Po \
- @AMDEP_TRUE@ $(DEPDIR)/diskless_exec-fsys_reiserfs.Po \
- @AMDEP_TRUE@ $(DEPDIR)/diskless_exec-fsys_vstafs.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/diskless_exec-fsys_xfs.Po \
- @AMDEP_TRUE@ $(DEPDIR)/diskless_exec-gunzip.Po \
- @AMDEP_TRUE@ $(DEPDIR)/diskless_exec-hercules.Po \
- @AMDEP_TRUE@ $(DEPDIR)/diskless_exec-md5.Po \
-@@ -466,6 +526,12 @@
- @AMDEP_TRUE@ $(DEPDIR)/ffs_stage1_5_exec-disk_io.Po \
- @AMDEP_TRUE@ $(DEPDIR)/ffs_stage1_5_exec-fsys_ffs.Po \
- @AMDEP_TRUE@ $(DEPDIR)/ffs_stage1_5_exec-stage1_5.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/jfs_stage1_5_exec-bios.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/jfs_stage1_5_exec-char_io.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/jfs_stage1_5_exec-common.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/jfs_stage1_5_exec-disk_io.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/jfs_stage1_5_exec-fsys_jfs.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/jfs_stage1_5_exec-stage1_5.Po \
- @AMDEP_TRUE@ $(DEPDIR)/libgrub_a-boot.Po \
- @AMDEP_TRUE@ $(DEPDIR)/libgrub_a-builtins.Po \
- @AMDEP_TRUE@ $(DEPDIR)/libgrub_a-char_io.Po \
-@@ -475,9 +541,11 @@
- @AMDEP_TRUE@ $(DEPDIR)/libgrub_a-fsys_ext2fs.Po \
- @AMDEP_TRUE@ $(DEPDIR)/libgrub_a-fsys_fat.Po \
- @AMDEP_TRUE@ $(DEPDIR)/libgrub_a-fsys_ffs.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/libgrub_a-fsys_jfs.Po \
- @AMDEP_TRUE@ $(DEPDIR)/libgrub_a-fsys_minix.Po \
- @AMDEP_TRUE@ $(DEPDIR)/libgrub_a-fsys_reiserfs.Po \
- @AMDEP_TRUE@ $(DEPDIR)/libgrub_a-fsys_vstafs.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/libgrub_a-fsys_xfs.Po \
- @AMDEP_TRUE@ $(DEPDIR)/libgrub_a-gunzip.Po \
- @AMDEP_TRUE@ $(DEPDIR)/libgrub_a-md5.Po \
- @AMDEP_TRUE@ $(DEPDIR)/libgrub_a-stage2.Po \
-@@ -497,9 +565,11 @@
- @AMDEP_TRUE@ $(DEPDIR)/pre_stage2_exec-fsys_ext2fs.Po \
- @AMDEP_TRUE@ $(DEPDIR)/pre_stage2_exec-fsys_fat.Po \
- @AMDEP_TRUE@ $(DEPDIR)/pre_stage2_exec-fsys_ffs.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/pre_stage2_exec-fsys_jfs.Po \
- @AMDEP_TRUE@ $(DEPDIR)/pre_stage2_exec-fsys_minix.Po \
- @AMDEP_TRUE@ $(DEPDIR)/pre_stage2_exec-fsys_reiserfs.Po \
- @AMDEP_TRUE@ $(DEPDIR)/pre_stage2_exec-fsys_vstafs.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/pre_stage2_exec-fsys_xfs.Po \
- @AMDEP_TRUE@ $(DEPDIR)/pre_stage2_exec-gunzip.Po \
- @AMDEP_TRUE@ $(DEPDIR)/pre_stage2_exec-hercules.Po \
- @AMDEP_TRUE@ $(DEPDIR)/pre_stage2_exec-md5.Po \
-@@ -517,7 +587,13 @@
- @AMDEP_TRUE@ $(DEPDIR)/vstafs_stage1_5_exec-common.Po \
- @AMDEP_TRUE@ $(DEPDIR)/vstafs_stage1_5_exec-disk_io.Po \
- @AMDEP_TRUE@ $(DEPDIR)/vstafs_stage1_5_exec-fsys_vstafs.Po \
--@AMDEP_TRUE@ $(DEPDIR)/vstafs_stage1_5_exec-stage1_5.Po
-+@AMDEP_TRUE@ $(DEPDIR)/vstafs_stage1_5_exec-stage1_5.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/xfs_stage1_5_exec-bios.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/xfs_stage1_5_exec-char_io.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/xfs_stage1_5_exec-common.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/xfs_stage1_5_exec-disk_io.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/xfs_stage1_5_exec-fsys_xfs.Po \
-+@AMDEP_TRUE@ $(DEPDIR)/xfs_stage1_5_exec-stage1_5.Po
- ASCOMPILE = $(AS) $(AM_ASFLAGS) $(ASFLAGS)
- COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
- $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-@@ -526,16 +602,17 @@
- CFLAGS = @CFLAGS@
- DIST_SOURCES = $(libgrub_a_SOURCES) $(diskless_exec_SOURCES) \
- $(e2fs_stage1_5_exec_SOURCES) $(fat_stage1_5_exec_SOURCES) \
-- $(ffs_stage1_5_exec_SOURCES) $(minix_stage1_5_exec_SOURCES) \
-- $(nbloader_exec_SOURCES) $(pre_stage2_exec_SOURCES) \
-- $(pxeloader_exec_SOURCES) $(reiserfs_stage1_5_exec_SOURCES) \
-- $(start_exec_SOURCES) $(vstafs_stage1_5_exec_SOURCES)
-+ $(ffs_stage1_5_exec_SOURCES) $(jfs_stage1_5_exec_SOURCES) \
-+ $(minix_stage1_5_exec_SOURCES) $(nbloader_exec_SOURCES) \
-+ $(pre_stage2_exec_SOURCES) $(pxeloader_exec_SOURCES) \
-+ $(reiserfs_stage1_5_exec_SOURCES) $(start_exec_SOURCES) \
-+ $(vstafs_stage1_5_exec_SOURCES) $(xfs_stage1_5_exec_SOURCES)
- DATA = $(noinst_DATA) $(pkgdata_DATA)
-
- HEADERS = $(noinst_HEADERS)
-
- DIST_COMMON = $(noinst_HEADERS) Makefile.am Makefile.in compile
--SOURCES = $(libgrub_a_SOURCES) $(diskless_exec_SOURCES) $(e2fs_stage1_5_exec_SOURCES) $(fat_stage1_5_exec_SOURCES) $(ffs_stage1_5_exec_SOURCES) $(minix_stage1_5_exec_SOURCES) $(nbloader_exec_SOURCES) $(pre_stage2_exec_SOURCES) $(pxeloader_exec_SOURCES) $(reiserfs_stage1_5_exec_SOURCES) $(start_exec_SOURCES) $(vstafs_stage1_5_exec_SOURCES)
-+SOURCES = $(libgrub_a_SOURCES) $(diskless_exec_SOURCES) $(e2fs_stage1_5_exec_SOURCES) $(fat_stage1_5_exec_SOURCES) $(ffs_stage1_5_exec_SOURCES) $(jfs_stage1_5_exec_SOURCES) $(minix_stage1_5_exec_SOURCES) $(nbloader_exec_SOURCES) $(pre_stage2_exec_SOURCES) $(pxeloader_exec_SOURCES) $(reiserfs_stage1_5_exec_SOURCES) $(start_exec_SOURCES) $(vstafs_stage1_5_exec_SOURCES) $(xfs_stage1_5_exec_SOURCES)
-
- all: $(BUILT_SOURCES)
- $(MAKE) $(AM_MAKEFLAGS) all-am
-@@ -566,6 +643,8 @@
- libgrub_a-fsys_fat.$(OBJEXT): fsys_fat.c
- libgrub_a-fsys_minix.$(OBJEXT): fsys_minix.c
- libgrub_a-fsys_reiserfs.$(OBJEXT): fsys_reiserfs.c
-+libgrub_a-fsys_jfs.$(OBJEXT): fsys_jfs.c
-+libgrub_a-fsys_xfs.$(OBJEXT): fsys_xfs.c
- libgrub_a-fsys_vstafs.$(OBJEXT): fsys_vstafs.c
- libgrub_a-stage2.$(OBJEXT): stage2.c
- libgrub_a-md5.$(OBJEXT): md5.c
-@@ -590,6 +669,8 @@
- diskless_exec-fsys_ffs.$(OBJEXT): fsys_ffs.c
- diskless_exec-fsys_minix.$(OBJEXT): fsys_minix.c
- diskless_exec-fsys_reiserfs.$(OBJEXT): fsys_reiserfs.c
-+diskless_exec-fsys_jfs.$(OBJEXT): fsys_jfs.c
-+diskless_exec-fsys_xfs.$(OBJEXT): fsys_xfs.c
- diskless_exec-fsys_vstafs.$(OBJEXT): fsys_vstafs.c
- diskless_exec-hercules.$(OBJEXT): hercules.c
- diskless_exec-serial.$(OBJEXT): serial.c
-@@ -632,6 +713,17 @@
- ffs_stage1_5.exec$(EXEEXT): $(ffs_stage1_5_exec_OBJECTS) $(ffs_stage1_5_exec_DEPENDENCIES)
- @rm -f ffs_stage1_5.exec$(EXEEXT)
- $(LINK) $(ffs_stage1_5_exec_LDFLAGS) $(ffs_stage1_5_exec_OBJECTS) $(ffs_stage1_5_exec_LDADD) $(LIBS)
-+jfs_stage1_5_exec-start.$(OBJEXT): start.S
-+jfs_stage1_5_exec-asm.$(OBJEXT): asm.S
-+jfs_stage1_5_exec-common.$(OBJEXT): common.c
-+jfs_stage1_5_exec-char_io.$(OBJEXT): char_io.c
-+jfs_stage1_5_exec-disk_io.$(OBJEXT): disk_io.c
-+jfs_stage1_5_exec-stage1_5.$(OBJEXT): stage1_5.c
-+jfs_stage1_5_exec-fsys_jfs.$(OBJEXT): fsys_jfs.c
-+jfs_stage1_5_exec-bios.$(OBJEXT): bios.c
-+jfs_stage1_5.exec$(EXEEXT): $(jfs_stage1_5_exec_OBJECTS) $(jfs_stage1_5_exec_DEPENDENCIES)
-+ @rm -f jfs_stage1_5.exec$(EXEEXT)
-+ $(LINK) $(jfs_stage1_5_exec_LDFLAGS) $(jfs_stage1_5_exec_OBJECTS) $(jfs_stage1_5_exec_LDADD) $(LIBS)
- minix_stage1_5_exec-start.$(OBJEXT): start.S
- minix_stage1_5_exec-asm.$(OBJEXT): asm.S
- minix_stage1_5_exec-common.$(OBJEXT): common.c
-@@ -661,6 +753,8 @@
- pre_stage2_exec-fsys_ffs.$(OBJEXT): fsys_ffs.c
- pre_stage2_exec-fsys_minix.$(OBJEXT): fsys_minix.c
- pre_stage2_exec-fsys_reiserfs.$(OBJEXT): fsys_reiserfs.c
-+pre_stage2_exec-fsys_jfs.$(OBJEXT): fsys_jfs.c
-+pre_stage2_exec-fsys_xfs.$(OBJEXT): fsys_xfs.c
- pre_stage2_exec-fsys_vstafs.$(OBJEXT): fsys_vstafs.c
- pre_stage2_exec-hercules.$(OBJEXT): hercules.c
- pre_stage2_exec-serial.$(OBJEXT): serial.c
-@@ -700,6 +794,17 @@
- vstafs_stage1_5.exec$(EXEEXT): $(vstafs_stage1_5_exec_OBJECTS) $(vstafs_stage1_5_exec_DEPENDENCIES)
- @rm -f vstafs_stage1_5.exec$(EXEEXT)
- $(LINK) $(vstafs_stage1_5_exec_LDFLAGS) $(vstafs_stage1_5_exec_OBJECTS) $(vstafs_stage1_5_exec_LDADD) $(LIBS)
-+xfs_stage1_5_exec-start.$(OBJEXT): start.S
-+xfs_stage1_5_exec-asm.$(OBJEXT): asm.S
-+xfs_stage1_5_exec-common.$(OBJEXT): common.c
-+xfs_stage1_5_exec-char_io.$(OBJEXT): char_io.c
-+xfs_stage1_5_exec-disk_io.$(OBJEXT): disk_io.c
-+xfs_stage1_5_exec-stage1_5.$(OBJEXT): stage1_5.c
-+xfs_stage1_5_exec-fsys_xfs.$(OBJEXT): fsys_xfs.c
-+xfs_stage1_5_exec-bios.$(OBJEXT): bios.c
-+xfs_stage1_5.exec$(EXEEXT): $(xfs_stage1_5_exec_OBJECTS) $(xfs_stage1_5_exec_DEPENDENCIES)
-+ @rm -f xfs_stage1_5.exec$(EXEEXT)
-+ $(LINK) $(xfs_stage1_5_exec_LDFLAGS) $(xfs_stage1_5_exec_OBJECTS) $(xfs_stage1_5_exec_LDADD) $(LIBS)
-
- mostlyclean-compile:
- -rm -f *.$(OBJEXT) core *.core
-@@ -717,9 +822,11 @@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/diskless_exec-fsys_ext2fs.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/diskless_exec-fsys_fat.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/diskless_exec-fsys_ffs.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/diskless_exec-fsys_jfs.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/diskless_exec-fsys_minix.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/diskless_exec-fsys_reiserfs.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/diskless_exec-fsys_vstafs.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/diskless_exec-fsys_xfs.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/diskless_exec-gunzip.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/diskless_exec-hercules.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/diskless_exec-md5.Po@_am_quote@
-@@ -744,6 +851,12 @@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/ffs_stage1_5_exec-disk_io.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/ffs_stage1_5_exec-fsys_ffs.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/ffs_stage1_5_exec-stage1_5.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/jfs_stage1_5_exec-bios.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/jfs_stage1_5_exec-char_io.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/jfs_stage1_5_exec-common.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/jfs_stage1_5_exec-disk_io.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/jfs_stage1_5_exec-fsys_jfs.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/jfs_stage1_5_exec-stage1_5.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/libgrub_a-boot.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/libgrub_a-builtins.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/libgrub_a-char_io.Po@_am_quote@
-@@ -753,9 +866,11 @@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/libgrub_a-fsys_ext2fs.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/libgrub_a-fsys_fat.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/libgrub_a-fsys_ffs.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/libgrub_a-fsys_jfs.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/libgrub_a-fsys_minix.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/libgrub_a-fsys_reiserfs.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/libgrub_a-fsys_vstafs.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/libgrub_a-fsys_xfs.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/libgrub_a-gunzip.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/libgrub_a-md5.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/libgrub_a-stage2.Po@_am_quote@
-@@ -775,9 +890,11 @@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/pre_stage2_exec-fsys_ext2fs.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/pre_stage2_exec-fsys_fat.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/pre_stage2_exec-fsys_ffs.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/pre_stage2_exec-fsys_jfs.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/pre_stage2_exec-fsys_minix.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/pre_stage2_exec-fsys_reiserfs.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/pre_stage2_exec-fsys_vstafs.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/pre_stage2_exec-fsys_xfs.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/pre_stage2_exec-gunzip.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/pre_stage2_exec-hercules.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/pre_stage2_exec-md5.Po@_am_quote@
-@@ -796,6 +913,12 @@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/vstafs_stage1_5_exec-disk_io.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/vstafs_stage1_5_exec-fsys_vstafs.Po@_am_quote@
- @AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/vstafs_stage1_5_exec-stage1_5.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/xfs_stage1_5_exec-bios.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/xfs_stage1_5_exec-char_io.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/xfs_stage1_5_exec-common.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/xfs_stage1_5_exec-disk_io.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/xfs_stage1_5_exec-fsys_xfs.Po@_am_quote@
-+@AMDEP_TRUE@@_am_include@ @_am_quote@$(DEPDIR)/xfs_stage1_5_exec-stage1_5.Po@_am_quote@
-
- distclean-depend:
- -rm -rf $(DEPDIR)
-@@ -848,6 +971,18 @@
- ffs_stage1_5_exec-asm.obj: asm.S
- $(AS) $(ffs_stage1_5_exec_ASFLAGS) $(ASFLAGS) -c -o ffs_stage1_5_exec-asm.obj `cygpath -w asm.S`
-
-+jfs_stage1_5_exec-start.o: start.S
-+ $(AS) $(jfs_stage1_5_exec_ASFLAGS) $(ASFLAGS) -c -o jfs_stage1_5_exec-start.o `test -f start.S || echo '$(srcdir)/'`start.S
-+
-+jfs_stage1_5_exec-start.obj: start.S
-+ $(AS) $(jfs_stage1_5_exec_ASFLAGS) $(ASFLAGS) -c -o jfs_stage1_5_exec-start.obj `cygpath -w start.S`
-+
-+jfs_stage1_5_exec-asm.o: asm.S
-+ $(AS) $(jfs_stage1_5_exec_ASFLAGS) $(ASFLAGS) -c -o jfs_stage1_5_exec-asm.o `test -f asm.S || echo '$(srcdir)/'`asm.S
-+
-+jfs_stage1_5_exec-asm.obj: asm.S
-+ $(AS) $(jfs_stage1_5_exec_ASFLAGS) $(ASFLAGS) -c -o jfs_stage1_5_exec-asm.obj `cygpath -w asm.S`
-+
- minix_stage1_5_exec-start.o: start.S
- $(AS) $(minix_stage1_5_exec_ASFLAGS) $(ASFLAGS) -c -o minix_stage1_5_exec-start.o `test -f start.S || echo '$(srcdir)/'`start.S
-
-@@ -908,6 +1043,18 @@
- vstafs_stage1_5_exec-asm.obj: asm.S
- $(AS) $(vstafs_stage1_5_exec_ASFLAGS) $(ASFLAGS) -c -o vstafs_stage1_5_exec-asm.obj `cygpath -w asm.S`
-
-+xfs_stage1_5_exec-start.o: start.S
-+ $(AS) $(xfs_stage1_5_exec_ASFLAGS) $(ASFLAGS) -c -o xfs_stage1_5_exec-start.o `test -f start.S || echo '$(srcdir)/'`start.S
-+
-+xfs_stage1_5_exec-start.obj: start.S
-+ $(AS) $(xfs_stage1_5_exec_ASFLAGS) $(ASFLAGS) -c -o xfs_stage1_5_exec-start.obj `cygpath -w start.S`
-+
-+xfs_stage1_5_exec-asm.o: asm.S
-+ $(AS) $(xfs_stage1_5_exec_ASFLAGS) $(ASFLAGS) -c -o xfs_stage1_5_exec-asm.o `test -f asm.S || echo '$(srcdir)/'`asm.S
-+
-+xfs_stage1_5_exec-asm.obj: asm.S
-+ $(AS) $(xfs_stage1_5_exec_ASFLAGS) $(ASFLAGS) -c -o xfs_stage1_5_exec-asm.obj `cygpath -w asm.S`
-+
- .c.o:
- @AMDEP_TRUE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
- @AMDEP_TRUE@ depfile='$(DEPDIR)/$*.Po' tmpdepfile='$(DEPDIR)/$*.TPo' @AMDEPBACKSLASH@
-@@ -1064,6 +1211,30 @@
- @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgrub_a_CFLAGS) $(CFLAGS) -c -o libgrub_a-fsys_reiserfs.obj `cygpath -w fsys_reiserfs.c`
-
-+libgrub_a-fsys_jfs.o: fsys_jfs.c
-+@AMDEP_TRUE@ source='fsys_jfs.c' object='libgrub_a-fsys_jfs.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/libgrub_a-fsys_jfs.Po' tmpdepfile='$(DEPDIR)/libgrub_a-fsys_jfs.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgrub_a_CFLAGS) $(CFLAGS) -c -o libgrub_a-fsys_jfs.o `test -f fsys_jfs.c || echo '$(srcdir)/'`fsys_jfs.c
-+
-+libgrub_a-fsys_jfs.obj: fsys_jfs.c
-+@AMDEP_TRUE@ source='fsys_jfs.c' object='libgrub_a-fsys_jfs.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/libgrub_a-fsys_jfs.Po' tmpdepfile='$(DEPDIR)/libgrub_a-fsys_jfs.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgrub_a_CFLAGS) $(CFLAGS) -c -o libgrub_a-fsys_jfs.obj `cygpath -w fsys_jfs.c`
-+
-+libgrub_a-fsys_xfs.o: fsys_xfs.c
-+@AMDEP_TRUE@ source='fsys_xfs.c' object='libgrub_a-fsys_xfs.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/libgrub_a-fsys_xfs.Po' tmpdepfile='$(DEPDIR)/libgrub_a-fsys_xfs.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgrub_a_CFLAGS) $(CFLAGS) -c -o libgrub_a-fsys_xfs.o `test -f fsys_xfs.c || echo '$(srcdir)/'`fsys_xfs.c
-+
-+libgrub_a-fsys_xfs.obj: fsys_xfs.c
-+@AMDEP_TRUE@ source='fsys_xfs.c' object='libgrub_a-fsys_xfs.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/libgrub_a-fsys_xfs.Po' tmpdepfile='$(DEPDIR)/libgrub_a-fsys_xfs.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(libgrub_a_CFLAGS) $(CFLAGS) -c -o libgrub_a-fsys_xfs.obj `cygpath -w fsys_xfs.c`
-+
- libgrub_a-fsys_vstafs.o: fsys_vstafs.c
- @AMDEP_TRUE@ source='fsys_vstafs.c' object='libgrub_a-fsys_vstafs.o' libtool=no @AMDEPBACKSLASH@
- @AMDEP_TRUE@ depfile='$(DEPDIR)/libgrub_a-fsys_vstafs.Po' tmpdepfile='$(DEPDIR)/libgrub_a-fsys_vstafs.TPo' @AMDEPBACKSLASH@
-@@ -1256,6 +1427,30 @@
- @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(diskless_exec_CFLAGS) $(CFLAGS) -c -o diskless_exec-fsys_reiserfs.obj `cygpath -w fsys_reiserfs.c`
-
-+diskless_exec-fsys_jfs.o: fsys_jfs.c
-+@AMDEP_TRUE@ source='fsys_jfs.c' object='diskless_exec-fsys_jfs.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/diskless_exec-fsys_jfs.Po' tmpdepfile='$(DEPDIR)/diskless_exec-fsys_jfs.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(diskless_exec_CFLAGS) $(CFLAGS) -c -o diskless_exec-fsys_jfs.o `test -f fsys_jfs.c || echo '$(srcdir)/'`fsys_jfs.c
-+
-+diskless_exec-fsys_jfs.obj: fsys_jfs.c
-+@AMDEP_TRUE@ source='fsys_jfs.c' object='diskless_exec-fsys_jfs.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/diskless_exec-fsys_jfs.Po' tmpdepfile='$(DEPDIR)/diskless_exec-fsys_jfs.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(diskless_exec_CFLAGS) $(CFLAGS) -c -o diskless_exec-fsys_jfs.obj `cygpath -w fsys_jfs.c`
-+
-+diskless_exec-fsys_xfs.o: fsys_xfs.c
-+@AMDEP_TRUE@ source='fsys_xfs.c' object='diskless_exec-fsys_xfs.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/diskless_exec-fsys_xfs.Po' tmpdepfile='$(DEPDIR)/diskless_exec-fsys_xfs.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(diskless_exec_CFLAGS) $(CFLAGS) -c -o diskless_exec-fsys_xfs.o `test -f fsys_xfs.c || echo '$(srcdir)/'`fsys_xfs.c
-+
-+diskless_exec-fsys_xfs.obj: fsys_xfs.c
-+@AMDEP_TRUE@ source='fsys_xfs.c' object='diskless_exec-fsys_xfs.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/diskless_exec-fsys_xfs.Po' tmpdepfile='$(DEPDIR)/diskless_exec-fsys_xfs.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(diskless_exec_CFLAGS) $(CFLAGS) -c -o diskless_exec-fsys_xfs.obj `cygpath -w fsys_xfs.c`
-+
- diskless_exec-fsys_vstafs.o: fsys_vstafs.c
- @AMDEP_TRUE@ source='fsys_vstafs.c' object='diskless_exec-fsys_vstafs.o' libtool=no @AMDEPBACKSLASH@
- @AMDEP_TRUE@ depfile='$(DEPDIR)/diskless_exec-fsys_vstafs.Po' tmpdepfile='$(DEPDIR)/diskless_exec-fsys_vstafs.TPo' @AMDEPBACKSLASH@
-@@ -1544,6 +1739,78 @@
- @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(ffs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o ffs_stage1_5_exec-bios.obj `cygpath -w bios.c`
-
-+jfs_stage1_5_exec-common.o: common.c
-+@AMDEP_TRUE@ source='common.c' object='jfs_stage1_5_exec-common.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/jfs_stage1_5_exec-common.Po' tmpdepfile='$(DEPDIR)/jfs_stage1_5_exec-common.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(jfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o jfs_stage1_5_exec-common.o `test -f common.c || echo '$(srcdir)/'`common.c
-+
-+jfs_stage1_5_exec-common.obj: common.c
-+@AMDEP_TRUE@ source='common.c' object='jfs_stage1_5_exec-common.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/jfs_stage1_5_exec-common.Po' tmpdepfile='$(DEPDIR)/jfs_stage1_5_exec-common.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(jfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o jfs_stage1_5_exec-common.obj `cygpath -w common.c`
-+
-+jfs_stage1_5_exec-char_io.o: char_io.c
-+@AMDEP_TRUE@ source='char_io.c' object='jfs_stage1_5_exec-char_io.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/jfs_stage1_5_exec-char_io.Po' tmpdepfile='$(DEPDIR)/jfs_stage1_5_exec-char_io.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(jfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o jfs_stage1_5_exec-char_io.o `test -f char_io.c || echo '$(srcdir)/'`char_io.c
-+
-+jfs_stage1_5_exec-char_io.obj: char_io.c
-+@AMDEP_TRUE@ source='char_io.c' object='jfs_stage1_5_exec-char_io.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/jfs_stage1_5_exec-char_io.Po' tmpdepfile='$(DEPDIR)/jfs_stage1_5_exec-char_io.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(jfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o jfs_stage1_5_exec-char_io.obj `cygpath -w char_io.c`
-+
-+jfs_stage1_5_exec-disk_io.o: disk_io.c
-+@AMDEP_TRUE@ source='disk_io.c' object='jfs_stage1_5_exec-disk_io.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/jfs_stage1_5_exec-disk_io.Po' tmpdepfile='$(DEPDIR)/jfs_stage1_5_exec-disk_io.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(jfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o jfs_stage1_5_exec-disk_io.o `test -f disk_io.c || echo '$(srcdir)/'`disk_io.c
-+
-+jfs_stage1_5_exec-disk_io.obj: disk_io.c
-+@AMDEP_TRUE@ source='disk_io.c' object='jfs_stage1_5_exec-disk_io.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/jfs_stage1_5_exec-disk_io.Po' tmpdepfile='$(DEPDIR)/jfs_stage1_5_exec-disk_io.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(jfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o jfs_stage1_5_exec-disk_io.obj `cygpath -w disk_io.c`
-+
-+jfs_stage1_5_exec-stage1_5.o: stage1_5.c
-+@AMDEP_TRUE@ source='stage1_5.c' object='jfs_stage1_5_exec-stage1_5.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/jfs_stage1_5_exec-stage1_5.Po' tmpdepfile='$(DEPDIR)/jfs_stage1_5_exec-stage1_5.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(jfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o jfs_stage1_5_exec-stage1_5.o `test -f stage1_5.c || echo '$(srcdir)/'`stage1_5.c
-+
-+jfs_stage1_5_exec-stage1_5.obj: stage1_5.c
-+@AMDEP_TRUE@ source='stage1_5.c' object='jfs_stage1_5_exec-stage1_5.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/jfs_stage1_5_exec-stage1_5.Po' tmpdepfile='$(DEPDIR)/jfs_stage1_5_exec-stage1_5.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(jfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o jfs_stage1_5_exec-stage1_5.obj `cygpath -w stage1_5.c`
-+
-+jfs_stage1_5_exec-fsys_jfs.o: fsys_jfs.c
-+@AMDEP_TRUE@ source='fsys_jfs.c' object='jfs_stage1_5_exec-fsys_jfs.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/jfs_stage1_5_exec-fsys_jfs.Po' tmpdepfile='$(DEPDIR)/jfs_stage1_5_exec-fsys_jfs.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(jfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o jfs_stage1_5_exec-fsys_jfs.o `test -f fsys_jfs.c || echo '$(srcdir)/'`fsys_jfs.c
-+
-+jfs_stage1_5_exec-fsys_jfs.obj: fsys_jfs.c
-+@AMDEP_TRUE@ source='fsys_jfs.c' object='jfs_stage1_5_exec-fsys_jfs.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/jfs_stage1_5_exec-fsys_jfs.Po' tmpdepfile='$(DEPDIR)/jfs_stage1_5_exec-fsys_jfs.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(jfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o jfs_stage1_5_exec-fsys_jfs.obj `cygpath -w fsys_jfs.c`
-+
-+jfs_stage1_5_exec-bios.o: bios.c
-+@AMDEP_TRUE@ source='bios.c' object='jfs_stage1_5_exec-bios.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/jfs_stage1_5_exec-bios.Po' tmpdepfile='$(DEPDIR)/jfs_stage1_5_exec-bios.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(jfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o jfs_stage1_5_exec-bios.o `test -f bios.c || echo '$(srcdir)/'`bios.c
-+
-+jfs_stage1_5_exec-bios.obj: bios.c
-+@AMDEP_TRUE@ source='bios.c' object='jfs_stage1_5_exec-bios.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/jfs_stage1_5_exec-bios.Po' tmpdepfile='$(DEPDIR)/jfs_stage1_5_exec-bios.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(jfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o jfs_stage1_5_exec-bios.obj `cygpath -w bios.c`
-+
- minix_stage1_5_exec-common.o: common.c
- @AMDEP_TRUE@ source='common.c' object='minix_stage1_5_exec-common.o' libtool=no @AMDEPBACKSLASH@
- @AMDEP_TRUE@ depfile='$(DEPDIR)/minix_stage1_5_exec-common.Po' tmpdepfile='$(DEPDIR)/minix_stage1_5_exec-common.TPo' @AMDEPBACKSLASH@
-@@ -1772,6 +2039,30 @@
- @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pre_stage2_exec_CFLAGS) $(CFLAGS) -c -o pre_stage2_exec-fsys_reiserfs.obj `cygpath -w fsys_reiserfs.c`
-
-+pre_stage2_exec-fsys_jfs.o: fsys_jfs.c
-+@AMDEP_TRUE@ source='fsys_jfs.c' object='pre_stage2_exec-fsys_jfs.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/pre_stage2_exec-fsys_jfs.Po' tmpdepfile='$(DEPDIR)/pre_stage2_exec-fsys_jfs.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pre_stage2_exec_CFLAGS) $(CFLAGS) -c -o pre_stage2_exec-fsys_jfs.o `test -f fsys_jfs.c || echo '$(srcdir)/'`fsys_jfs.c
-+
-+pre_stage2_exec-fsys_jfs.obj: fsys_jfs.c
-+@AMDEP_TRUE@ source='fsys_jfs.c' object='pre_stage2_exec-fsys_jfs.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/pre_stage2_exec-fsys_jfs.Po' tmpdepfile='$(DEPDIR)/pre_stage2_exec-fsys_jfs.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pre_stage2_exec_CFLAGS) $(CFLAGS) -c -o pre_stage2_exec-fsys_jfs.obj `cygpath -w fsys_jfs.c`
-+
-+pre_stage2_exec-fsys_xfs.o: fsys_xfs.c
-+@AMDEP_TRUE@ source='fsys_xfs.c' object='pre_stage2_exec-fsys_xfs.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/pre_stage2_exec-fsys_xfs.Po' tmpdepfile='$(DEPDIR)/pre_stage2_exec-fsys_xfs.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pre_stage2_exec_CFLAGS) $(CFLAGS) -c -o pre_stage2_exec-fsys_xfs.o `test -f fsys_xfs.c || echo '$(srcdir)/'`fsys_xfs.c
-+
-+pre_stage2_exec-fsys_xfs.obj: fsys_xfs.c
-+@AMDEP_TRUE@ source='fsys_xfs.c' object='pre_stage2_exec-fsys_xfs.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/pre_stage2_exec-fsys_xfs.Po' tmpdepfile='$(DEPDIR)/pre_stage2_exec-fsys_xfs.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(pre_stage2_exec_CFLAGS) $(CFLAGS) -c -o pre_stage2_exec-fsys_xfs.obj `cygpath -w fsys_xfs.c`
-+
- pre_stage2_exec-fsys_vstafs.o: fsys_vstafs.c
- @AMDEP_TRUE@ source='fsys_vstafs.c' object='pre_stage2_exec-fsys_vstafs.o' libtool=no @AMDEPBACKSLASH@
- @AMDEP_TRUE@ depfile='$(DEPDIR)/pre_stage2_exec-fsys_vstafs.Po' tmpdepfile='$(DEPDIR)/pre_stage2_exec-fsys_vstafs.TPo' @AMDEPBACKSLASH@
-@@ -1987,6 +2278,78 @@
- @AMDEP_TRUE@ depfile='$(DEPDIR)/vstafs_stage1_5_exec-bios.Po' tmpdepfile='$(DEPDIR)/vstafs_stage1_5_exec-bios.TPo' @AMDEPBACKSLASH@
- @AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(vstafs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o vstafs_stage1_5_exec-bios.obj `cygpath -w bios.c`
-+
-+xfs_stage1_5_exec-common.o: common.c
-+@AMDEP_TRUE@ source='common.c' object='xfs_stage1_5_exec-common.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/xfs_stage1_5_exec-common.Po' tmpdepfile='$(DEPDIR)/xfs_stage1_5_exec-common.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(xfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o xfs_stage1_5_exec-common.o `test -f common.c || echo '$(srcdir)/'`common.c
-+
-+xfs_stage1_5_exec-common.obj: common.c
-+@AMDEP_TRUE@ source='common.c' object='xfs_stage1_5_exec-common.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/xfs_stage1_5_exec-common.Po' tmpdepfile='$(DEPDIR)/xfs_stage1_5_exec-common.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(xfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o xfs_stage1_5_exec-common.obj `cygpath -w common.c`
-+
-+xfs_stage1_5_exec-char_io.o: char_io.c
-+@AMDEP_TRUE@ source='char_io.c' object='xfs_stage1_5_exec-char_io.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/xfs_stage1_5_exec-char_io.Po' tmpdepfile='$(DEPDIR)/xfs_stage1_5_exec-char_io.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(xfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o xfs_stage1_5_exec-char_io.o `test -f char_io.c || echo '$(srcdir)/'`char_io.c
-+
-+xfs_stage1_5_exec-char_io.obj: char_io.c
-+@AMDEP_TRUE@ source='char_io.c' object='xfs_stage1_5_exec-char_io.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/xfs_stage1_5_exec-char_io.Po' tmpdepfile='$(DEPDIR)/xfs_stage1_5_exec-char_io.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(xfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o xfs_stage1_5_exec-char_io.obj `cygpath -w char_io.c`
-+
-+xfs_stage1_5_exec-disk_io.o: disk_io.c
-+@AMDEP_TRUE@ source='disk_io.c' object='xfs_stage1_5_exec-disk_io.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/xfs_stage1_5_exec-disk_io.Po' tmpdepfile='$(DEPDIR)/xfs_stage1_5_exec-disk_io.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(xfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o xfs_stage1_5_exec-disk_io.o `test -f disk_io.c || echo '$(srcdir)/'`disk_io.c
-+
-+xfs_stage1_5_exec-disk_io.obj: disk_io.c
-+@AMDEP_TRUE@ source='disk_io.c' object='xfs_stage1_5_exec-disk_io.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/xfs_stage1_5_exec-disk_io.Po' tmpdepfile='$(DEPDIR)/xfs_stage1_5_exec-disk_io.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(xfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o xfs_stage1_5_exec-disk_io.obj `cygpath -w disk_io.c`
-+
-+xfs_stage1_5_exec-stage1_5.o: stage1_5.c
-+@AMDEP_TRUE@ source='stage1_5.c' object='xfs_stage1_5_exec-stage1_5.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/xfs_stage1_5_exec-stage1_5.Po' tmpdepfile='$(DEPDIR)/xfs_stage1_5_exec-stage1_5.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(xfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o xfs_stage1_5_exec-stage1_5.o `test -f stage1_5.c || echo '$(srcdir)/'`stage1_5.c
-+
-+xfs_stage1_5_exec-stage1_5.obj: stage1_5.c
-+@AMDEP_TRUE@ source='stage1_5.c' object='xfs_stage1_5_exec-stage1_5.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/xfs_stage1_5_exec-stage1_5.Po' tmpdepfile='$(DEPDIR)/xfs_stage1_5_exec-stage1_5.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(xfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o xfs_stage1_5_exec-stage1_5.obj `cygpath -w stage1_5.c`
-+
-+xfs_stage1_5_exec-fsys_xfs.o: fsys_xfs.c
-+@AMDEP_TRUE@ source='fsys_xfs.c' object='xfs_stage1_5_exec-fsys_xfs.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/xfs_stage1_5_exec-fsys_xfs.Po' tmpdepfile='$(DEPDIR)/xfs_stage1_5_exec-fsys_xfs.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(xfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o xfs_stage1_5_exec-fsys_xfs.o `test -f fsys_xfs.c || echo '$(srcdir)/'`fsys_xfs.c
-+
-+xfs_stage1_5_exec-fsys_xfs.obj: fsys_xfs.c
-+@AMDEP_TRUE@ source='fsys_xfs.c' object='xfs_stage1_5_exec-fsys_xfs.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/xfs_stage1_5_exec-fsys_xfs.Po' tmpdepfile='$(DEPDIR)/xfs_stage1_5_exec-fsys_xfs.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(xfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o xfs_stage1_5_exec-fsys_xfs.obj `cygpath -w fsys_xfs.c`
-+
-+xfs_stage1_5_exec-bios.o: bios.c
-+@AMDEP_TRUE@ source='bios.c' object='xfs_stage1_5_exec-bios.o' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/xfs_stage1_5_exec-bios.Po' tmpdepfile='$(DEPDIR)/xfs_stage1_5_exec-bios.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(xfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o xfs_stage1_5_exec-bios.o `test -f bios.c || echo '$(srcdir)/'`bios.c
-+
-+xfs_stage1_5_exec-bios.obj: bios.c
-+@AMDEP_TRUE@ source='bios.c' object='xfs_stage1_5_exec-bios.obj' libtool=no @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ depfile='$(DEPDIR)/xfs_stage1_5_exec-bios.Po' tmpdepfile='$(DEPDIR)/xfs_stage1_5_exec-bios.TPo' @AMDEPBACKSLASH@
-+@AMDEP_TRUE@ $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-+ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(xfs_stage1_5_exec_CFLAGS) $(CFLAGS) -c -o xfs_stage1_5_exec-bios.obj `cygpath -w bios.c`
- CCDEPMODE = @CCDEPMODE@
- uninstall-info-am:
- install-pkgdataDATA: $(pkgdata_DATA)
diff --git a/sys-apps/grub/files/grub-0.90/grub-jfs+xfs-1.0-core.patch b/sys-apps/grub/files/grub-0.90/grub-jfs+xfs-1.0-core.patch
deleted file mode 100644
index 8bc908a375e1..000000000000
--- a/sys-apps/grub/files/grub-0.90/grub-jfs+xfs-1.0-core.patch
+++ /dev/null
@@ -1,2430 +0,0 @@
-diff -urN --exclude-from=xlist-core grub-0.90/AUTHORS grub-0.90.jfs+xfs/AUTHORS
---- grub-0.90/AUTHORS Fri Jun 22 06:32:55 2001
-+++ grub-0.90.jfs+xfs/AUTHORS Tue Aug 28 17:00:29 2001
-@@ -37,3 +37,5 @@
- Frank Mehnert added support for hercules console.
-
- Kristoffer Branemyr added VSTa filesystem support.
-+
-+Serguei Tzukanov wrote stage2/fsys_jfs.c and stage2/fsys_xfs.c.
-diff -urN --exclude-from=xlist-core grub-0.90/README grub-0.90.jfs+xfs/README
---- grub-0.90/README Thu Jun 21 01:02:46 2001
-+++ grub-0.90.jfs+xfs/README Tue Aug 28 16:56:55 2001
-@@ -4,8 +4,9 @@
-
- - provides fully-featured command line and graphical interfaces
- - recognizes fdisk partitions and BSD disklabels
-- - can dynamically read Linux ext2fs and ReiserFS, BSD ufs, MS-DOS
-- FAT16 and FAT32, and Minix fs filesystems, plus hardcoded blocklists
-+ - can dynamically read Linux ext2fs, ReiserFS, JFS and XFS, BSD ufs,
-+ MS-DOS FAT16 and FAT32, and Minix fs filesystems, plus hardcoded
-+ blocklists
- - can boot Multiboot-compliant kernels (such as GNU Mach), as well
- as standard Linux and *BSD kernels
-
-diff -urN --exclude-from=xlist-core grub-0.90/TODO grub-0.90.jfs+xfs/TODO
---- grub-0.90/TODO Sun Nov 26 21:39:50 2000
-+++ grub-0.90.jfs+xfs/TODO Tue Aug 28 17:06:35 2001
-@@ -80,7 +80,7 @@
-
- * Add ISA PnP support.
-
--* Add more filesystems support (XFS, NTFS, etc.)
-+* Add more filesystems support (NTFS, etc.)
-
- * Add more remote console support (parallel and net).
-
-diff -urN --exclude-from=xlist-core grub-0.90/configure.in grub-0.90.jfs+xfs/configure.in
---- grub-0.90/configure.in Thu Jul 5 15:29:56 2001
-+++ grub-0.90.jfs+xfs/configure.in Thu Aug 23 17:53:16 2001
-@@ -219,6 +219,20 @@
- FSYS_CFLAGS="$FSYS_CFLAGS -DFSYS_REISERFS=1"
- fi
-
-+AC_ARG_ENABLE(jfs,
-+ [ --disable-jfs disable IBM JFS support in Stage 2])
-+
-+if test x"$enable_jfs" != xno; then
-+ FSYS_CFLAGS="$FSYS_CFLAGS -DFSYS_JFS=1"
-+fi
-+
-+AC_ARG_ENABLE(xfs,
-+ [ --disable-xfs disable SGI XFS support in Stage 2])
-+
-+if test x"$enable_xfs" != xno; then
-+ FSYS_CFLAGS="$FSYS_CFLAGS -DFSYS_XFS=1"
-+fi
-+
- AC_ARG_ENABLE(vstafs,
- [ --disable-vstafs disable VSTa FS support in Stage 2])
-
-diff -urN --exclude-from=xlist-core grub-0.90/stage2/Makefile.am grub-0.90.jfs+xfs/stage2/Makefile.am
---- grub-0.90/stage2/Makefile.am Wed Jul 4 11:33:48 2001
-+++ grub-0.90.jfs+xfs/stage2/Makefile.am Thu Aug 23 18:03:38 2001
-@@ -4,7 +4,7 @@
-
- # For dist target.
- noinst_HEADERS = apic.h defs.h dir.h disk_inode.h disk_inode_ffs.h \
-- fat.h filesys.h freebsd.h fs.h hercules.h i386-elf.h \
-+ fat.h jfs.h xfs.h filesys.h freebsd.h fs.h hercules.h i386-elf.h \
- imgact_aout.h mb_header.h mb_info.h md5.h pc_slice.h serial.h \
- shared.h smp-imps.h nbi.h vstafs.h
- EXTRA_DIST = setjmp.S apm.S $(noinst_SCRIPTS)
-@@ -16,11 +16,13 @@
- noinst_LIBRARIES = libgrub.a
- libgrub_a_SOURCES = boot.c builtins.c common.c char_io.c cmdline.c \
- disk_io.c gunzip.c fsys_ffs.c fsys_ext2fs.c fsys_fat.c \
-- fsys_minix.c fsys_reiserfs.c fsys_vstafs.c stage2.c md5.c
-+ fsys_minix.c fsys_reiserfs.c fsys_jfs.c fsys_xfs.c fsys_vstafs.c \
-+ stage2.c md5.c
- libgrub_a_CFLAGS = $(GRUB_CFLAGS) -I$(top_srcdir)/lib \
- -DGRUB_UTIL=1 -DFSYS_EXT2FS=1 -DFSYS_FAT=1 -DFSYS_FFS=1 \
-- -DFSYS_MINIX=1 -DFSYS_REISERFS=1 -DFSYS_VSTAFS=1 \
-- -DSUPPORT_SERIAL=1 -DSUPPORT_HERCULES=1 -fwritable-strings
-+ -DFSYS_MINIX=1 -DFSYS_REISERFS=1 -DFSYS_JFS=1 -DFSYS_XFS=1 \
-+ -DFSYS_VSTAFS=1 -DSUPPORT_SERIAL=1 -DSUPPORT_HERCULES=1 \
-+ -fwritable-strings
-
- # Stage 2 and Stage 1.5's.
- pkgdatadir = $(datadir)/$(PACKAGE)/$(host_cpu)-$(host_vendor)
-@@ -29,19 +31,22 @@
-
- if DISKLESS_SUPPORT
- pkgdata_DATA = stage2 e2fs_stage1_5 fat_stage1_5 ffs_stage1_5 \
-- minix_stage1_5 reiserfs_stage1_5 vstafs_stage1_5 nbgrub pxegrub
-+ minix_stage1_5 reiserfs_stage1_5 jfs_stage1_5 xfs_stage1_5 \
-+ vstafs_stage1_5 nbgrub pxegrub
- noinst_DATA = pre_stage2 start nbloader pxeloader diskless
- noinst_PROGRAMS = pre_stage2.exec start.exec e2fs_stage1_5.exec \
- fat_stage1_5.exec ffs_stage1_5.exec minix_stage1_5.exec \
-- reiserfs_stage1_5.exec vstafs_stage1_5.exec nbloader.exec \
-- pxeloader.exec diskless.exec
-+ reiserfs_stage1_5.exec jfs_stage1_5.exec xfs_stage1_5.exec \
-+ vstafs_stage1_5.exec nbloader.exec pxeloader.exec diskless.exec
- else
- pkgdata_DATA = stage2 e2fs_stage1_5 fat_stage1_5 ffs_stage1_5 \
-- minix_stage1_5 reiserfs_stage1_5 vstafs_stage1_5
-+ minix_stage1_5 reiserfs_stage1_5 jfs_stage1_5 xfs_stage1_5 \
-+ vstafs_stage1_5
- noinst_DATA = pre_stage2 start
- noinst_PROGRAMS = pre_stage2.exec start.exec e2fs_stage1_5.exec \
- fat_stage1_5.exec ffs_stage1_5.exec minix_stage1_5.exec \
-- reiserfs_stage1_5.exec vstafs_stage1_5.exec
-+ reiserfs_stage1_5.exec jfs_stage1_5.exec xfs_stage1_5.exec \
-+ vstafs_stage1_5.exec
- endif
- MOSTLYCLEANFILES = $(noinst_PROGRAMS)
-
-@@ -78,7 +83,8 @@
- pre_stage2_exec_SOURCES = asm.S bios.c boot.c builtins.c common.c \
- char_io.c cmdline.c disk_io.c gunzip.c fsys_ext2fs.c \
- fsys_fat.c fsys_ffs.c fsys_minix.c fsys_reiserfs.c \
-- fsys_vstafs.c hercules.c serial.c smp-imps.c stage2.c md5.c
-+ fsys_jfs.c fsys_xfs.c fsys_vstafs.c hercules.c serial.c \
-+ smp-imps.c stage2.c md5.c
- pre_stage2_exec_CFLAGS = $(STAGE2_COMPILE) $(FSYS_CFLAGS)
- pre_stage2_exec_ASFLAGS = $(STAGE2_COMPILE) $(FSYS_CFLAGS)
- pre_stage2_exec_LDFLAGS = $(PRE_STAGE2_LINK)
-@@ -158,6 +164,24 @@
- reiserfs_stage1_5_exec_ASFLAGS = $(STAGE1_5_COMPILE) -DFSYS_REISERFS=1 \
- -DNO_BLOCK_FILES=1
- reiserfs_stage1_5_exec_LDFLAGS = $(STAGE1_5_LINK)
-+
-+# For jfs_stage1_5 target.
-+jfs_stage1_5_exec_SOURCES = start.S asm.S common.c char_io.c \
-+ disk_io.c stage1_5.c fsys_jfs.c bios.c
-+jfs_stage1_5_exec_CFLAGS = $(STAGE1_5_COMPILE) -DFSYS_JFS=1 \
-+ -DNO_BLOCK_FILES=1
-+jfs_stage1_5_exec_ASFLAGS = $(STAGE1_5_COMPILE) -DFSYS_JFS=1 \
-+ -DNO_BLOCK_FILES=1
-+jfs_stage1_5_exec_LDFLAGS = $(STAGE1_5_LINK)
-+
-+# For xfs_stage1_5 target.
-+xfs_stage1_5_exec_SOURCES = start.S asm.S common.c char_io.c \
-+ disk_io.c stage1_5.c fsys_xfs.c bios.c
-+xfs_stage1_5_exec_CFLAGS = $(STAGE1_5_COMPILE) -DFSYS_XFS=1 \
-+ -DNO_BLOCK_FILES=1
-+xfs_stage1_5_exec_ASFLAGS = $(STAGE1_5_COMPILE) -DFSYS_XFS=1 \
-+ -DNO_BLOCK_FILES=1
-+xfs_stage1_5_exec_LDFLAGS = $(STAGE1_5_LINK)
-
- # For vstafs_stage1_5 target.
- vstafs_stage1_5_exec_SOURCES = start.S asm.S common.c char_io.c \
-diff -urN --exclude-from=xlist-core grub-0.90/stage2/builtins.c grub-0.90.jfs+xfs/stage2/builtins.c
---- grub-0.90/stage2/builtins.c Fri Jun 22 03:15:02 2001
-+++ grub-0.90.jfs+xfs/stage2/builtins.c Fri Aug 24 22:13:48 2001
-@@ -3643,7 +3643,9 @@
- {"ffs", "/ffs_stage1_5"},
- {"fat", "/fat_stage1_5"},
- {"minix", "/minix_stage1_5"},
-- {"reiserfs", "/reiserfs_stage1_5"}
-+ {"reiserfs", "/reiserfs_stage1_5"},
-+ {"jfs", "/jfs_stage1_5"},
-+ {"xfs", "/xfs_stage1_5"}
- };
-
- tmp_drive = saved_drive;
-diff -urN --exclude-from=xlist-core grub-0.90/stage2/disk_io.c grub-0.90.jfs+xfs/stage2/disk_io.c
---- grub-0.90/stage2/disk_io.c Fri Jun 22 06:32:56 2001
-+++ grub-0.90.jfs+xfs/stage2/disk_io.c Thu Aug 23 17:57:46 2001
-@@ -60,6 +60,12 @@
- # ifdef FSYS_REISERFS
- {"reiserfs", reiserfs_mount, reiserfs_read, reiserfs_dir, 0, reiserfs_embed},
- # endif
-+# ifdef FSYS_JFS
-+ {"jfs", jfs_mount, jfs_read, jfs_dir, 0, jfs_embed},
-+# endif
-+# ifdef FSYS_XFS
-+ {"xfs", xfs_mount, xfs_read, xfs_dir, 0, 0},
-+# endif
- # ifdef FSYS_VSTAFS
- {"vstafs", vstafs_mount, vstafs_read, vstafs_dir, 0, 0},
- # endif
-diff -urN --exclude-from=xlist-core grub-0.90/stage2/filesys.h grub-0.90.jfs+xfs/stage2/filesys.h
---- grub-0.90/stage2/filesys.h Fri Jun 22 06:32:56 2001
-+++ grub-0.90.jfs+xfs/stage2/filesys.h Fri Aug 24 23:09:23 2001
-@@ -68,6 +68,25 @@
- #define FSYS_REISERFS_NUM 0
- #endif
-
-+#ifdef FSYS_JFS
-+#define FSYS_JFS_NUM 1
-+int jfs_mount (void);
-+int jfs_read (char *buf, int len);
-+int jfs_dir (char *dirname);
-+int jfs_embed (int *start_sector, int needed_sectors);
-+#else
-+#define FSYS_JFS_NUM 0
-+#endif
-+
-+#ifdef FSYS_XFS
-+#define FSYS_XFS_NUM 1
-+int xfs_mount (void);
-+int xfs_read (char *buf, int len);
-+int xfs_dir (char *dirname);
-+#else
-+#define FSYS_XFS_NUM 0
-+#endif
-+
- #ifdef FSYS_VSTAFS
- #define FSYS_VSTAFS_NUM 1
- int vstafs_mount (void);
-@@ -90,7 +109,8 @@
- #ifndef NUM_FSYS
- #define NUM_FSYS \
- (FSYS_FFS_NUM + FSYS_FAT_NUM + FSYS_EXT2FS_NUM + FSYS_MINIX_NUM \
-- + FSYS_REISERFS_NUM + FSYS_VSTAFS_NUM + FSYS_TFTP_NUM)
-+ + FSYS_REISERFS_NUM + FSYS_JFS_NUM + FSYS_XFS_NUM + FSYS_VSTAFS_NUM \
-+ + FSYS_TFTP_NUM)
- #endif
-
- /* defines for the block filesystem info area */
-diff -urN --exclude-from=xlist-core grub-0.90/stage2/fsys_jfs.c grub-0.90.jfs+xfs/stage2/fsys_jfs.c
---- grub-0.90/stage2/fsys_jfs.c Thu Jan 1 03:00:00 1970
-+++ grub-0.90.jfs+xfs/stage2/fsys_jfs.c Wed Aug 29 01:20:04 2001
-@@ -0,0 +1,405 @@
-+/*
-+ * fsys_jfs.c - an implementation for the IBM JFS file system
-+ *
-+ * Copyright (C) 2001 Serguei Tzukanov
-+ *
-+ * This program is free software; you can redistribute it and/or modify
-+ * it under the terms of the GNU General Public License as published by
-+ * the Free Software Foundation; either version 2 of the License, or
-+ * (at your option) any later version.
-+ *
-+ * This program is distributed in the hope that it will be useful,
-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-+ * GNU General Public License for more details.
-+ *
-+ * You should have received a copy of the GNU General Public License
-+ * along with this program; if not, write to the Free Software
-+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-+ */
-+
-+#ifdef FSYS_JFS
-+
-+#include "shared.h"
-+#include "filesys.h"
-+#include "jfs.h"
-+
-+#define MAX_LINK_COUNT 8
-+
-+#define DTTYPE_INLINE 0
-+#define DTTYPE_PAGE 1
-+
-+struct jfs_info
-+{
-+ int bsize;
-+ int l2bsize;
-+ int bdlog;
-+ int xindex;
-+ int xlastindex;
-+ int sindex;
-+ int slastindex;
-+ int de_index;
-+ int dttype;
-+ xad_t *xad;
-+ ldtentry_t *de;
-+};
-+
-+static struct jfs_info jfs;
-+
-+#define xtpage ((xtpage_t *)FSYS_BUF)
-+#define dtpage ((dtpage_t *)((char *)FSYS_BUF + 4096))
-+#define fileset ((dinode_t *)((char *)FSYS_BUF + 8192))
-+#define inode ((dinode_t *)((char *)FSYS_BUF + 8192 + sizeof(dinode_t)))
-+#define dtroot ((dtroot_t *)(&inode->di_btroot))
-+
-+static ldtentry_t de_always[2] = {
-+ {1, -1, 2, {'.', '.'}},
-+ {1, -1, 1, {'.'}}
-+};
-+
-+static int
-+isinxt (s64 key, s64 offset, s64 len)
-+{
-+ return (key >= offset) ? (key < offset + len ? 1 : 0) : 0;
-+}
-+
-+static xad_t *
-+first_extent (dinode_t *di)
-+{
-+ xtpage_t *xtp;
-+
-+ jfs.xindex = 2;
-+ xtp = (xtpage_t *)&di->di_btroot;
-+ jfs.xad = &xtp->xad[2];
-+ if (xtp->header.flag & BT_LEAF) {
-+ jfs.xlastindex = xtp->header.nextindex;
-+ } else {
-+ do {
-+ devread (addressXAD (jfs.xad) << jfs.bdlog, 0,
-+ sizeof(xtpage_t), (char *)xtpage);
-+ jfs.xad = &xtpage->xad[2];
-+ } while (!(xtpage->header.flag & BT_LEAF));
-+ jfs.xlastindex = xtpage->header.nextindex;
-+ }
-+
-+ return jfs.xad;
-+}
-+
-+static xad_t *
-+next_extent (void)
-+{
-+ if (++jfs.xindex < jfs.xlastindex) {
-+ } else if (xtpage->header.next) {
-+ devread (xtpage->header.next << jfs.bdlog, 0,
-+ sizeof(xtpage_t), (char *)xtpage);
-+ jfs.xlastindex = xtpage->header.nextindex;
-+ jfs.xindex = XTENTRYSTART;
-+ jfs.xad = &xtpage->xad[XTENTRYSTART];
-+ } else {
-+ return NULL;
-+ }
-+ return ++jfs.xad;
-+}
-+
-+
-+static void
-+di_read (u32 inum, dinode_t *di)
-+{
-+ s64 key;
-+ u32 xd, ioffset;
-+ s64 offset;
-+ xad_t *xad;
-+ pxd_t pxd;
-+
-+ key = (((inum >> L2INOSPERIAG) << L2INOSPERIAG) + 4096) >> jfs.l2bsize;
-+ xd = (inum & (INOSPERIAG - 1)) >> L2INOSPEREXT;
-+ ioffset = ((inum & (INOSPERIAG - 1)) & (INOSPEREXT - 1)) << L2DISIZE;
-+ xad = first_extent (fileset);
-+ do {
-+ offset = offsetXAD (xad);
-+ if (isinxt (key, offset, lengthXAD (xad))) {
-+ devread ((addressXAD (xad) + key - offset) << jfs.bdlog,
-+ 3072 + xd*sizeof(pxd_t), sizeof(pxd_t), (char *)&pxd);
-+ devread (addressPXD (&pxd) << jfs.bdlog,
-+ ioffset, DISIZE, (char *)di);
-+ break;
-+ }
-+ } while ((xad = next_extent ()));
-+}
-+
-+static ldtentry_t *
-+next_dentry (void)
-+{
-+ ldtentry_t *de;
-+ s8 *stbl;
-+
-+ if (jfs.dttype == DTTYPE_INLINE) {
-+ if (jfs.sindex < jfs.slastindex) {
-+ return (ldtentry_t *)&dtroot->slot[(int)dtroot->header.stbl[jfs.sindex++]];
-+ }
-+ } else {
-+ de = (ldtentry_t *)dtpage->slot;
-+ stbl = (s8 *)&de[(int)dtpage->header.stblindex];
-+ if (jfs.sindex < jfs.slastindex) {
-+ return &de[(int)stbl[jfs.sindex++]];
-+ } else if (dtpage->header.next) {
-+ devread (dtpage->header.next << jfs.bdlog, 0,
-+ sizeof(dtpage_t), (char *)dtpage);
-+ jfs.slastindex = dtpage->header.nextindex;
-+ jfs.sindex = 1;
-+ return &de[(int)((s8 *)&de[(int)dtpage->header.stblindex])[0]];
-+ }
-+ }
-+
-+ return (jfs.de_index < 2) ? &de_always[jfs.de_index++] : NULL;
-+}
-+
-+static ldtentry_t *
-+first_dentry (void)
-+{
-+ dtroot_t *dtr;
-+ pxd_t *xd;
-+ idtentry_t *de;
-+
-+ dtr = (dtroot_t *)&inode->di_btroot;
-+ jfs.sindex = 0;
-+ jfs.de_index = 0;
-+
-+ de_always[0].inumber = inode->di_parent;
-+ de_always[1].inumber = inode->di_number;
-+ if (dtr->header.flag & BT_LEAF) {
-+ jfs.dttype = DTTYPE_INLINE;
-+ jfs.slastindex = dtr->header.nextindex;
-+ } else {
-+ de = (idtentry_t *)dtpage->slot;
-+ jfs.dttype = DTTYPE_PAGE;
-+ xd = &((idtentry_t *)dtr->slot)[(int)dtr->header.stbl[0]].xd;
-+ for (;;) {
-+ devread (addressPXD (xd) << jfs.bdlog, 0,
-+ sizeof(dtpage_t), (char *)dtpage);
-+ if (dtpage->header.flag & BT_LEAF)
-+ break;
-+ xd = &de[(int)((s8 *)&de[(int)dtpage->header.stblindex])[0]].xd;
-+ }
-+ jfs.slastindex = dtpage->header.nextindex;
-+ }
-+
-+ return next_dentry ();
-+}
-+
-+
-+static dtslot_t *
-+next_dslot (int next)
-+{
-+ return (jfs.dttype == DTTYPE_INLINE)
-+ ? (dtslot_t *)&dtroot->slot[next]
-+ : &((dtslot_t *)dtpage->slot)[next];
-+}
-+
-+static void
-+uni2ansi (UniChar *uni, char *ansi, int len)
-+{
-+ for (; len; len--, uni++)
-+ *ansi++ = (*uni & 0xff80) ? '?' : *(char *)uni;
-+}
-+
-+int
-+jfs_mount (void)
-+{
-+ struct jfs_superblock super;
-+
-+ if (part_length < MINJFS >> SECTOR_BITS
-+ || !devread (SUPER1_OFF >> SECTOR_BITS, 0,
-+ sizeof(struct jfs_superblock), (char *)&super)
-+ || (super.s_magic != JFS_MAGIC)
-+ || !devread ((AITBL_OFF >> SECTOR_BITS) + FILESYSTEM_I,
-+ 0, DISIZE, (char*)fileset)) {
-+ return 0;
-+ }
-+
-+ jfs.bsize = super.s_bsize;
-+ jfs.l2bsize = super.s_l2bsize;
-+ jfs.bdlog = jfs.l2bsize - SECTOR_BITS;
-+
-+ return 1;
-+}
-+
-+int
-+jfs_read (char *buf, int len)
-+{
-+ xad_t *xad;
-+ s64 endofprev, endofcur;
-+ s64 offset, xadlen;
-+ int toread, startpos, endpos;
-+
-+ startpos = filepos;
-+ endpos = filepos + len;
-+ endofprev = (1ULL << 62) - 1;
-+ xad = first_extent (inode);
-+ do {
-+ offset = offsetXAD (xad);
-+ xadlen = lengthXAD (xad);
-+ if (isinxt (filepos >> jfs.l2bsize, offset, xadlen)) {
-+ endofcur = (offset + xadlen) << jfs.l2bsize;
-+ toread = (endofcur >= endpos)
-+ ? len : (endofcur - filepos);
-+#ifndef STAGE1_5
-+ disk_read_func = disk_read_hook;
-+#endif /* STAGE1_5 */
-+ devread (addressXAD (xad) << jfs.bdlog,
-+ filepos - (offset << jfs.l2bsize), toread, buf);
-+#ifndef STAGE1_5
-+ disk_read_func = NULL;
-+#endif /* STAGE1_5 */
-+ buf += toread;
-+ len -= toread;
-+ filepos += toread;
-+ } else if (offset > endofprev) {
-+ toread = ((offset << jfs.l2bsize) >= endpos)
-+ ? len : ((offset - endofprev) << jfs.l2bsize);
-+ len -= toread;
-+ filepos += toread;
-+ for (; toread; toread--) {
-+ *buf++ = 0;
-+ }
-+ continue;
-+ }
-+ endofprev = offset + xadlen;
-+ xad = next_extent ();
-+ } while (len > 0 && xad);
-+
-+ return filepos - startpos;
-+}
-+
-+int
-+jfs_dir (char *dirname)
-+{
-+ char *ptr, *rest, ch;
-+ ldtentry_t *de;
-+ dtslot_t *ds;
-+ u32 inum, parent_inum;
-+ s64 di_size;
-+ u32 di_mode;
-+ int namlen, cmp, n, link_count;
-+ char namebuf[JFS_NAME_MAX + 1], linkbuf[JFS_PATH_MAX];
-+
-+ parent_inum = inum = ROOT_I;
-+ link_count = 0;
-+ for (;;) {
-+ di_read (inum, inode);
-+ di_size = inode->di_size;
-+ di_mode = inode->di_mode;
-+
-+ if ((di_mode & IFMT) == IFLNK) {
-+ if (++link_count > MAX_LINK_COUNT) {
-+ errnum = ERR_SYMLINK_LOOP;
-+ return 0;
-+ }
-+ if (di_size < (di_mode & INLINEEA ? 256 : 128)) {
-+ grub_memmove (linkbuf, inode->di_fastsymlink, di_size);
-+ n = di_size;
-+ } else if (di_size < JFS_PATH_MAX - 1) {
-+ filepos = 0;
-+ filemax = di_size;
-+ n = jfs_read (linkbuf, filemax);
-+ } else {
-+ errnum = ERR_FILELENGTH;
-+ return 0;
-+ }
-+
-+ inum = (linkbuf[0] == '/') ? ROOT_I : parent_inum;
-+ while (n < (JFS_PATH_MAX - 1) && (linkbuf[n++] = *dirname++));
-+ linkbuf[n] = 0;
-+ dirname = linkbuf;
-+ continue;
-+ }
-+
-+ if (!*dirname || isspace (*dirname)) {
-+ if ((di_mode & IFMT) != IFREG) {
-+ errnum = ERR_BAD_FILETYPE;
-+ return 0;
-+ }
-+ filepos = 0;
-+ filemax = di_size;
-+ return 1;
-+ }
-+
-+ if ((di_mode & IFMT) != IFDIR) {
-+ errnum = ERR_BAD_FILETYPE;
-+ return 0;
-+ }
-+
-+ for (; *dirname == '/'; dirname++);
-+
-+ for (rest = dirname; (ch = *rest) && !isspace (ch) && ch != '/'; rest++);
-+ *rest = 0;
-+
-+ de = first_dentry ();
-+ for (;;) {
-+ namlen = de->namlen;
-+ if (de->next == -1) {
-+ uni2ansi (de->name, namebuf, namlen);
-+ namebuf[namlen] = 0;
-+ } else {
-+ uni2ansi (de->name, namebuf, DTLHDRDATALEN);
-+ ptr = namebuf;
-+ ptr += DTLHDRDATALEN;
-+ namlen -= DTLHDRDATALEN;
-+ ds = next_dslot (de->next);
-+ while (ds->next != -1) {
-+ uni2ansi (ds->name, ptr, DTSLOTDATALEN);
-+ ptr += DTSLOTDATALEN;
-+ namlen -= DTSLOTDATALEN;
-+ ds = next_dslot (ds->next);
-+ }
-+ uni2ansi (ds->name, ptr, namlen);
-+ ptr += namlen;
-+ *ptr = 0;
-+ }
-+
-+ cmp = (!*dirname) ? -1 : substring (dirname, namebuf);
-+#ifndef STAGE1_5
-+ if (print_possibilities && ch != '/'
-+ && cmp <= 0) {
-+ if (print_possibilities > 0)
-+ print_possibilities = -print_possibilities;
-+ print_a_completion (namebuf);
-+ } else
-+#endif
-+ if (cmp == 0) {
-+ parent_inum = inum;
-+ inum = de->inumber;
-+ *(dirname = rest) = ch;
-+ break;
-+ }
-+ de = next_dentry ();
-+ if (de == NULL) {
-+ if (print_possibilities < 0)
-+ return 1;
-+
-+ errnum = ERR_FILE_NOT_FOUND;
-+ *rest = ch;
-+ return 0;
-+ }
-+ }
-+ }
-+}
-+
-+int
-+jfs_embed (int *start_sector, int needed_sectors)
-+{
-+ struct jfs_superblock super;
-+
-+ if (needed_sectors > 63
-+ || !devread (SUPER1_OFF >> SECTOR_BITS, 0,
-+ sizeof (struct jfs_superblock),
-+ (char *)&super)
-+ || (super.s_magic != JFS_MAGIC)) {
-+ return 0;
-+ }
-+
-+ *start_sector = 1;
-+ return 1;
-+}
-+
-+#endif /* FSYS_JFS */
-diff -urN --exclude-from=xlist-core grub-0.90/stage2/fsys_xfs.c grub-0.90.jfs+xfs/stage2/fsys_xfs.c
---- grub-0.90/stage2/fsys_xfs.c Thu Jan 1 03:00:00 1970
-+++ grub-0.90.jfs+xfs/stage2/fsys_xfs.c Wed Aug 29 11:24:18 2001
-@@ -0,0 +1,617 @@
-+/*
-+ * fsys_xfs.c - an implementation for the SGI XFS file system
-+ *
-+ * Copyright (C) 2001 Serguei Tzukanov
-+ *
-+ * This program is free software; you can redistribute it and/or modify
-+ * it under the terms of the GNU General Public License as published by
-+ * the Free Software Foundation; either version 2 of the License, or
-+ * (at your option) any later version.
-+ *
-+ * This program is distributed in the hope that it will be useful,
-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-+ * GNU General Public License for more details.
-+ *
-+ * You should have received a copy of the GNU General Public License
-+ * along with this program; if not, write to the Free Software
-+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-+ */
-+
-+#ifdef FSYS_XFS
-+
-+#include "shared.h"
-+#include "filesys.h"
-+#include "xfs.h"
-+
-+#define MAX_LINK_COUNT 8
-+
-+typedef struct xad {
-+ xfs_fileoff_t offset;
-+ xfs_fsblock_t start;
-+ xfs_filblks_t len;
-+} xad_t;
-+
-+struct xfs_info {
-+ int bsize;
-+ int dirbsize;
-+ int isize;
-+ unsigned int agblocks;
-+ int bdlog;
-+ int blklog;
-+ int inopblog;
-+ int agblklog;
-+ int agnolog;
-+ unsigned int nextents;
-+ xfs_daddr_t next;
-+ xfs_daddr_t daddr;
-+ xfs_dablk_t forw;
-+ xfs_dablk_t dablk;
-+ xfs_bmbt_rec_32_t *xt;
-+ xfs_bmbt_ptr_t ptr0;
-+ int btnode_ptr0_off;
-+ int i8param;
-+ int dirpos;
-+ int dirmax;
-+ int blkoff;
-+ int fpos;
-+ xfs_ino_t rootino;
-+};
-+
-+static struct xfs_info xfs;
-+
-+#define dirbuf ((char *)FSYS_BUF)
-+#define filebuf ((char *)FSYS_BUF + 4096)
-+#define inode ((xfs_dinode_t *)((char *)FSYS_BUF + 8192))
-+#define icore (inode->di_core)
-+
-+#define mask32lo(n) (((__uint32_t)1 << (n)) - 1)
-+
-+#define XFS_INO_MASK(k) ((__uint32_t)((1ULL << (k)) - 1))
-+#define XFS_INO_OFFSET_BITS xfs.inopblog
-+#define XFS_INO_AGBNO_BITS xfs.agblklog
-+#define XFS_INO_AGINO_BITS (xfs.agblklog + xfs.inopblog)
-+#define XFS_INO_AGNO_BITS xfs.agnolog
-+
-+static inline xfs_agblock_t
-+agino2agbno (xfs_agino_t agino)
-+{
-+ return agino >> XFS_INO_OFFSET_BITS;
-+}
-+
-+static inline xfs_agnumber_t
-+ino2agno (xfs_ino_t ino)
-+{
-+ return ino >> XFS_INO_AGINO_BITS;
-+}
-+
-+static inline xfs_agino_t
-+ino2agino (xfs_ino_t ino)
-+{
-+ return ino & XFS_INO_MASK(XFS_INO_AGINO_BITS);
-+}
-+
-+static inline int
-+ino2offset (xfs_ino_t ino)
-+{
-+ return ino & XFS_INO_MASK(XFS_INO_OFFSET_BITS);
-+}
-+
-+static inline __const__ __uint16_t
-+le16 (__uint16_t x)
-+{
-+ __asm__("xchgb %b0,%h0" \
-+ : "=q" (x) \
-+ : "0" (x)); \
-+ return x;
-+}
-+
-+static inline __const__ __uint32_t
-+le32 (__uint32_t x)
-+{
-+ __asm__("bswap %0" : "=r" (x) : "0" (x));
-+ return x;
-+}
-+
-+static inline __const__ __uint64_t
-+le64 (__uint64_t x)
-+{
-+ __uint32_t h = x >> 32;
-+ __uint32_t l = x & ((1ULL<<32)-1);
-+ return (((__uint64_t)le32(l)) << 32) | ((__uint64_t)(le32(h)));
-+}
-+
-+
-+static xfs_fsblock_t
-+xt_start (xfs_bmbt_rec_32_t *r)
-+{
-+ return (((xfs_fsblock_t)(le32 (r->l1) & mask32lo(9))) << 43) |
-+ (((xfs_fsblock_t)le32 (r->l2)) << 11) |
-+ (((xfs_fsblock_t)le32 (r->l3)) >> 21);
-+}
-+
-+static xfs_fileoff_t
-+xt_offset (xfs_bmbt_rec_32_t *r)
-+{
-+ return (((xfs_fileoff_t)le32 (r->l0) &
-+ mask32lo(31)) << 23) |
-+ (((xfs_fileoff_t)le32 (r->l1)) >> 9);
-+}
-+
-+static xfs_filblks_t
-+xt_len (xfs_bmbt_rec_32_t *r)
-+{
-+ return le32(r->l3) & mask32lo(21);
-+}
-+
-+static inline int
-+xfs_highbit32(__uint32_t v)
-+{
-+ int i;
-+
-+ if (--v) {
-+ for (i = 0; i < 31; i++, v >>= 1) {
-+ if (v == 0)
-+ return i;
-+ }
-+ }
-+ return 0;
-+}
-+
-+static int
-+isinxt (xfs_fileoff_t key, xfs_fileoff_t offset, xfs_filblks_t len)
-+{
-+ return (key >= offset) ? (key < offset + len ? 1 : 0) : 0;
-+}
-+
-+static xfs_daddr_t
-+agb2daddr (xfs_agnumber_t agno, xfs_agblock_t agbno)
-+{
-+ return ((xfs_fsblock_t)agno*xfs.agblocks + agbno) << xfs.bdlog;
-+}
-+
-+static xfs_daddr_t
-+fsb2daddr (xfs_fsblock_t fsbno)
-+{
-+ return agb2daddr ((xfs_agnumber_t)(fsbno >> xfs.agblklog),
-+ (xfs_agblock_t)(fsbno & mask32lo(xfs.agblklog)));
-+}
-+
-+#undef offsetof
-+#define offsetof(t,m) ((int)&(((t *)0)->m))
-+
-+static inline int
-+btroot_maxrecs (void)
-+{
-+ int tmp = icore.di_forkoff ? (icore.di_forkoff << 3) : xfs.isize;
-+
-+ return (tmp - sizeof(xfs_bmdr_block_t) - offsetof(xfs_dinode_t, di_u)) /
-+ (sizeof (xfs_bmbt_key_t) + sizeof (xfs_bmbt_ptr_t));
-+}
-+
-+static int
-+di_read (xfs_ino_t ino)
-+{
-+ xfs_agino_t agino;
-+ xfs_agnumber_t agno;
-+ xfs_agblock_t agbno;
-+ xfs_daddr_t daddr;
-+ int offset;
-+
-+ agno = ino2agno (ino);
-+ agino = ino2agino (ino);
-+ agbno = agino2agbno (agino);
-+ offset = ino2offset (ino);
-+ daddr = agb2daddr (agno, agbno);
-+
-+ devread (daddr, offset*xfs.isize, xfs.isize, (char *)inode);
-+
-+ xfs.ptr0 = *(xfs_bmbt_ptr_t *)
-+ (inode->di_u.di_c + sizeof(xfs_bmdr_block_t)
-+ + btroot_maxrecs ()*sizeof(xfs_bmbt_key_t));
-+
-+ return 1;
-+}
-+
-+static void
-+init_extents (void)
-+{
-+ xfs_bmbt_ptr_t ptr0;
-+ xfs_btree_lblock_t h;
-+
-+ switch (icore.di_format) {
-+ case XFS_DINODE_FMT_EXTENTS:
-+ xfs.xt = inode->di_u.di_bmx;
-+ xfs.nextents = le32 (icore.di_nextents);
-+ break;
-+ case XFS_DINODE_FMT_BTREE:
-+ ptr0 = xfs.ptr0;
-+ for (;;) {
-+ xfs.daddr = fsb2daddr (le64(ptr0));
-+ devread (xfs.daddr, 0,
-+ sizeof(xfs_btree_lblock_t), (char *)&h);
-+ if (!h.bb_level) {
-+ xfs.nextents = le16(h.bb_numrecs);
-+ xfs.next = fsb2daddr (le64(h.bb_rightsib));
-+ xfs.fpos = sizeof(xfs_btree_block_t);
-+ return;
-+ }
-+ devread (xfs.daddr, xfs.btnode_ptr0_off,
-+ sizeof(xfs_bmbt_ptr_t), (char *)&ptr0);
-+ }
-+ }
-+}
-+
-+static xad_t *
-+next_extent (void)
-+{
-+ static xad_t xad;
-+
-+ switch (icore.di_format) {
-+ case XFS_DINODE_FMT_EXTENTS:
-+ if (xfs.nextents == 0)
-+ return NULL;
-+ break;
-+ case XFS_DINODE_FMT_BTREE:
-+ if (xfs.nextents == 0) {
-+ xfs_btree_lblock_t h;
-+ if (xfs.next == 0)
-+ return NULL;
-+ xfs.daddr = xfs.next;
-+ devread (xfs.daddr, 0, sizeof(xfs_btree_lblock_t), (char *)&h);
-+ xfs.nextents = le16(h.bb_numrecs);
-+ xfs.next = fsb2daddr (le64(h.bb_rightsib));
-+ xfs.fpos = sizeof(xfs_btree_block_t);
-+ }
-+ /* Yeah, I know that's slow, but I really don't care */
-+ devread (xfs.daddr, xfs.fpos, sizeof(xfs_bmbt_rec_t), filebuf);
-+ xfs.xt = (xfs_bmbt_rec_32_t *)filebuf;
-+ xfs.fpos += sizeof(xfs_bmbt_rec_32_t);
-+ }
-+ xad.offset = xt_offset (xfs.xt);
-+ xad.start = xt_start (xfs.xt);
-+ xad.len = xt_len (xfs.xt);
-+ ++xfs.xt;
-+ --xfs.nextents;
-+
-+ return &xad;
-+}
-+
-+/*
-+ * Name lies - the function reads only first 100 bytes
-+ */
-+static void
-+xfs_dabread (void)
-+{
-+ xad_t *xad;
-+ xfs_fileoff_t offset;;
-+
-+ init_extents ();
-+ while ((xad = next_extent ())) {
-+ offset = xad->offset;
-+ if (isinxt (xfs.dablk, offset, xad->len)) {
-+ devread (fsb2daddr (xad->start + xfs.dablk - offset),
-+ 0, 100, dirbuf);
-+ break;
-+ }
-+ }
-+}
-+
-+static inline xfs_ino_t
-+sf_ino (char *sfe, int namelen)
-+{
-+ void *p = sfe + namelen + 3;
-+
-+ return (xfs.i8param == 0)
-+ ? le64(*(xfs_ino_t *)p) : le32(*(__uint32_t *)p);
-+}
-+
-+static inline xfs_ino_t
-+sf_parent_ino (void)
-+{
-+ return (xfs.i8param == 0)
-+ ? le64(*(xfs_ino_t *)(&inode->di_u.di_dir2sf.hdr.parent))
-+ : le32(*(__uint32_t *)(&inode->di_u.di_dir2sf.hdr.parent));
-+}
-+
-+static inline int
-+roundup8 (int n)
-+{
-+ return ((n+7)&~7);
-+}
-+
-+static char *
-+next_dentry (xfs_ino_t *ino)
-+{
-+ int namelen = 1;
-+ int toread;
-+ static char *usual[2] = {".", ".."};
-+ static xfs_dir2_sf_entry_t *sfe;
-+ char *name = usual[0];
-+
-+ if (xfs.dirpos >= xfs.dirmax) {
-+ if (xfs.forw == 0)
-+ return NULL;
-+ xfs.dablk = xfs.forw;
-+ xfs_dabread ();
-+#define h ((xfs_dir2_leaf_hdr_t *)dirbuf)
-+ xfs.dirmax = le16 (h->count) - le16 (h->stale);
-+ xfs.forw = le32 (h->info.forw);
-+#undef h
-+ xfs.dirpos = 0;
-+ }
-+
-+ switch (icore.di_format) {
-+ case XFS_DINODE_FMT_LOCAL:
-+ switch (xfs.dirpos) {
-+ case -2:
-+ *ino = 0;
-+ break;
-+ case -1:
-+ *ino = sf_parent_ino ();
-+ ++name;
-+ ++namelen;
-+ sfe = (xfs_dir2_sf_entry_t *)
-+ (inode->di_u.di_c
-+ + sizeof(xfs_dir2_sf_hdr_t)
-+ - xfs.i8param);
-+ break;
-+ default:
-+ namelen = sfe->namelen;
-+ *ino = sf_ino ((char *)sfe, namelen);
-+ name = sfe->name;
-+ sfe = (xfs_dir2_sf_entry_t *)
-+ ((char *)sfe + namelen + 11 - xfs.i8param);
-+ }
-+ break;
-+ case XFS_DINODE_FMT_BTREE:
-+ case XFS_DINODE_FMT_EXTENTS:
-+#define dau ((xfs_dir2_data_union_t *)dirbuf)
-+ for (;;) {
-+ if (xfs.blkoff >= xfs.dirbsize) {
-+ xfs.blkoff = sizeof(xfs_dir2_data_hdr_t);
-+ filepos &= ~(xfs.dirbsize - 1);
-+ filepos |= xfs.blkoff;
-+ }
-+ xfs_read (dirbuf, 4);
-+ xfs.blkoff += 4;
-+ if (dau->unused.freetag == XFS_DIR2_DATA_FREE_TAG) {
-+ toread = roundup8 (le16(dau->unused.length)) - 4;
-+ xfs.blkoff += toread;
-+ filepos += toread;
-+ continue;
-+ }
-+ break;
-+ }
-+ xfs_read ((char *)dirbuf + 4, 5);
-+ *ino = le64 (dau->entry.inumber);
-+ namelen = dau->entry.namelen;
-+#undef dau
-+ toread = roundup8 (namelen + 11) - 9;
-+ xfs_read (dirbuf, toread);
-+ name = (char *)dirbuf;
-+ xfs.blkoff += toread + 5;
-+ }
-+ ++xfs.dirpos;
-+ name[namelen] = 0;
-+
-+ return name;
-+}
-+
-+static char *
-+first_dentry (xfs_ino_t *ino)
-+{
-+ xfs.forw = 0;
-+ switch (icore.di_format) {
-+ case XFS_DINODE_FMT_LOCAL:
-+ xfs.dirmax = inode->di_u.di_dir2sf.hdr.count;
-+ xfs.i8param = inode->di_u.di_dir2sf.hdr.i8count ? 0 : 4;
-+ xfs.dirpos = -2;
-+ break;
-+ case XFS_DINODE_FMT_EXTENTS:
-+ case XFS_DINODE_FMT_BTREE:
-+ filepos = 0;
-+ xfs_read (dirbuf, sizeof(xfs_dir2_data_hdr_t));
-+ if (((xfs_dir2_data_hdr_t *)dirbuf)->magic == le32(XFS_DIR2_BLOCK_MAGIC)) {
-+#define tail ((xfs_dir2_block_tail_t *)dirbuf)
-+ filepos = xfs.dirbsize - sizeof(*tail);
-+ xfs_read (dirbuf, sizeof(*tail));
-+ xfs.dirmax = le32 (tail->count) - le32 (tail->stale);
-+#undef tail
-+ } else {
-+ xfs.dablk = (1ULL << 35) >> xfs.blklog;
-+#define h ((xfs_dir2_leaf_hdr_t *)dirbuf)
-+#define n ((xfs_da_intnode_t *)dirbuf)
-+ for (;;) {
-+ xfs_dabread ();
-+ if ((n->hdr.info.magic == le16(XFS_DIR2_LEAFN_MAGIC))
-+ || (n->hdr.info.magic == le16(XFS_DIR2_LEAF1_MAGIC))) {
-+ xfs.dirmax = le16 (h->count) - le16 (h->stale);
-+ xfs.forw = le32 (h->info.forw);
-+ break;
-+ }
-+ xfs.dablk = le32 (n->btree[0].before);
-+ }
-+#undef n
-+#undef h
-+ }
-+ xfs.blkoff = sizeof(xfs_dir2_data_hdr_t);
-+ filepos = xfs.blkoff;
-+ xfs.dirpos = 0;
-+ }
-+ return next_dentry (ino);
-+}
-+
-+int
-+xfs_mount (void)
-+{
-+ xfs_sb_t super;
-+
-+ if (!devread (0, 0, sizeof(super), (char *)&super)
-+ || (le32(super.sb_magicnum) != XFS_SB_MAGIC)
-+ || ((le16(super.sb_versionnum)
-+ & XFS_SB_VERSION_NUMBITS) != XFS_SB_VERSION_4) ) {
-+ return 0;
-+ }
-+
-+ xfs.bsize = le32 (super.sb_blocksize);
-+ xfs.blklog = super.sb_blocklog;
-+ xfs.bdlog = xfs.blklog - SECTOR_BITS;
-+ xfs.rootino = le64 (super.sb_rootino);
-+ xfs.isize = le16 (super.sb_inodesize);
-+ xfs.agblocks = le32 (super.sb_agblocks);
-+ xfs.dirbsize = xfs.bsize << super.sb_dirblklog;
-+
-+ xfs.inopblog = super.sb_inopblog;
-+ xfs.agblklog = super.sb_agblklog;
-+ xfs.agnolog = xfs_highbit32 (le32(super.sb_agcount));
-+
-+ xfs.btnode_ptr0_off =
-+ ((xfs.bsize - sizeof(xfs_btree_block_t)) /
-+ (sizeof (xfs_bmbt_key_t) + sizeof (xfs_bmbt_ptr_t)))
-+ * sizeof(xfs_bmbt_key_t) + sizeof(xfs_btree_block_t);
-+
-+ return 1;
-+}
-+
-+int
-+xfs_read (char *buf, int len)
-+{
-+ xad_t *xad;
-+ xfs_fileoff_t endofprev, endofcur, offset;
-+ xfs_filblks_t xadlen;
-+ int toread, startpos, endpos;
-+
-+ if (icore.di_format == XFS_DINODE_FMT_LOCAL) {
-+ grub_memmove (buf, inode->di_u.di_c + filepos, len);
-+ filepos += len;
-+ return len;
-+ }
-+
-+ startpos = filepos;
-+ endpos = filepos + len;
-+ endofprev = (xfs_fileoff_t)-1;
-+ init_extents ();
-+ while (len > 0 && (xad = next_extent ())) {
-+ offset = xad->offset;
-+ xadlen = xad->len;
-+ if (isinxt (filepos >> xfs.blklog, offset, xadlen)) {
-+ endofcur = (offset + xadlen) << xfs.blklog;
-+ toread = (endofcur >= endpos)
-+ ? len : (endofcur - filepos);
-+#ifndef STAGE1_5
-+ disk_read_func = disk_read_hook;
-+#endif /* STAGE1_5 */
-+ devread (fsb2daddr (xad->start),
-+ filepos - (offset << xfs.blklog), toread, buf);
-+#ifndef STAGE1_5
-+ disk_read_func = NULL;
-+#endif /* STAGE1_5 */
-+ buf += toread;
-+ len -= toread;
-+ filepos += toread;
-+ } else if (offset > endofprev) {
-+ toread = ((offset << xfs.blklog) >= endpos)
-+ ? len : ((offset - endofprev) << xfs.blklog);
-+ len -= toread;
-+ filepos += toread;
-+ for (; toread; toread--) {
-+ *buf++ = 0;
-+ }
-+ continue;
-+ }
-+ endofprev = offset + xadlen;
-+ }
-+
-+ return filepos - startpos;
-+}
-+
-+int
-+xfs_dir (char *dirname)
-+{
-+ xfs_ino_t ino, parent_ino, new_ino;
-+ xfs_fsize_t di_size;
-+ int di_mode;
-+ int cmp, n, link_count;
-+ char linkbuf[xfs.bsize];
-+ char *rest, *name, ch;
-+
-+ parent_ino = ino = xfs.rootino;
-+ link_count = 0;
-+ for (;;) {
-+ di_read (ino);
-+ di_size = le64 (icore.di_size);
-+ di_mode = le16 (icore.di_mode);
-+
-+ if ((di_mode & IFMT) == IFLNK) {
-+ if (++link_count > MAX_LINK_COUNT) {
-+ errnum = ERR_SYMLINK_LOOP;
-+ return 0;
-+ }
-+ if (di_size < xfs.bsize - 1) {
-+ filepos = 0;
-+ filemax = di_size;
-+ n = xfs_read (linkbuf, filemax);
-+ } else {
-+ errnum = ERR_FILELENGTH;
-+ return 0;
-+ }
-+
-+ ino = (linkbuf[0] == '/') ? xfs.rootino : parent_ino;
-+ while (n < (xfs.bsize - 1) && (linkbuf[n++] = *dirname++));
-+ linkbuf[n] = 0;
-+ dirname = linkbuf;
-+ continue;
-+ }
-+
-+ if (!*dirname || isspace (*dirname)) {
-+ if ((di_mode & IFMT) != IFREG) {
-+ errnum = ERR_BAD_FILETYPE;
-+ return 0;
-+ }
-+ filepos = 0;
-+ filemax = di_size;
-+ return 1;
-+ }
-+
-+ if ((di_mode & IFMT) != IFDIR) {
-+ errnum = ERR_BAD_FILETYPE;
-+ return 0;
-+ }
-+
-+ for (; *dirname == '/'; dirname++);
-+
-+ for (rest = dirname; (ch = *rest) && !isspace (ch) && ch != '/'; rest++);
-+ *rest = 0;
-+
-+ name = first_dentry (&new_ino);
-+ for (;;) {
-+ cmp = (!*dirname) ? -1 : substring (dirname, name);
-+#ifndef STAGE1_5
-+ if (print_possibilities && ch != '/' && cmp <= 0) {
-+ if (print_possibilities > 0)
-+ print_possibilities = -print_possibilities;
-+ print_a_completion (name);
-+ } else
-+#endif
-+ if (cmp == 0) {
-+ parent_ino = ino;
-+ if (new_ino)
-+ ino = new_ino;
-+ *(dirname = rest) = ch;
-+ break;
-+ }
-+ name = next_dentry (&new_ino);
-+ if (name == NULL) {
-+ if (print_possibilities < 0)
-+ return 1;
-+
-+ errnum = ERR_FILE_NOT_FOUND;
-+ *rest = ch;
-+ return 0;
-+ }
-+ }
-+ }
-+}
-+
-+#endif /* FSYS_XFS */
-diff -urN --exclude-from=xlist-core grub-0.90/stage2/jfs.h grub-0.90.jfs+xfs/stage2/jfs.h
---- grub-0.90/stage2/jfs.h Thu Jan 1 03:00:00 1970
-+++ grub-0.90.jfs+xfs/stage2/jfs.h Mon Aug 27 12:57:53 2001
-@@ -0,0 +1,601 @@
-+/*
-+ * jfs.h - an extractions from linux/include/linux/jfs/jfs* into one file
-+ *
-+ * Copyright (c) International Business Machines Corp., 2000
-+ *
-+ * This program is free software; you can redistribute it and/or modify
-+ * it under the terms of the GNU General Public License as published by
-+ * the Free Software Foundation; either version 2 of the License, or
-+ * (at your option) any later version.
-+ *
-+ * This program is distributed in the hope that it will be useful,
-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
-+ * the GNU General Public License for more details.
-+ *
-+ * You should have received a copy of the GNU General Public License
-+ * along with this program; if not, write to the Free Software
-+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-+ *
-+ */
-+
-+#ifndef _JFS_H_
-+#define _JFS_H_
-+
-+/* those are from jfs_filsys.h */
-+
-+/*
-+ * file system option (superblock flag)
-+ */
-+/* platform option (conditional compilation) */
-+#define JFS_AIX 0x80000000 /* AIX support */
-+/* POSIX name/directory support */
-+
-+#define JFS_OS2 0x40000000 /* OS/2 support */
-+/* case-insensitive name/directory support */
-+
-+#define JFS_LINUX 0x10000000 /* Linux support */
-+/* case-sensitive name/directory support */
-+
-+/* directory option */
-+#define JFS_UNICODE 0x00000001 /* unicode name */
-+
-+/* bba */
-+#define JFS_SWAP_BYTES 0x00100000 /* running on big endian computer */
-+
-+
-+/*
-+ * buffer cache configuration
-+ */
-+/* page size */
-+#ifdef PSIZE
-+#undef PSIZE
-+#endif
-+#define PSIZE 4096 /* page size (in byte) */
-+
-+/*
-+ * fs fundamental size
-+ *
-+ * PSIZE >= file system block size >= PBSIZE >= DISIZE
-+ */
-+#define PBSIZE 512 /* physical block size (in byte) */
-+#define DISIZE 512 /* on-disk inode size (in byte) */
-+#define L2DISIZE 9
-+#define INOSPERIAG 4096 /* number of disk inodes per iag */
-+#define L2INOSPERIAG 12
-+#define INOSPEREXT 32 /* number of disk inode per extent */
-+#define L2INOSPEREXT 5
-+
-+/* Minimum number of bytes supported for a JFS partition */
-+#define MINJFS (0x1000000)
-+
-+/*
-+ * fixed byte offset address
-+ */
-+#define SUPER1_OFF 0x8000 /* primary superblock */
-+
-+#define AITBL_OFF (SUPER1_OFF + PSIZE + (PSIZE << 1))
-+
-+/*
-+ * fixed reserved inode number
-+ */
-+/* aggregate inode */
-+#define AGGREGATE_I 1 /* aggregate inode map inode */
-+#define FILESYSTEM_I 16 /* 1st/only fileset inode in ait:
-+ * fileset inode map inode
-+ */
-+
-+/* per fileset inode */
-+#define ROOT_I 2 /* fileset root inode */
-+
-+/*
-+ * directory configuration
-+ */
-+#define JFS_NAME_MAX 255
-+#define JFS_PATH_MAX PSIZE
-+
-+typedef unsigned char u8;
-+typedef char s8;
-+typedef unsigned short u16;
-+typedef short s16;
-+typedef unsigned int u32;
-+typedef int s32;
-+typedef unsigned long long u64;
-+typedef long long s64;
-+
-+typedef u16 UniChar;
-+
-+/* these from jfs_btree.h */
-+
-+/* btpaget_t flag */
-+#define BT_TYPE 0x07 /* B+-tree index */
-+#define BT_ROOT 0x01 /* root page */
-+#define BT_LEAF 0x02 /* leaf page */
-+#define BT_INTERNAL 0x04 /* internal page */
-+#define BT_RIGHTMOST 0x10 /* rightmost page */
-+#define BT_LEFTMOST 0x20 /* leftmost page */
-+
-+/* those are from jfs_types.h */
-+
-+struct timestruc_t {
-+ u32 tv_sec;
-+ u32 tv_nsec;
-+};
-+
-+/*
-+ * physical xd (pxd)
-+ */
-+typedef struct {
-+ unsigned len:24;
-+ unsigned addr1:8;
-+ u32 addr2;
-+} pxd_t;
-+
-+/* xd_t field extraction */
-+#define lengthPXD(pxd) ((pxd)->len)
-+#define addressPXD(pxd) (((s64)((pxd)->addr1)) << 32 | ((pxd)->addr2))
-+
-+/*
-+ * data extent descriptor (dxd)
-+ */
-+typedef struct {
-+ unsigned flag:8; /* 1: flags */
-+ unsigned rsrvd:24; /* 3: */
-+ u32 size; /* 4: size in byte */
-+ unsigned len:24; /* 3: length in unit of fsblksize */
-+ unsigned addr1:8; /* 1: address in unit of fsblksize */
-+ u32 addr2; /* 4: address in unit of fsblksize */
-+} dxd_t; /* - 16 - */
-+
-+/*
-+ * DASD limit information - stored in directory inode
-+ */
-+typedef struct dasd {
-+ u8 thresh; /* Alert Threshold (in percent) */
-+ u8 delta; /* Alert Threshold delta (in percent) */
-+ u8 rsrvd1;
-+ u8 limit_hi; /* DASD limit (in logical blocks) */
-+ u32 limit_lo; /* DASD limit (in logical blocks) */
-+ u8 rsrvd2[3];
-+ u8 used_hi; /* DASD usage (in logical blocks) */
-+ u32 used_lo; /* DASD usage (in logical blocks) */
-+} dasd_t;
-+
-+
-+/* from jfs_superblock.h */
-+
-+#define JFS_MAGIC 0x3153464A /* "JFS1" */
-+
-+struct jfs_superblock
-+{
-+ u32 s_magic; /* 4: magic number */
-+ u32 s_version; /* 4: version number */
-+
-+ s64 s_size; /* 8: aggregate size in hardware/LVM blocks;
-+ * VFS: number of blocks
-+ */
-+ s32 s_bsize; /* 4: aggregate block size in bytes;
-+ * VFS: fragment size
-+ */
-+ s16 s_l2bsize; /* 2: log2 of s_bsize */
-+ s16 s_l2bfactor; /* 2: log2(s_bsize/hardware block size) */
-+ s32 s_pbsize; /* 4: hardware/LVM block size in bytes */
-+ s16 s_l2pbsize; /* 2: log2 of s_pbsize */
-+ s16 pad; /* 2: padding necessary for alignment */
-+
-+ u32 s_agsize; /* 4: allocation group size in aggr. blocks */
-+
-+ u32 s_flag; /* 4: aggregate attributes:
-+ * see jfs_filsys.h
-+ */
-+ u32 s_state; /* 4: mount/unmount/recovery state:
-+ * see jfs_filsys.h
-+ */
-+ s32 s_compress; /* 4: > 0 if data compression */
-+
-+ pxd_t s_ait2; /* 8: first extent of secondary
-+ * aggregate inode table
-+ */
-+
-+ pxd_t s_aim2; /* 8: first extent of secondary
-+ * aggregate inode map
-+ */
-+ u32 s_logdev; /* 4: device address of log */
-+ s32 s_logserial; /* 4: log serial number at aggregate mount */
-+ pxd_t s_logpxd; /* 8: inline log extent */
-+
-+ pxd_t s_fsckpxd; /* 8: inline fsck work space extent */
-+
-+ struct timestruc_t s_time; /* 8: time last updated */
-+
-+ s32 s_fsckloglen; /* 4: Number of filesystem blocks reserved for
-+ * the fsck service log.
-+ * N.B. These blocks are divided among the
-+ * versions kept. This is not a per
-+ * version size.
-+ * N.B. These blocks are included in the
-+ * length field of s_fsckpxd.
-+ */
-+ s8 s_fscklog; /* 1: which fsck service log is most recent
-+ * 0 => no service log data yet
-+ * 1 => the first one
-+ * 2 => the 2nd one
-+ */
-+ char s_fpack[11]; /* 11: file system volume name
-+ * N.B. This must be 11 bytes to
-+ * conform with the OS/2 BootSector
-+ * requirements
-+ */
-+
-+ /* extendfs() parameter under s_state & FM_EXTENDFS */
-+ s64 s_xsize; /* 8: extendfs s_size */
-+ pxd_t s_xfsckpxd; /* 8: extendfs fsckpxd */
-+ pxd_t s_xlogpxd; /* 8: extendfs logpxd */
-+ /* - 128 byte boundary - */
-+
-+ /*
-+ * DFS VFS support (preliminary)
-+ */
-+ char s_attach; /* 1: VFS: flag: set when aggregate is attached
-+ */
-+ u8 rsrvd4[7]; /* 7: reserved - set to 0 */
-+
-+ u64 totalUsable; /* 8: VFS: total of 1K blocks which are
-+ * available to "normal" (non-root) users.
-+ */
-+ u64 minFree; /* 8: VFS: # of 1K blocks held in reserve for
-+ * exclusive use of root. This value can be 0,
-+ * and if it is then totalUsable will be equal
-+ * to # of blocks in aggregate. I believe this
-+ * means that minFree + totalUsable = # blocks.
-+ * In that case, we don't need to store both
-+ * totalUsable and minFree since we can compute
-+ * one from the other. I would guess minFree
-+ * would be the one we should store, and
-+ * totalUsable would be the one we should
-+ * compute. (Just a guess...)
-+ */
-+
-+ u64 realFree; /* 8: VFS: # of free 1K blocks can be used by
-+ * "normal" users. It may be this is something
-+ * we should compute when asked for instead of
-+ * storing in the superblock. I don't know how
-+ * often this information is needed.
-+ */
-+ /*
-+ * graffiti area
-+ */
-+};
-+
-+/* from jfs_dtree.h */
-+
-+/*
-+ * entry segment/slot
-+ *
-+ * an entry consists of type dependent head/only segment/slot and
-+ * additional segments/slots linked vi next field;
-+ * N.B. last/only segment of entry is terminated by next = -1;
-+ */
-+/*
-+ * directory page slot
-+ */
-+typedef struct {
-+ s8 next; /* 1: */
-+ s8 cnt; /* 1: */
-+ UniChar name[15]; /* 30: */
-+} dtslot_t; /* (32) */
-+
-+#define DTSLOTDATALEN 15
-+
-+/*
-+ * internal node entry head/only segment
-+ */
-+typedef struct {
-+ pxd_t xd; /* 8: child extent descriptor */
-+
-+ s8 next; /* 1: */
-+ u8 namlen; /* 1: */
-+ UniChar name[11]; /* 22: 2-byte aligned */
-+} idtentry_t; /* (32) */
-+
-+/*
-+ * leaf node entry head/only segment
-+ *
-+ * For legacy filesystems, name contains 13 unichars -- no index field
-+ */
-+typedef struct {
-+ u32 inumber; /* 4: 4-byte aligned */
-+ s8 next; /* 1: */
-+ u8 namlen; /* 1: */
-+ UniChar name[11]; /* 22: 2-byte aligned */
-+ u32 index; /* 4: index into dir_table */
-+} ldtentry_t; /* (32) */
-+
-+#define DTLHDRDATALEN 11
-+
-+/*
-+ * dir_table used for directory traversal during readdir
-+*/
-+
-+/*
-+ * Maximum entry in inline directory table
-+ */
-+
-+typedef struct dir_table_slot {
-+ u8 rsrvd; /* 1: */
-+ u8 flag; /* 1: 0 if free */
-+ u8 slot; /* 1: slot within leaf page of entry */
-+ u8 addr1; /* 1: upper 8 bits of leaf page address */
-+ u32 addr2; /* 4: lower 32 bits of leaf page address -OR-
-+ index of next entry when this entry was deleted */
-+} dir_table_slot_t; /* (8) */
-+
-+/*
-+ * directory root page (in-line in on-disk inode):
-+ *
-+ * cf. dtpage_t below.
-+ */
-+typedef union {
-+ struct {
-+ dasd_t DASD; /* 16: DASD limit/usage info F226941 */
-+
-+ u8 flag; /* 1: */
-+ s8 nextindex; /* 1: next free entry in stbl */
-+ s8 freecnt; /* 1: free count */
-+ s8 freelist; /* 1: freelist header */
-+
-+ u32 idotdot; /* 4: parent inode number */
-+
-+ s8 stbl[8]; /* 8: sorted entry index table */
-+ } header; /* (32) */
-+
-+ dtslot_t slot[9];
-+} dtroot_t;
-+
-+/*
-+ * directory regular page:
-+ *
-+ * entry slot array of 32 byte slot
-+ *
-+ * sorted entry slot index table (stbl):
-+ * contiguous slots at slot specified by stblindex,
-+ * 1-byte per entry
-+ * 512 byte block: 16 entry tbl (1 slot)
-+ * 1024 byte block: 32 entry tbl (1 slot)
-+ * 2048 byte block: 64 entry tbl (2 slot)
-+ * 4096 byte block: 128 entry tbl (4 slot)
-+ *
-+ * data area:
-+ * 512 byte block: 16 - 2 = 14 slot
-+ * 1024 byte block: 32 - 2 = 30 slot
-+ * 2048 byte block: 64 - 3 = 61 slot
-+ * 4096 byte block: 128 - 5 = 123 slot
-+ *
-+ * N.B. index is 0-based; index fields refer to slot index
-+ * except nextindex which refers to entry index in stbl;
-+ * end of entry stot list or freelist is marked with -1.
-+ */
-+typedef union {
-+ struct {
-+ s64 next; /* 8: next sibling */
-+ s64 prev; /* 8: previous sibling */
-+
-+ u8 flag; /* 1: */
-+ s8 nextindex; /* 1: next entry index in stbl */
-+ s8 freecnt; /* 1: */
-+ s8 freelist; /* 1: slot index of head of freelist */
-+
-+ u8 maxslot; /* 1: number of slots in page slot[] */
-+ s8 stblindex; /* 1: slot index of start of stbl */
-+ u8 rsrvd[2]; /* 2: */
-+
-+ pxd_t self; /* 8: self pxd */
-+ } header; /* (32) */
-+
-+ dtslot_t slot[128];
-+} dtpage_t;
-+
-+/* from jfs_xtree.h */
-+
-+/*
-+ * extent allocation descriptor (xad)
-+ */
-+typedef struct xad {
-+ unsigned flag:8; /* 1: flag */
-+ unsigned rsvrd:16; /* 2: reserved */
-+ unsigned off1:8; /* 1: offset in unit of fsblksize */
-+ u32 off2; /* 4: offset in unit of fsblksize */
-+ unsigned len:24; /* 3: length in unit of fsblksize */
-+ unsigned addr1:8; /* 1: address in unit of fsblksize */
-+ u32 addr2; /* 4: address in unit of fsblksize */
-+} xad_t; /* (16) */
-+
-+/* xad_t field extraction */
-+#define offsetXAD(xad) (((s64)((xad)->off1)) << 32 | ((xad)->off2))
-+#define addressXAD(xad) (((s64)((xad)->addr1)) << 32 | ((xad)->addr2))
-+#define lengthXAD(xad) ((xad)->len)
-+
-+/* possible values for maxentry */
-+#define XTPAGEMAXSLOT 256
-+#define XTENTRYSTART 2
-+
-+/*
-+ * xtree page:
-+ */
-+typedef union {
-+ struct xtheader {
-+ s64 next; /* 8: */
-+ s64 prev; /* 8: */
-+
-+ u8 flag; /* 1: */
-+ u8 rsrvd1; /* 1: */
-+ s16 nextindex; /* 2: next index = number of entries */
-+ s16 maxentry; /* 2: max number of entries */
-+ s16 rsrvd2; /* 2: */
-+
-+ pxd_t self; /* 8: self */
-+ } header; /* (32) */
-+
-+ xad_t xad[XTPAGEMAXSLOT]; /* 16 * maxentry: xad array */
-+} xtpage_t;
-+
-+/* from jfs_dinode.h */
-+
-+struct dinode {
-+ /*
-+ * I. base area (128 bytes)
-+ * ------------------------
-+ *
-+ * define generic/POSIX attributes
-+ */
-+ u32 di_inostamp; /* 4: stamp to show inode belongs to fileset */
-+ s32 di_fileset; /* 4: fileset number */
-+ u32 di_number; /* 4: inode number, aka file serial number */
-+ u32 di_gen; /* 4: inode generation number */
-+
-+ pxd_t di_ixpxd; /* 8: inode extent descriptor */
-+
-+ s64 di_size; /* 8: size */
-+ s64 di_nblocks; /* 8: number of blocks allocated */
-+
-+ u32 di_nlink; /* 4: number of links to the object */
-+
-+ u32 di_uid; /* 4: user id of owner */
-+ u32 di_gid; /* 4: group id of owner */
-+
-+ u32 di_mode; /* 4: attribute, format and permission */
-+
-+ struct timestruc_t di_atime; /* 8: time last data accessed */
-+ struct timestruc_t di_ctime; /* 8: time last status changed */
-+ struct timestruc_t di_mtime; /* 8: time last data modified */
-+ struct timestruc_t di_otime; /* 8: time created */
-+
-+ dxd_t di_acl; /* 16: acl descriptor */
-+
-+ dxd_t di_ea; /* 16: ea descriptor */
-+
-+ s32 di_next_index; /* 4: Next available dir_table index */
-+
-+ s32 di_acltype; /* 4: Type of ACL */
-+
-+ /*
-+ * Extension Areas.
-+ *
-+ * Historically, the inode was partitioned into 4 128-byte areas,
-+ * the last 3 being defined as unions which could have multiple
-+ * uses. The first 96 bytes had been completely unused until
-+ * an index table was added to the directory. It is now more
-+ * useful to describe the last 3/4 of the inode as a single
-+ * union. We would probably be better off redesigning the
-+ * entire structure from scratch, but we don't want to break
-+ * commonality with OS/2's JFS at this time.
-+ */
-+ union {
-+ struct {
-+ /*
-+ * This table contains the information needed to
-+ * find a directory entry from a 32-bit index.
-+ * If the index is small enough, the table is inline,
-+ * otherwise, an x-tree root overlays this table
-+ */
-+ dir_table_slot_t _table[12]; /* 96: inline */
-+
-+ dtroot_t _dtroot; /* 288: dtree root */
-+ } _dir; /* (384) */
-+#define di_dirtable u._dir._table
-+#define di_dtroot u._dir._dtroot
-+#define di_parent di_dtroot.header.idotdot
-+#define di_DASD di_dtroot.header.DASD
-+
-+ struct {
-+ union {
-+ u8 _data[96]; /* 96: unused */
-+ struct {
-+ void *_imap; /* 4: unused */
-+ u32 _gengen; /* 4: generator */
-+ } _imap;
-+ } _u1; /* 96: */
-+#define di_gengen u._file._u1._imap._gengen
-+
-+ union {
-+ xtpage_t _xtroot;
-+ struct {
-+ u8 unused[16]; /* 16: */
-+ dxd_t _dxd; /* 16: */
-+ union {
-+ u32 _rdev; /* 4: */
-+ u8 _fastsymlink[128];
-+ } _u;
-+ u8 _inlineea[128];
-+ } _special;
-+ } _u2;
-+ } _file;
-+#define di_xtroot u._file._u2._xtroot
-+#define di_dxd u._file._u2._special._dxd
-+#define di_btroot di_xtroot
-+#define di_inlinedata u._file._u2._special._u
-+#define di_rdev u._file._u2._special._u._rdev
-+#define di_fastsymlink u._file._u2._special._u._fastsymlink
-+#define di_inlineea u._file._u2._special._inlineea
-+ } u;
-+};
-+
-+typedef struct dinode dinode_t;
-+
-+/* di_mode */
-+#define IFMT 0xF000 /* S_IFMT - mask of file type */
-+#define IFDIR 0x4000 /* S_IFDIR - directory */
-+#define IFREG 0x8000 /* S_IFREG - regular file */
-+#define IFLNK 0xA000 /* S_IFLNK - symbolic link */
-+
-+/* extended mode bits (on-disk inode di_mode) */
-+#define INLINEEA 0x00040000 /* inline EA area free */
-+
-+/* from jfs_imap.h */
-+
-+#define EXTSPERIAG 128 /* number of disk inode extent per iag */
-+#define SMAPSZ 4 /* number of words per summary map */
-+#define MAXAG 128 /* maximum number of allocation groups */
-+
-+/*
-+ * inode allocation map:
-+ *
-+ * inode allocation map consists of
-+ * . the inode map control page and
-+ * . inode allocation group pages (per 4096 inodes)
-+ * which are addressed by standard JFS xtree.
-+ */
-+/*
-+ * inode allocation group page (per 4096 inodes of an AG)
-+ */
-+typedef struct {
-+ s64 agstart; /* 8: starting block of ag */
-+ s32 iagnum; /* 4: inode allocation group number */
-+ s32 inofreefwd; /* 4: ag inode free list forward */
-+ s32 inofreeback; /* 4: ag inode free list back */
-+ s32 extfreefwd; /* 4: ag inode extent free list forward */
-+ s32 extfreeback; /* 4: ag inode extent free list back */
-+ s32 iagfree; /* 4: iag free list */
-+
-+ /* summary map: 1 bit per inode extent */
-+ s32 inosmap[SMAPSZ]; /* 16: sum map of mapwords w/ free inodes;
-+ * note: this indicates free and backed
-+ * inodes, if the extent is not backed the
-+ * value will be 1. if the extent is
-+ * backed but all inodes are being used the
-+ * value will be 1. if the extent is
-+ * backed but at least one of the inodes is
-+ * free the value will be 0.
-+ */
-+ s32 extsmap[SMAPSZ]; /* 16: sum map of mapwords w/ free extents */
-+ s32 nfreeinos; /* 4: number of free inodes */
-+ s32 nfreeexts; /* 4: number of free extents */
-+ /* (72) */
-+ u8 pad[1976]; /* 1976: pad to 2048 bytes */
-+ /* allocation bit map: 1 bit per inode (0 - free, 1 - allocated) */
-+ u32 wmap[EXTSPERIAG]; /* 512: working allocation map */
-+ u32 pmap[EXTSPERIAG]; /* 512: persistent allocation map */
-+ pxd_t inoext[EXTSPERIAG]; /* 1024: inode extent addresses */
-+} iag_t; /* (4096) */
-+
-+#endif /* _JFS_H_ */
-diff -urN --exclude-from=xlist-core grub-0.90/stage2/shared.h grub-0.90.jfs+xfs/stage2/shared.h
---- grub-0.90/stage2/shared.h Fri Jun 22 06:32:56 2001
-+++ grub-0.90.jfs+xfs/stage2/shared.h Thu Aug 23 17:49:01 2001
-@@ -206,7 +206,9 @@
- #define STAGE2_ID_FAT_STAGE1_5 3
- #define STAGE2_ID_MINIX_STAGE1_5 4
- #define STAGE2_ID_REISERFS_STAGE1_5 5
--#define STAGE2_ID_VSTAFS_STAGE1_5 6
-+#define STAGE2_ID_JFS_STAGE1_5 6
-+#define STAGE2_ID_XFS_STAGE1_5 7
-+#define STAGE2_ID_VSTAFS_STAGE1_5 8
-
- #ifndef STAGE1_5
- # define STAGE2_ID STAGE2_ID_STAGE2
-@@ -221,6 +223,10 @@
- # define STAGE2_ID STAGE2_ID_MINIX_STAGE1_5
- # elif defined(FSYS_REISERFS)
- # define STAGE2_ID STAGE2_ID_REISERFS_STAGE1_5
-+# elif defined(FSYS_JFS)
-+# define STAGE2_ID STAGE2_ID_JFS_STAGE1_5
-+# elif defined(FSYS_XFS)
-+# define STAGE2_ID STAGE2_ID_XFS_STAGE1_5
- # elif defined(FSYS_VSTAFS)
- # define STAGE2_ID STAGE2_ID_VSTAFS_STAGE1_5
- # else
-diff -urN --exclude-from=xlist-core grub-0.90/stage2/xfs.h grub-0.90.jfs+xfs/stage2/xfs.h
---- grub-0.90/stage2/xfs.h Thu Jan 1 03:00:00 1970
-+++ grub-0.90.jfs+xfs/stage2/xfs.h Wed Aug 29 02:00:47 2001
-@@ -0,0 +1,545 @@
-+/*
-+ * xfs.h - an extraction from xfsprogs-1.3.5/include/xfs* into one file
-+ *
-+ * Copyright (c) 2000 Silicon Graphics, Inc. All Rights Reserved.
-+ *
-+ * This program is free software; you can redistribute it and/or modify it
-+ * under the terms of version 2 of the GNU General Public License as
-+ * published by the Free Software Foundation.
-+ *
-+ * This program is distributed in the hope that it would be useful, but
-+ * WITHOUT ANY WARRANTY; without even the implied warranty of
-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-+ *
-+ * Further, this software is distributed without any warranty that it is
-+ * free of the rightful claim of any third person regarding infringement
-+ * or the like. Any license provided herein, whether implied or
-+ * otherwise, applies only to this software file. Patent licenses, if
-+ * any, provided herein do not apply to combinations of this program with
-+ * other software, or any other product whatsoever.
-+ *
-+ * You should have received a copy of the GNU General Public License along
-+ * with this program; if not, write the Free Software Foundation, Inc., 59
-+ * Temple Place - Suite 330, Boston MA 02111-1307, USA.
-+ *
-+ * Contact information: Silicon Graphics, Inc., 1600 Amphitheatre Pkwy,
-+ * Mountain View, CA 94043, or:
-+ *
-+ * http://www.sgi.com
-+ *
-+ * For further information regarding this notice, see:
-+ *
-+ * http://oss.sgi.com/projects/GenInfo/SGIGPLNoticeExplan/
-+ */
-+
-+#ifndef _BITS_TYPES_H
-+typedef signed char __int8_t;
-+typedef unsigned char __uint8_t;
-+typedef short __int16_t;
-+typedef unsigned short __uint16_t;
-+typedef int __int32_t;
-+typedef unsigned int __uint32_t;
-+typedef long long __int64_t;
-+typedef unsigned long long __uint64_t;
-+#endif
-+
-+typedef __uint64_t xfs_ino_t;
-+typedef __uint32_t xfs_agino_t;
-+typedef __int64_t xfs_daddr_t;
-+typedef __int64_t xfs_off_t;
-+typedef __uint8_t uuid_t[16];
-+
-+
-+/* those are from xfs_types.h */
-+
-+typedef __uint32_t xfs_agblock_t; /* blockno in alloc. group */
-+typedef __uint32_t xfs_extlen_t; /* extent length in blocks */
-+typedef __uint32_t xfs_agnumber_t; /* allocation group number */
-+typedef __int32_t xfs_extnum_t; /* # of extents in a file */
-+typedef __int16_t xfs_aextnum_t; /* # extents in an attribute fork */
-+typedef __int64_t xfs_fsize_t; /* bytes in a file */
-+
-+typedef __uint32_t xfs_dablk_t; /* dir/attr block number (in file) */
-+typedef __uint32_t xfs_dahash_t; /* dir/attr hash value */
-+
-+/*
-+ * Disk based types:
-+ */
-+typedef __uint64_t xfs_dfsbno_t; /* blockno in filesystem (agno|agbno) */
-+typedef __uint64_t xfs_drfsbno_t; /* blockno in filesystem (raw) */
-+typedef __uint64_t xfs_drtbno_t; /* extent (block) in realtime area */
-+typedef __uint64_t xfs_dfiloff_t; /* block number in a file */
-+
-+typedef __uint64_t xfs_fsblock_t; /* blockno in filesystem (agno|agbno) */
-+typedef __uint64_t xfs_fileoff_t; /* block number in a file */
-+typedef __uint64_t xfs_filblks_t; /* number of blocks in a file */
-+
-+
-+/* those are from xfs_sb.h */
-+
-+#define XFS_SB_MAGIC 0x58465342 /* 'XFSB'*/
-+#define XFS_SB_VERSION_4 4 /* 6.2+ - bitmask version */
-+#define XFS_SB_VERSION_NUMBITS 0x000f
-+
-+typedef struct xfs_sb
-+{
-+ __uint32_t sb_magicnum; /* magic number == XFS_SB_MAGIC */
-+ __uint32_t sb_blocksize; /* logical block size, bytes */
-+ xfs_drfsbno_t sb_dblocks; /* number of data blocks */
-+ xfs_drfsbno_t sb_rblocks; /* number of realtime blocks */
-+ xfs_drtbno_t sb_rextents; /* number of realtime extents */
-+ uuid_t sb_uuid; /* file system unique id */
-+ xfs_dfsbno_t sb_logstart; /* starting block of log if internal */
-+ xfs_ino_t sb_rootino; /* root inode number */
-+ xfs_ino_t sb_rbmino; /* bitmap inode for realtime extents */
-+ xfs_ino_t sb_rsumino; /* summary inode for rt bitmap */
-+ xfs_agblock_t sb_rextsize; /* realtime extent size, blocks */
-+ xfs_agblock_t sb_agblocks; /* size of an allocation group */
-+ xfs_agnumber_t sb_agcount; /* number of allocation groups */
-+ xfs_extlen_t sb_rbmblocks; /* number of rt bitmap blocks */
-+ xfs_extlen_t sb_logblocks; /* number of log blocks */
-+ __uint16_t sb_versionnum; /* header version == XFS_SB_VERSION */
-+ __uint16_t sb_sectsize; /* volume sector size, bytes */
-+ __uint16_t sb_inodesize; /* inode size, bytes */
-+ __uint16_t sb_inopblock; /* inodes per block */
-+ char sb_fname[12]; /* file system name */
-+ __uint8_t sb_blocklog; /* log2 of sb_blocksize */
-+ __uint8_t sb_sectlog; /* log2 of sb_sectsize */
-+ __uint8_t sb_inodelog; /* log2 of sb_inodesize */
-+ __uint8_t sb_inopblog; /* log2 of sb_inopblock */
-+ __uint8_t sb_agblklog; /* log2 of sb_agblocks (rounded up) */
-+ __uint8_t sb_rextslog; /* log2 of sb_rextents */
-+ __uint8_t sb_inprogress; /* mkfs is in progress, don't mount */
-+ __uint8_t sb_imax_pct; /* max % of fs for inode space */
-+ /* statistics */
-+ /*
-+ * These fields must remain contiguous. If you really
-+ * want to change their layout, make sure you fix the
-+ * code in xfs_trans_apply_sb_deltas().
-+ */
-+ __uint64_t sb_icount; /* allocated inodes */
-+ __uint64_t sb_ifree; /* free inodes */
-+ __uint64_t sb_fdblocks; /* free data blocks */
-+ __uint64_t sb_frextents; /* free realtime extents */
-+ /*
-+ * End contiguous fields.
-+ */
-+ xfs_ino_t sb_uquotino; /* user quota inode */
-+ xfs_ino_t sb_gquotino; /* group quota inode */
-+ __uint16_t sb_qflags; /* quota flags */
-+ __uint8_t sb_flags; /* misc. flags */
-+ __uint8_t sb_shared_vn; /* shared version number */
-+ xfs_extlen_t sb_inoalignmt; /* inode chunk alignment, fsblocks */
-+ __uint32_t sb_unit; /* stripe or raid unit */
-+ __uint32_t sb_width; /* stripe or raid width */
-+ __uint8_t sb_dirblklog; /* log2 of dir block size (fsbs) */
-+ __uint8_t sb_dummy[7]; /* padding */
-+} xfs_sb_t;
-+
-+
-+/* those are from xfs_btree.h */
-+
-+/*
-+ * Long form header: bmap btrees.
-+ */
-+typedef struct xfs_btree_lblock
-+{
-+ __uint32_t bb_magic; /* magic number for block type */
-+ __uint16_t bb_level; /* 0 is a leaf */
-+ __uint16_t bb_numrecs; /* current # of data records */
-+ xfs_dfsbno_t bb_leftsib; /* left sibling block or NULLDFSBNO */
-+ xfs_dfsbno_t bb_rightsib; /* right sibling block or NULLDFSBNO */
-+} xfs_btree_lblock_t;
-+
-+/*
-+ * Combined header and structure, used by common code.
-+ */
-+typedef struct xfs_btree_hdr
-+{
-+ __uint32_t bb_magic; /* magic number for block type */
-+ __uint16_t bb_level; /* 0 is a leaf */
-+ __uint16_t bb_numrecs; /* current # of data records */
-+} xfs_btree_hdr_t;
-+
-+typedef struct xfs_btree_block
-+{
-+ xfs_btree_hdr_t bb_h; /* header */
-+ union {
-+ struct {
-+ xfs_agblock_t bb_leftsib;
-+ xfs_agblock_t bb_rightsib;
-+ } s; /* short form pointers */
-+ struct {
-+ xfs_dfsbno_t bb_leftsib;
-+ xfs_dfsbno_t bb_rightsib;
-+ } l; /* long form pointers */
-+ } bb_u; /* rest */
-+} xfs_btree_block_t;
-+
-+/* those are from xfs_bmap_btree.h */
-+
-+/*
-+ * Bmap root header, on-disk form only.
-+ */
-+typedef struct xfs_bmdr_block
-+{
-+ __uint16_t bb_level; /* 0 is a leaf */
-+ __uint16_t bb_numrecs; /* current # of data records */
-+} xfs_bmdr_block_t;
-+
-+/*
-+ * Bmap btree record and extent descriptor.
-+ * For 32-bit kernels,
-+ * l0:31 is an extent flag (value 1 indicates non-normal).
-+ * l0:0-30 and l1:9-31 are startoff.
-+ * l1:0-8, l2:0-31, and l3:21-31 are startblock.
-+ * l3:0-20 are blockcount.
-+ * For 64-bit kernels,
-+ * l0:63 is an extent flag (value 1 indicates non-normal).
-+ * l0:9-62 are startoff.
-+ * l0:0-8 and l1:21-63 are startblock.
-+ * l1:0-20 are blockcount.
-+ */
-+
-+#define BMBT_USE_64 1
-+
-+typedef struct xfs_bmbt_rec_32
-+{
-+ __uint32_t l0, l1, l2, l3;
-+} xfs_bmbt_rec_32_t;
-+typedef struct xfs_bmbt_rec_64
-+{
-+ __uint64_t l0, l1;
-+} xfs_bmbt_rec_64_t;
-+
-+#if BMBT_USE_64
-+typedef __uint64_t xfs_bmbt_rec_base_t; /* use this for casts */
-+typedef xfs_bmbt_rec_64_t xfs_bmbt_rec_t, xfs_bmdr_rec_t;
-+#else /* !BMBT_USE_64 */
-+typedef __uint32_t xfs_bmbt_rec_base_t; /* use this for casts */
-+typedef xfs_bmbt_rec_32_t xfs_bmbt_rec_t, xfs_bmdr_rec_t;
-+#endif /* BMBT_USE_64 */
-+
-+/*
-+ * Key structure for non-leaf levels of the tree.
-+ */
-+typedef struct xfs_bmbt_key
-+{
-+ xfs_dfiloff_t br_startoff; /* starting file offset */
-+} xfs_bmbt_key_t, xfs_bmdr_key_t;
-+
-+typedef xfs_dfsbno_t xfs_bmbt_ptr_t, xfs_bmdr_ptr_t; /* btree pointer type */
-+ /* btree block header type */
-+typedef struct xfs_btree_lblock xfs_bmbt_block_t;
-+
-+
-+/* those are from xfs_dir2.h */
-+/*
-+ * Directory version 2.
-+ * There are 4 possible formats:
-+ * shortform
-+ * single block - data with embedded leaf at the end
-+ * multiple data blocks, single leaf+freeindex block
-+ * data blocks, node&leaf blocks (btree), freeindex blocks
-+ *
-+ * The shortform format is in xfs_dir2_sf.h.
-+ * The single block format is in xfs_dir2_block.h.
-+ * The data block format is in xfs_dir2_data.h.
-+ * The leaf and freeindex block formats are in xfs_dir2_leaf.h.
-+ * Node blocks are the same as the other version, in xfs_da_btree.h.
-+ */
-+
-+/*
-+ * Byte offset in data block and shortform entry.
-+ */
-+typedef __uint16_t xfs_dir2_data_off_t;
-+
-+/*
-+ * Byte offset in a directory.
-+ */
-+typedef xfs_off_t xfs_dir2_off_t;
-+
-+/* those are from xfs_da_btree.h */
-+/*========================================================================
-+ * Directory Structure when greater than XFS_LBSIZE(mp) bytes.
-+ *========================================================================*/
-+
-+/*
-+ * This structure is common to both leaf nodes and non-leaf nodes in the Btree.
-+ *
-+ * Is is used to manage a doubly linked list of all blocks at the same
-+ * level in the Btree, and to identify which type of block this is.
-+ */
-+#define XFS_DIR2_LEAF1_MAGIC 0xd2f1 /* magic number: v2 dirlf single blks */
-+#define XFS_DIR2_LEAFN_MAGIC 0xd2ff /* magic number: v2 dirlf multi blks */
-+
-+typedef struct xfs_da_blkinfo {
-+ xfs_dablk_t forw; /* previous block in list */
-+ xfs_dablk_t back; /* following block in list */
-+ __uint16_t magic; /* validity check on block */
-+ __uint16_t pad; /* unused */
-+} xfs_da_blkinfo_t;
-+
-+/*
-+ * This is the structure of the root and intermediate nodes in the Btree.
-+ * The leaf nodes are defined above.
-+ *
-+ * Entries are not packed.
-+ *
-+ * Since we have duplicate keys, use a binary search but always follow
-+ * all match in the block, not just the first match found.
-+ */
-+
-+typedef struct xfs_da_intnode {
-+ struct xfs_da_node_hdr { /* constant-structure header block */
-+ xfs_da_blkinfo_t info; /* block type, links, etc. */
-+ __uint16_t count; /* count of active entries */
-+ __uint16_t level; /* level above leaves (leaf == 0) */
-+ } hdr;
-+ struct xfs_da_node_entry {
-+ xfs_dahash_t hashval; /* hash value for this descendant */
-+ xfs_dablk_t before; /* Btree block before this key */
-+ } btree[1]; /* variable sized array of keys */
-+} xfs_da_intnode_t;
-+
-+
-+/* those are from xfs_dir2_data.h */
-+/*
-+ * Directory format 2, data block structures.
-+ */
-+
-+/*
-+ * Constants.
-+ */
-+#define XFS_DIR2_DATA_FREE_TAG 0xffff
-+#define XFS_DIR2_DATA_FD_COUNT 3
-+
-+/*
-+ * Structures.
-+ */
-+
-+/*
-+ * Describe a free area in the data block.
-+ * The freespace will be formatted as a xfs_dir2_data_unused_t.
-+ */
-+typedef struct xfs_dir2_data_free {
-+ xfs_dir2_data_off_t offset; /* start of freespace */
-+ xfs_dir2_data_off_t length; /* length of freespace */
-+} xfs_dir2_data_free_t;
-+
-+/*
-+ * Header for the data blocks.
-+ * Always at the beginning of a directory-sized block.
-+ * The code knows that XFS_DIR2_DATA_FD_COUNT is 3.
-+ */
-+typedef struct xfs_dir2_data_hdr {
-+ __uint32_t magic; /* XFS_DIR2_DATA_MAGIC */
-+ /* or XFS_DIR2_BLOCK_MAGIC */
-+ xfs_dir2_data_free_t bestfree[XFS_DIR2_DATA_FD_COUNT];
-+} xfs_dir2_data_hdr_t;
-+
-+/*
-+ * Active entry in a data block. Aligned to 8 bytes.
-+ * Tag appears as the last 2 bytes.
-+ */
-+typedef struct xfs_dir2_data_entry {
-+ xfs_ino_t inumber; /* inode number */
-+ __uint8_t namelen; /* name length */
-+ __uint8_t name[1]; /* name bytes, no null */
-+ /* variable offset */
-+ xfs_dir2_data_off_t tag; /* starting offset of us */
-+} xfs_dir2_data_entry_t;
-+
-+/*
-+ * Unused entry in a data block. Aligned to 8 bytes.
-+ * Tag appears as the last 2 bytes.
-+ */
-+typedef struct xfs_dir2_data_unused {
-+ __uint16_t freetag; /* XFS_DIR2_DATA_FREE_TAG */
-+ xfs_dir2_data_off_t length; /* total free length */
-+ /* variable offset */
-+ xfs_dir2_data_off_t tag; /* starting offset of us */
-+} xfs_dir2_data_unused_t;
-+
-+typedef union {
-+ xfs_dir2_data_entry_t entry;
-+ xfs_dir2_data_unused_t unused;
-+} xfs_dir2_data_union_t;
-+
-+
-+/* those are from xfs_dir2_leaf.h */
-+/*
-+ * Directory version 2, leaf block structures.
-+ */
-+
-+/*
-+ * Leaf block header.
-+ */
-+typedef struct xfs_dir2_leaf_hdr {
-+ xfs_da_blkinfo_t info; /* header for da routines */
-+ __uint16_t count; /* count of entries */
-+ __uint16_t stale; /* count of stale entries */
-+} xfs_dir2_leaf_hdr_t;
-+
-+
-+/* those are from xfs_dir2_block.h */
-+/*
-+ * xfs_dir2_block.h
-+ * Directory version 2, single block format structures
-+ */
-+
-+/*
-+ * The single block format is as follows:
-+ * xfs_dir2_data_hdr_t structure
-+ * xfs_dir2_data_entry_t and xfs_dir2_data_unused_t structures
-+ * xfs_dir2_leaf_entry_t structures
-+ * xfs_dir2_block_tail_t structure
-+ */
-+
-+#define XFS_DIR2_BLOCK_MAGIC 0x58443242 /* XD2B: for one block dirs */
-+
-+typedef struct xfs_dir2_block_tail {
-+ __uint32_t count; /* count of leaf entries */
-+ __uint32_t stale; /* count of stale lf entries */
-+} xfs_dir2_block_tail_t;
-+
-+
-+/* those are from xfs_dir2_sf.h */
-+
-+/*
-+ * Directory layout when stored internal to an inode.
-+ *
-+ * Small directories are packed as tightly as possible so as to
-+ * fit into the literal area of the inode.
-+ */
-+
-+/*
-+ * Inode number stored as 8 8-bit values.
-+ */
-+typedef struct { __uint8_t i[8]; } xfs_dir2_ino8_t;
-+
-+/*
-+ * Inode number stored as 4 8-bit values.
-+ * Works a lot of the time, when all the inode numbers in a directory
-+ * fit in 32 bits.
-+ */
-+typedef struct { __uint8_t i[4]; } xfs_dir2_ino4_t;
-+
-+typedef union {
-+ xfs_dir2_ino8_t i8;
-+ xfs_dir2_ino4_t i4;
-+} xfs_dir2_inou_t;
-+
-+/*
-+ * Normalized offset (in a data block) of the entry, really xfs_dir2_data_off_t.
-+ * Only need 16 bits, this is the byte offset into the single block form.
-+ */
-+typedef struct { __uint8_t i[2]; } xfs_dir2_sf_off_t;
-+
-+/*
-+ * The parent directory has a dedicated field, and the self-pointer must
-+ * be calculated on the fly.
-+ *
-+ * Entries are packed toward the top as tightly as possible. The header
-+ * and the elements must be bcopy()'d out into a work area to get correct
-+ * alignment for the inode number fields.
-+ */
-+typedef struct xfs_dir2_sf_hdr {
-+ __uint8_t count; /* count of entries */
-+ __uint8_t i8count; /* count of 8-byte inode #s */
-+ xfs_dir2_inou_t parent; /* parent dir inode number */
-+} xfs_dir2_sf_hdr_t;
-+
-+typedef struct xfs_dir2_sf_entry {
-+ __uint8_t namelen; /* actual name length */
-+ xfs_dir2_sf_off_t offset; /* saved offset */
-+ __uint8_t name[1]; /* name, variable size */
-+ xfs_dir2_inou_t inumber; /* inode number, var. offset */
-+} xfs_dir2_sf_entry_t;
-+
-+typedef struct xfs_dir2_sf {
-+ xfs_dir2_sf_hdr_t hdr; /* shortform header */
-+ xfs_dir2_sf_entry_t list[1]; /* shortform entries */
-+} xfs_dir2_sf_t;
-+
-+/* those are from xfs_dinode.h */
-+
-+#define XFS_DINODE_VERSION_1 1
-+#define XFS_DINODE_VERSION_2 2
-+#define XFS_DINODE_MAGIC 0x494e /* 'IN' */
-+
-+/*
-+ * Disk inode structure.
-+ * This is just the header; the inode is expanded to fill a variable size
-+ * with the last field expanding. It is split into the core and "other"
-+ * because we only need the core part in the in-core inode.
-+ */
-+typedef struct xfs_timestamp {
-+ __int32_t t_sec; /* timestamp seconds */
-+ __int32_t t_nsec; /* timestamp nanoseconds */
-+} xfs_timestamp_t;
-+
-+/*
-+ * Note: Coordinate changes to this structure with the XFS_DI_* #defines
-+ * below and the offsets table in xfs_ialloc_log_di().
-+ */
-+typedef struct xfs_dinode_core
-+{
-+ __uint16_t di_magic; /* inode magic # = XFS_DINODE_MAGIC */
-+ __uint16_t di_mode; /* mode and type of file */
-+ __int8_t di_version; /* inode version */
-+ __int8_t di_format; /* format of di_c data */
-+ __uint16_t di_onlink; /* old number of links to file */
-+ __uint32_t di_uid; /* owner's user id */
-+ __uint32_t di_gid; /* owner's group id */
-+ __uint32_t di_nlink; /* number of links to file */
-+ __uint16_t di_projid; /* owner's project id */
-+ __uint8_t di_pad[10]; /* unused, zeroed space */
-+ xfs_timestamp_t di_atime; /* time last accessed */
-+ xfs_timestamp_t di_mtime; /* time last modified */
-+ xfs_timestamp_t di_ctime; /* time created/inode modified */
-+ xfs_fsize_t di_size; /* number of bytes in file */
-+ xfs_drfsbno_t di_nblocks; /* # of direct & btree blocks used */
-+ xfs_extlen_t di_extsize; /* basic/minimum extent size for file */
-+ xfs_extnum_t di_nextents; /* number of extents in data fork */
-+ xfs_aextnum_t di_anextents; /* number of extents in attribute fork*/
-+ __uint8_t di_forkoff; /* attr fork offs, <<3 for 64b align */
-+ __int8_t di_aformat; /* format of attr fork's data */
-+ __uint32_t di_dmevmask; /* DMIG event mask */
-+ __uint16_t di_dmstate; /* DMIG state info */
-+ __uint16_t di_flags; /* random flags, XFS_DIFLAG_... */
-+ __uint32_t di_gen; /* generation number */
-+} xfs_dinode_core_t;
-+
-+typedef struct xfs_dinode
-+{
-+ xfs_dinode_core_t di_core;
-+ xfs_agino_t di_next_unlinked;/* agi unlinked list ptr */
-+ union {
-+ xfs_bmdr_block_t di_bmbt; /* btree root block */
-+ xfs_bmbt_rec_32_t di_bmx[1]; /* extent list */
-+ xfs_dir2_sf_t di_dir2sf; /* shortform directory v2 */
-+ char di_c[1]; /* local contents */
-+ } di_u;
-+} xfs_dinode_t;
-+
-+/*
-+ * Values for di_format
-+ */
-+typedef enum xfs_dinode_fmt
-+{
-+ XFS_DINODE_FMT_DEV, /* CHR, BLK: di_dev */
-+ XFS_DINODE_FMT_LOCAL, /* DIR, REG: di_c */
-+ /* LNK: di_symlink */
-+ XFS_DINODE_FMT_EXTENTS, /* DIR, REG, LNK: di_bmx */
-+ XFS_DINODE_FMT_BTREE, /* DIR, REG, LNK: di_bmbt */
-+ XFS_DINODE_FMT_UUID /* MNT: di_uuid */
-+} xfs_dinode_fmt_t;
-+
-+/*
-+ * File types (mode field)
-+ */
-+#define IFMT 0170000 /* type of file */
-+#define IFDIR 0040000 /* directory */
-+#define IFREG 0100000 /* regular */
-+#define IFLNK 0120000 /* symbolic link */
diff --git a/sys-apps/grub/files/grub-0.91/grub-0.5.96.1-dont-give-mem-to-kernel.patch b/sys-apps/grub/files/grub-0.91/grub-0.5.96.1-dont-give-mem-to-kernel.patch
deleted file mode 100644
index dd3a60d12835..000000000000
--- a/sys-apps/grub/files/grub-0.91/grub-0.5.96.1-dont-give-mem-to-kernel.patch
+++ /dev/null
@@ -1,30 +0,0 @@
---- grub-0.5.96.1/stage2/boot.c.pix Mon Oct 16 16:42:08 2000
-+++ grub-0.5.96.1/stage2/boot.c Fri Feb 23 16:40:29 2001
-@@ -322,7 +322,18 @@
-
- while (((int) dest) < CL_MY_END_ADDR && *src)
- *(dest++) = *(src++);
--
-+
-+/* don't add ``mem='' for 2.4 kernels :
-+
-+Newer machines have several regions of reserved memory outside and
-+inside these regions. grub's actions are suicide on newer laptops,
-+and machines like servers with lots of memory. Laptops have special
-+sections of memory above 1MB which must be reserved... Ditto for
-+ACPI tables. Using mem=XXX completely eliminates any information
-+that the BIOS has provided to the OS.
-+
-+*/
-+#if 0
- /* Add a mem option automatically only if the user doesn't
- specify it explicitly. */
- if (! grub_strstr (arg, "mem=")
-@@ -337,6 +348,7 @@
- dest = convert_to_ascii (dest, 'u', (extended_memory + 0x400));
- *(dest++) = 'K';
- }
-+#endif
-
- *dest = 0;
- }
diff --git a/sys-apps/grub/files/grub-0.91/grub-0.5.96.1-special-raid-devices.patch b/sys-apps/grub/files/grub-0.91/grub-0.5.96.1-special-raid-devices.patch
deleted file mode 100644
index 15176e7c19da..000000000000
--- a/sys-apps/grub/files/grub-0.91/grub-0.5.96.1-special-raid-devices.patch
+++ /dev/null
@@ -1,17 +0,0 @@
---- grub-0.5.96.1/lib/device.c.pix Mon Oct 16 16:41:54 2000
-+++ grub-0.5.96.1/lib/device.c Tue Apr 3 12:01:41 2001
-@@ -616,7 +616,13 @@
- if (strcmp (dev + strlen(dev) - 5, "/disc") == 0)
- strcat (dev + strlen(dev) - 5, "/part");
- }
-- sprintf (dev + strlen(dev), "%d", ((partition >> 16) & 0xFF) + 1);
-+
-+ sprintf (dev + strlen(dev), "%s%d",
-+ /* Compaq smart and others */
-+ (strncmp(dev, "/dev/ida/", 9) == 0 ||
-+ strncmp(dev, "/dev/cciss/", 11) == 0 ||
-+ strncmp(dev, "/dev/rd/", 8) == 0) ? "p" : "",
-+ ((partition >> 16) & 0xFF) + 1);
-
- /* Open the partition. */
- fd = open (dev, O_RDWR);
diff --git a/sys-apps/grub/files/grub-0.91/grub-0.90-addsyncs.patch b/sys-apps/grub/files/grub-0.91/grub-0.90-addsyncs.patch
deleted file mode 100644
index 4c53344a3cbe..000000000000
--- a/sys-apps/grub/files/grub-0.91/grub-0.90-addsyncs.patch
+++ /dev/null
@@ -1,57 +0,0 @@
-
-I just found another semi-critical bug, whose fix should really get
-into 0.91.
-
-It turns out that "grub-install" doesn't have any "sync" calls to make
-sure any filesystem caches are coherent with the raw devices they are
-on top of... so if your filesystem waits to write out any data from the
-copy command in the script to put the "stage1" and "stage2" in their
-final location, you're hosed.
-
-I found this because it just bit me on one of my systems running stock
-RedHat 7.2 with a large "stage2".
-
-The only script that is patched here is "grub-install". The others
-don't appear to need it as they either unmount things first or don't
-refer to devices.
-
-Hmm. Maybe the right fix is to make the "sync" system call when
-starting the GRUB shell with a device map that refers to any real disks
-or something like that.
-
-------------------------(start patch)-----------------------
---- grub.orig/util/grub-install.in Mon Oct 22 16:46:07 2001
-+++ grub/util/grub-install.in Sat Oct 27 13:06:33 2001
-@@ -244,6 +244,10 @@
- # Create a safe temporary file.
- test -x /bin/tempfile && log_file=`tempfile --prefix=grub`
-
-+ # Before all invocations of the grub shell, call sync to make sure
-+ # the raw device is in sync with any bufferring in filesystems.
-+ sync
-+
- $grub_shell --batch --device-map=$device_map <<EOF >$log_file
- quit
- EOF
-@@ -318,6 +322,10 @@
- # Create a safe temporary file.
- test -x /bin/tempfile && log_file=`tempfile --prefix=grub`
-
-+# Before all invocations of the grub shell, call sync to make sure
-+# the raw device is in sync with any bufferring in filesystems.
-+sync
-+
- # Now perform the installation.
- $grub_shell --batch --device-map=$device_map <<EOF >$log_file
- root $root_drive
-------------------------(end patch)-----------------------
-
---
- Erich Stefan Boleyn <erich@uruk.org> http://www.uruk.org/
-"Reality is truly stranger than fiction; Probably why fiction is so popular"
-
-_______________________________________________
-Bug-grub mailing list
-Bug-grub@gnu.org
-http://mail.gnu.org/mailman/listinfo/bug-grub
-
diff --git a/sys-apps/grub/files/grub-0.91/grub-0.90-append.patch b/sys-apps/grub/files/grub-0.91/grub-0.90-append.patch
deleted file mode 100644
index 99cd0285faef..000000000000
--- a/sys-apps/grub/files/grub-0.91/grub-0.90-append.patch
+++ /dev/null
@@ -1,111 +0,0 @@
---- grub-0.90/stage2/stage2.c.append Thu Dec 20 08:20:48 2001
-+++ grub-0.90/stage2/stage2.c Thu Dec 20 17:01:20 2001
-@@ -500,7 +500,8 @@
- if (config_entries)
- printf ("\
- Press enter to boot the selected OS, \'e\' to edit the\n\
-- commands before booting, or \'c\' for a command-line.");
-+ commands before booting, \'a\' to modify the kernel arguments\n\
-+ before booting, or \'c\' for a command-line.");
- else
- printf ("\
- Press \'b\' to boot, \'e\' to edit the selected command in the\n\
-@@ -787,6 +788,98 @@
- enter_cmdline (heap, 0);
- goto restart;
- }
-+ if (config_entries && c == 'a')
-+ {
-+ int new_num_entries = 0, i = 0, j;
-+ int needs_padding, amount;
-+ char *new_heap;
-+ char * entries;
-+ char * entry_copy;
-+ char * append_line;
-+ char * start;
-+
-+ entry_copy = new_heap = heap;
-+ cur_entry = get_entry (config_entries, first_entry + entryno,
-+ 1);
-+
-+ do
-+ {
-+ while ((*(new_heap++) = cur_entry[i++]) != 0);
-+ new_num_entries++;
-+ }
-+ while (config_entries && cur_entry[i]);
-+
-+ /* this only needs to be done if config_entries is non-NULL,
-+ but it doesn't hurt to do it always */
-+ *(new_heap++) = 0;
-+
-+ new_heap = heap + NEW_HEAPSIZE + 1;
-+
-+ entries = entry_copy;
-+ while (*entries)
-+ {
-+ if ((strstr(entries, "kernel") == entries) &&
-+ isspace(entries[6]))
-+ break;
-+
-+ while (*entries) entries++;
-+ entries++;
-+ }
-+
-+ if (!*entries)
-+ goto restart;
-+
-+ start = entries + 6;
-+
-+ /* skip the white space */
-+ while (*start && isspace(*start)) start++;
-+ /* skip the kernel name */
-+ while (*start && !isspace(*start)) start++;
-+
-+ /* skip the white space */
-+ needs_padding = (!*start || !isspace(*start));
-+ while (*start && isspace(*start)) start++;
-+
-+ append_line = new_heap;
-+ grub_strcpy(append_line, start);
-+
-+ cls();
-+ print_cmdline_message (0);
-+
-+ if (get_cmdline(PACKAGE " append> ",
-+ append_line, NEW_HEAPSIZE + 1,
-+ 0, 1))
-+ goto restart;
-+
-+ /* have new args; append_line points to the
-+ new args and start points to the old
-+ args */
-+
-+ i = grub_strlen(start);
-+ j = grub_strlen(append_line);
-+
-+ if (i > (j + needs_padding))
-+ amount = i;
-+ else
-+ amount = j + needs_padding;
-+
-+ /* align rest of commands properly */
-+ memmove (start + j + needs_padding, start + i,
-+ ((int) append_line) - ((int) start) - (amount));
-+
-+ if (needs_padding)
-+ *start = ' ';
-+
-+ /* copy command to correct area */
-+ memmove (start + needs_padding, append_line, j);
-+
-+ /* set up this entry to boot */
-+ config_entries = NULL;
-+ cur_entry = entry_copy;
-+ heap = new_heap;
-+
-+ break;
-+ }
- #ifdef GRUB_UTIL
- if (c == 'q')
- {
diff --git a/sys-apps/grub/files/grub-0.91/grub-0.90-install.in.patch b/sys-apps/grub/files/grub-0.91/grub-0.90-install.in.patch
deleted file mode 100644
index c714196a4402..000000000000
--- a/sys-apps/grub/files/grub-0.91/grub-0.90-install.in.patch
+++ /dev/null
@@ -1,34 +0,0 @@
---- grub-0.90/util/grub-install.in~ Wed Feb 28 06:19:39 2001
-+++ grub-0.90/util/grub-install.in Thu Jul 19 16:01:12 2001
-@@ -224,6 +224,15 @@
- test -d "$bootdir" || mkdir "$bootdir" || exit 1
- test -d "$grubdir" || mkdir "$grubdir" || exit 1
-
-+# Copy the GRUB images to the GRUB directory.
-+for file in ${grubdir}/stage1 ${grubdir}/stage2 ${grubdir}/*stage1_5; do
-+ rm -f $file || exit 1
-+done
-+for file in \
-+ ${pkgdatadir}/stage1 ${pkgdatadir}/stage2 ${pkgdatadir}/*stage1_5; do
-+ cp -f $file ${grubdir} || exit 1
-+done
-+
- # If --recheck is specified, remove the device map, if present.
- if test $recheck = yes; then
- rm -f $device_map
-@@ -297,15 +306,6 @@
- EOF
- exit 1
- fi
--
--# Copy the GRUB images to the GRUB directory.
--for file in ${grubdir}/stage1 ${grubdir}/stage2 ${grubdir}/*stage1_5; do
-- rm -f $file || exit 1
--done
--for file in \
-- ${pkgdatadir}/stage1 ${pkgdatadir}/stage2 ${pkgdatadir}/*stage1_5; do
-- cp -f $file ${grubdir} || exit 1
--done
-
- # Create a safe temporary file.
- test -x /bin/tempfile && log_file=`tempfile --prefix=grub`
diff --git a/sys-apps/grub/files/grub-0.91/grub-0.90-installcopyonly.patch b/sys-apps/grub/files/grub-0.91/grub-0.90-installcopyonly.patch
deleted file mode 100644
index 1083ab507e71..000000000000
--- a/sys-apps/grub/files/grub-0.91/grub-0.90-installcopyonly.patch
+++ /dev/null
@@ -1,85 +0,0 @@
---- grub-0.90/util/grub-install.in~ Thu Jul 19 18:42:58 2001
-+++ grub-0.90/util/grub-install.in Thu Jul 19 18:43:12 2001
-@@ -38,6 +38,7 @@
- force_lba=
- recheck=no
- debug=no
-+justcopy=no
-
- # Usage: usage
- # Print the usage.
-@@ -149,6 +150,17 @@
- fi
- }
-
-+copy_images() {
-+ # Copy the GRUB images to the GRUB directory.
-+ for file in ${grubdir}/stage1 ${grubdir}/stage2 ${grubdir}/*stage1_5; do
-+ rm -f $file || exit 1
-+ done
-+ for file in \
-+ ${pkgdatadir}/stage1 ${pkgdatadir}/stage2 ${pkgdatadir}/*stage1_5; do
-+ cp -f $file ${grubdir} || exit 1
-+ done
-+}
-+
- # Check the arguments.
- for option in "$@"; do
- case "$option" in
-@@ -166,6 +178,8 @@
- force_lba="--force-lba" ;;
- --recheck)
- recheck=yes ;;
-+ --just-copy)
-+ justcopy=yes ;;
- # This is an undocumented feature...
- --debug)
- debug=yes ;;
-@@ -179,12 +193,6 @@
- esac
- done
-
--if test "x$install_device" = x; then
-- echo "install_device not specified." 1>&2
-- usage
-- exit 1
--fi
--
- # If the debugging feature is enabled, print commands.
- if test $debug = yes; then
- set -x
-@@ -195,6 +203,18 @@
- grubdir=${bootdir}/grub
- device_map=${grubdir}/device.map
-
-+# if they just want the images copied, copy the images and then exit
-+if test $justcopy = yes; then
-+ copy_images
-+ exit 0
-+fi
-+
-+if test "x$install_device" = x; then
-+ echo "install_device not specified." 1>&2
-+ usage
-+ exit 1
-+fi
-+
- # Check if GRUB is installed
- if test -f "$grub_shell"; then
- :
-@@ -224,14 +244,7 @@
- test -d "$bootdir" || mkdir "$bootdir" || exit 1
- test -d "$grubdir" || mkdir "$grubdir" || exit 1
-
--# Copy the GRUB images to the GRUB directory.
--for file in ${grubdir}/stage1 ${grubdir}/stage2 ${grubdir}/*stage1_5; do
-- rm -f $file || exit 1
--done
--for file in \
-- ${pkgdatadir}/stage1 ${pkgdatadir}/stage2 ${pkgdatadir}/*stage1_5; do
-- cp -f $file ${grubdir} || exit 1
--done
-+copy_images
-
- # If --recheck is specified, remove the device map, if present.
- if test $recheck = yes; then
diff --git a/sys-apps/grub/files/grub-0.91/grub-0.90-passwordprompt.patch b/sys-apps/grub/files/grub-0.91/grub-0.90-passwordprompt.patch
deleted file mode 100644
index 47810a9ca9b9..000000000000
--- a/sys-apps/grub/files/grub-0.91/grub-0.90-passwordprompt.patch
+++ /dev/null
@@ -1,146 +0,0 @@
-diff -ur grub-0.90/stage2/stage2.c grub/stage2/stage2.c
---- grub-0.90/stage2/stage2.c Thu Jul 19 01:58:59 2001
-+++ grub/stage2/stage2.c Thu Jul 19 01:59:11 2001
-@@ -316,6 +316,7 @@
- char *cur_entry = 0;
- int disp_up = DISP_UP;
- int disp_down = DISP_DOWN;
-+ int ask_pass = 0;
-
- /*
- * Main loop for menu UI.
-@@ -423,8 +424,72 @@
- grub_printf ("\n\
- Use the %c and %c keys to select which entry is highlighted.\n",
- disp_up, disp_down);
--
-- if (! auth && password)
-+
-+ if (! auth && password && ask_pass)
-+ {
-+ /* Do password check here! */
-+ char entered[32];
-+ char *pptr = password;
-+
-+ /* we've asked, so don't ask again */
-+ ask_pass = 0;
-+
-+ if (terminal & TERMINAL_DUMB)
-+ grub_printf ("\n\nThe selected entry is %d ", entryno);
-+ else
-+ {
-+ print_entries (view_y0 + 3, 12, first_entry, menu_entries);
-+ /* highlight initial line */
-+ set_line_highlight (view_y0 + 4 + entryno, first_entry + entryno,
-+ menu_entries);
-+ }
-+
-+ /* Wipe out the previously entered password */
-+ memset (entered, 0, sizeof (entered));
-+ gotoxy (view_x0 + 1, view_y0 + 16);
-+ get_cmdline (" Password: ", entered, 31, '*', 0);
-+
-+ while (! isspace (*pptr) && *pptr)
-+ pptr++;
-+
-+ /* Make sure that PASSWORD is NUL-terminated. */
-+ *pptr++ = 0;
-+
-+ if (! check_password (entered, password, password_type))
-+ {
-+ char *new_file = config_file;
-+
-+ while (isspace (*pptr))
-+ pptr++;
-+
-+ /* If *PPTR is NUL, then allow the user to use
-+ privileged instructions, otherwise, load
-+ another configuration file. */
-+ if (*pptr != 0)
-+ {
-+ while ((*(new_file++) = *(pptr++)) != 0)
-+ ;
-+
-+ /* Make sure that the user will not have
-+ authority in the next configuration. */
-+ auth = 0;
-+ return;
-+ }
-+ else
-+ {
-+ /* Now the user is superhuman. */
-+ auth = 1;
-+ goto restart;
-+ }
-+ }
-+ else
-+ {
-+ printf (" Failed!\n Press any key to continue...");
-+ getkey ();
-+ goto restart;
-+ }
-+ }
-+ else if (! auth && password)
- {
- printf ("\
- Press enter to boot the selected OS or \'p\' to enter a\n\
-@@ -637,57 +702,8 @@
- {
- if (c == 'p')
- {
-- /* Do password check here! */
-- char entered[32];
-- char *pptr = password;
--
-- if (terminal & TERMINAL_DUMB)
-- grub_printf ("\r ");
-- else
-- gotoxy (view_x0 + 1, view_y1 + 21);
--
-- /* Wipe out the previously entered password */
-- memset (entered, 0, sizeof (entered));
-- get_cmdline (" Password: ", entered, 31, '*', 0);
--
-- while (! isspace (*pptr) && *pptr)
-- pptr++;
--
-- /* Make sure that PASSWORD is NUL-terminated. */
-- *pptr++ = 0;
--
-- if (! check_password (entered, password, password_type))
-- {
-- char *new_file = config_file;
-- while (isspace (*pptr))
-- pptr++;
--
-- /* If *PPTR is NUL, then allow the user to use
-- privileged instructions, otherwise, load
-- another configuration file. */
-- if (*pptr != 0)
-- {
-- while ((*(new_file++) = *(pptr++)) != 0)
-- ;
--
-- /* Make sure that the user will not have
-- authority in the next configuration. */
-- auth = 0;
-- return;
-- }
-- else
-- {
-- /* Now the user is superhuman. */
-- auth = 1;
-- goto restart;
-- }
-- }
-- else
-- {
-- printf ("Failed!\n Press any key to continue...");
-- getkey ();
-- goto restart;
-- }
-+ ask_pass = 1;
-+ goto restart;
- }
- }
- else
diff --git a/sys-apps/grub/files/grub-0.91/grub-0.90-symlinkmenulst.patch b/sys-apps/grub/files/grub-0.91/grub-0.90-symlinkmenulst.patch
deleted file mode 100644
index 0d55efe181f5..000000000000
--- a/sys-apps/grub/files/grub-0.91/grub-0.90-symlinkmenulst.patch
+++ /dev/null
@@ -1,16 +0,0 @@
-Only in grub: ChangeLog~
-diff -ur grub-0.90/util/grub-install.in grub/util/grub-install.in
---- grub-0.90/util/grub-install.in Wed Sep 5 15:50:06 2001
-+++ grub/util/grub-install.in Wed Sep 5 15:50:24 2001
-@@ -320,6 +320,10 @@
- exit 1
- fi
-
-+if ! test -e /boot/grub/grub.conf ; then
-+ test -e /boot/grub/menu.lst && ln -s ./menu.lst /boot/grub/grub.conf
-+fi
-+
- # Create a safe temporary file.
- test -x /bin/mktemp && log_file=`/bin/mktemp /tmp/grub-install.log.XXXXXX`
-
-Only in grub/util: grub-install.in.orig
diff --git a/sys-apps/grub/files/grub-0.91/grub-0.90-vga16-keypressclear.patch b/sys-apps/grub/files/grub-0.91/grub-0.90-vga16-keypressclear.patch
deleted file mode 100644
index e1678344ba12..000000000000
--- a/sys-apps/grub/files/grub-0.91/grub-0.90-vga16-keypressclear.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-diff -ur grub/stage2/stage2.c grub-0.90/stage2/stage2.c
---- grub/stage2/stage2.c Thu Jul 19 01:43:41 2001
-+++ grub-0.90/stage2/stage2.c Thu Jul 19 01:50:23 2001
-@@ -503,19 +503,6 @@
-
- c = translate_keycode (getkey ());
-
-- if (grub_timeout >= 0)
-- {
-- if (terminal & TERMINAL_DUMB)
-- grub_putchar ('\r');
-- else
-- gotoxy (view_x0 + 3, 22);
-- printf (" ");
-- grub_timeout = -1;
-- fallback_entry = -1;
-- if (! (terminal & TERMINAL_DUMB))
-- gotoxy (view_x1 - 6, view_x0 + 4 + entryno);
-- }
--
- /* We told them above (at least in SUPPORT_SERIAL) to use
- '^' or 'v' so accept these keys. */
- if (c == 16 || c == '^')
-@@ -792,6 +779,12 @@
- }
- #endif
- }
-+ if (grub_timeout >= 0)
-+ {
-+ grub_timeout = -1;
-+ fallback_entry = -1;
-+ goto restart;
-+ }
- }
- }
-
diff --git a/sys-apps/grub/files/grub-0.91/grub-0.91-initrdusemem.patch b/sys-apps/grub/files/grub-0.91/grub-0.91-initrdusemem.patch
deleted file mode 100644
index e28d58c901da..000000000000
--- a/sys-apps/grub/files/grub-0.91/grub-0.91-initrdusemem.patch
+++ /dev/null
@@ -1,107 +0,0 @@
---- grub-0.91/stage2/shared.h Fri Jan 25 21:33:39 2002
-+++ grub/stage2/shared.h Fri Jan 25 20:08:10 2002
-@@ -979,6 +979,9 @@
- int grub_strlen (const char *str);
- char *grub_strcpy (char *dest, const char *src);
-
-+/* simple version of string to unsigned long; doesn't handle bases */
-+unsigned long simple_strtoul(char *str_ptr, char **endp);
-+
- #ifndef GRUB_UTIL
- typedef unsigned long grub_jmp_buf[6];
- #else
---- grub-0.91/stage2/char_io.c Fri Jan 25 21:33:39 2002
-+++ grub/stage2/char_io.c Fri Jan 25 21:33:24 2002
-@@ -964,6 +964,34 @@
- return 1;
- }
-
-+/* convert a string to an unsigned long. basically taken straight from
-+ * the Linux kernel (lib/vsprintf.c) but made even simpler due to lack of
-+ * base handling
-+ * str_ptr is the start of the string,
-+ * endp will point to the end of the parsed string when we're done
-+ */
-+unsigned long
-+simple_strtoul(char *str_ptr, char **endp)
-+{
-+ unsigned long result = 0;
-+
-+ while (1)
-+ {
-+ unsigned int digit;
-+
-+ digit = *str_ptr - '0';
-+ /* since digit is unsigned, it will wrap */
-+ if (digit > 9)
-+ break;
-+ result = result * 10 + digit;
-+ str_ptr++;
-+ }
-+
-+ if (endp)
-+ *endp = (char *)str_ptr;
-+ return result;
-+}
-+
- int
- grub_tolower (int c)
- {
---- grub-0.91/stage2/boot.c Mon Nov 12 01:57:29 2001
-+++ grub/stage2/boot.c Fri Jan 25 21:27:44 2002
-@@ -28,6 +28,7 @@
- static int cur_addr;
- entry_func entry_addr;
- static struct mod_list mll[99];
-+static unsigned long kernel_mem_end = 0;
-
-
- /*
-@@ -308,6 +309,36 @@
- 0,
- (64 - setup_sects - 1) << 9);
-
-+ /* we need to parse mem= from the command-line so that we can load
-+ the initrd in the right place. bleah */
-+ {
-+ char *mem;
-+
-+ mem = grub_strstr (arg, "mem=");
-+ if (mem)
-+ {
-+ /* we handle this identically to the kernel; see memparse
-+ in lib/cmdline.c of the kernel source for the
-+ original location of this code */
-+ kernel_mem_end = simple_strtoul(mem+4, &mem);
-+
-+ switch(*mem)
-+ {
-+ case 'G':
-+ case 'g':
-+ kernel_mem_end <<= 10;
-+ case 'M':
-+ case 'm':
-+ kernel_mem_end <<= 10;
-+ case 'K':
-+ case 'k':
-+ kernel_mem_end <<= 10;
-+ default:
-+ break;
-+ }
-+ }
-+ }
-+
- /* Copy command-line plus memory hack to staging area.
- NOTE: Linux has a bug that it doesn't handle multiple spaces
- between two options and a space after a "mem=" option isn't
-@@ -720,7 +751,9 @@
- goto fail;
- }
-
-- moveto = ((mbi.mem_upper + 0x400) * 0x400 - len) & 0xfffff000;
-+ if (!kernel_mem_end)
-+ kernel_mem_end = (mbi.mem_upper + 0x400) * 0x400;
-+ moveto = (kernel_mem_end - len) & 0xfffff000;
- if (moveto + len >= LINUX_INITRD_MAX_ADDRESS)
- moveto = (LINUX_INITRD_MAX_ADDRESS - len) & 0xfffff000;
-
diff --git a/sys-apps/grub/files/grub-0.91/grub-0.91-splashimagehelp.patch b/sys-apps/grub/files/grub-0.91/grub-0.91-splashimagehelp.patch
deleted file mode 100644
index cc7807350493..000000000000
--- a/sys-apps/grub/files/grub-0.91/grub-0.91-splashimagehelp.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-diff -ur grub-0.91/docs/grub.texi grub/docs/grub.texi
---- grub-0.91/docs/grub.texi Mon Jan 21 22:57:46 2002
-+++ grub/docs/grub.texi Mon Jan 21 22:57:51 2002
-@@ -1891,6 +1891,7 @@
- * rarp:: Initialize a network device via RARP
- * serial:: Set up a serial device
- * setkey:: Configure the key map
-+* splashimage:: Use a splash image
- * terminal:: Choose a terminal
- * tftpserver:: Specify a TFTP server
- * unhide:: Unhide a partition
-@@ -2260,6 +2261,16 @@
- @end deffn
-
-
-+@node splashimage
-+@subsection splashimage
-+
-+@deffn Command splashimage file
-+Select an image to use as the background image. This should be
-+specified using normal GRUB device naming syntax. The format of the
-+file is a gzipped xpm which is 640x480 with a 14 color palette.
-+@end deffn
-+
-+
- @node terminal
- @subsection terminal
-
diff --git a/sys-apps/grub/files/grub-0.91/grub-0.91-vga16.patch b/sys-apps/grub/files/grub-0.91/grub-0.91-vga16.patch
deleted file mode 100644
index e908f921a908..000000000000
--- a/sys-apps/grub/files/grub-0.91/grub-0.91-vga16.patch
+++ /dev/null
@@ -1,2057 +0,0 @@
-diff -urN grub-0.91/ChangeLog grub/ChangeLog
---- grub-0.91/ChangeLog Sat Jan 19 15:26:02 2002
-+++ grub/ChangeLog Mon Jan 21 22:44:25 2002
-@@ -1877,6 +1877,18 @@
- [!STAGE1_5] (CMDLINE_WIDTH): New macro.
- [!STAGE1_5] (CMDLINE_MARGIN): Likewise.
- * stage2/shared.h (TERMINAL_DUMB): Likewise.
-+
-+2000-08-29 Paulo César Pereira de Andrade <pcpa@conectiva.com.br>
-+
-+ * configure.in: Added --disable-vga16 option, in case user does not
-+ want the new VGA graphics interface.
-+ * stage2/asm.S: Added some new functions, for graphics operations,
-+ and renamed several functions to allow wrapping them.
-+ * stage2/stage2.c: Main changes for VGA16 support.
-+ * stage2/char_io.c: Modified calls of grub_putchar to putchar
-+ * stage2/disk_io.c: Same as for char_io.c
-+ * stage2/cmdline.c: Also, the same as for char_io.c
-+ * stage2/shared.h: Definitions for externs and wrapping functions.
-
- 2000-08-28 OKUJI Yoshinori <okuji@gnu.org>
-
-diff -urN grub-0.91/configure.in grub/configure.in
---- grub-0.91/configure.in Tue Jan 15 05:27:59 2002
-+++ grub/configure.in Mon Jan 21 22:44:25 2002
-@@ -18,6 +18,7 @@
- AC_PREREQ(2.13)
-
- AC_CANONICAL_HOST
-+AM_PROG_LIBTOOL
-
- case "$host_cpu" in
- i[[3456]]86) host_cpu=i386 ;;
-@@ -610,6 +611,12 @@
- ASFLAGS='$(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(CPPFLAGS) $(CFLAGS)'
- AC_SUBST(ASFLAGS)
-
-+AC_ARG_ENABLE(vga16,
-+ [ --disable-vga16 disable VGA graphics interface])
-+
-+if test x"$enable_vga16" != xno; then
-+ STAGE2_CFLAGS="$STAGE2_CFLAGS -DVGA16=1"
-+fi
-
- dnl Output.
- AC_OUTPUT([Makefile stage1/Makefile stage2/Makefile docs/Makefile \
-diff -urN grub-0.91/stage2/asm.S grub/stage2/asm.S
---- grub-0.91/stage2/asm.S Sat Dec 29 13:05:36 2001
-+++ grub/stage2/asm.S Mon Jan 21 22:44:25 2002
-@@ -1865,7 +1865,7 @@
- * %cl = cursor ending scanline
- */
-
--ENTRY(nocursor)
-+ENTRY(grub_nocursor)
- push %ebp
- push %ebx /* save EBX */
-
-@@ -1951,7 +1951,7 @@
-
-
- /*
-- * console_set_attrib(attr) : Sets the character attributes for character at
-+ * grub_set_attrib(attr) : Sets the character attributes for character at
- * current cursor position.
- *
- * Bitfields for character's display attribute:
-@@ -1985,7 +1985,7 @@
- * %cx = count to display (???, possible side-effects!!)
- */
-
--ENTRY(console_set_attrib)
-+ENTRY(grub_set_attrib)
- push %ebp
- push %ebx
-
-@@ -2009,6 +2009,263 @@
- pop %ebp
- ret
-
-+#ifdef VGA16
-+VARIABLE(cursorX)
-+.word 0
-+VARIABLE(cursorY)
-+.word 0
-+VARIABLE(cursorWidth)
-+.word 0
-+VARIABLE(cursorHeight)
-+.word 0
-+VARIABLE(cursorCount)
-+.word 0
-+VARIABLE(cursorBuf)
-+.byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
-+
-+/*
-+ * set_int1c_handler(void)
-+ */
-+ENTRY(set_int1c_handler)
-+ pushl %edi
-+
-+ /* save the original int1c handler */
-+ movl $0x70, %edi
-+ movw (%edi), %ax
-+ movw %ax, ABS(int1c_offset)
-+ movw 2(%edi), %ax
-+ movw %ax, ABS(int1c_segment)
-+
-+ /* save the new int1c handler */
-+ movw $ABS(int1c_handler), %ax
-+ movw %ax, (%edi)
-+ xorw %ax, %ax
-+ movw %ax, 2(%edi)
-+
-+ popl %edi
-+ ret
-+
-+
-+/*
-+ * unset_int1c_handler(void)
-+ */
-+ENTRY(unset_int1c_handler)
-+ pushl %edi
-+
-+ /* check if int1c_handler is set */
-+ movl $0x70, %edi
-+ movw $ABS(int1c_handler), %ax
-+ cmpw %ax, (%edi)
-+ jne int1c_1
-+ xorw %ax, %ax
-+ cmpw %ax, 2(%edi)
-+ jne int1c_1
-+
-+ /* restore the original */
-+ movw ABS(int1c_offset), %ax
-+ movw %ax, (%edi)
-+ movw ABS(int1c_segment), %ax
-+ movw %ax, 2(%edi)
-+
-+int1c_1:
-+ popl %edi
-+ ret
-+
-+/*
-+ * blinks graphics cursor
-+ */
-+ .code16
-+write_data:
-+ movw $0, %ax
-+ movw %ax, %ds
-+
-+ mov $0xA000, %ax /* video in es:di */
-+ mov %ax, %es
-+ mov $80, %ax
-+ movw $ABS(cursorY), %si
-+ mov %ds:(%si), %bx
-+ mul %bx
-+ movw $ABS(cursorX), %si
-+ mov %ds:(%si), %bx
-+ shr $3, %bx /* %bx /= 8 */
-+ add %bx, %ax
-+ mov %ax, %di
-+
-+ movw $ABS(cursorBuf), %si /* fontBuf in ds:si */
-+
-+ /* prepare for data moving */
-+ mov $16, %dx /* altura da fonte */
-+ mov $80, %bx /* bytes por linha */
-+
-+write_loop:
-+ movb %ds:(%si), %al
-+ xorb $0xff, %al
-+ movb %al, %ds:(%si) /* invert cursorBuf */
-+ movb %al, %es:(%di) /* write to video */
-+ add %bx, %di
-+ inc %si
-+ dec %dx
-+ jg write_loop
-+ ret
-+
-+int1c_handler:
-+ pusha
-+ mov $0, %ax
-+ mov %ax, %ds
-+ mov $ABS(cursorCount), %si
-+ mov %ds:(%si), %ax
-+ inc %ax
-+ mov %ax, %ds:(%si)
-+ cmp $9, %ax
-+ jne int1c_done
-+
-+ mov $0, %ax
-+ mov %ax, %ds:(%si)
-+/*
-+ movw $0x3c4, %dx
-+ movb $0x020f, %ax
-+ outw %ax, %dx
-+*/
-+ call write_data
-+
-+int1c_done:
-+ popa
-+ iret
-+ /* call previous int1c handler */
-+ /* ljmp */
-+ .byte 0xea
-+int1c_offset: .word 0
-+int1c_segment: .word 0
-+ .code32
-+
-+
-+ENTRY(get_font)
-+ push %ebp
-+ push %ebx
-+ push %ecx
-+ push %edx
-+
-+ call EXT_C(prot_to_real)
-+ .code16
-+
-+ movw $0x1130, %ax
-+ movb $6, %bh /* font 8x16 */
-+ int $0x10
-+ movw %bp, %dx
-+ movw %es, %cx
-+
-+ DATA32 call EXT_C(real_to_prot)
-+ .code32
-+
-+ xorl %eax, %eax
-+ movw %cx, %ax
-+ shll $4, %eax
-+ movw %dx, %ax
-+
-+ pop %edx
-+ pop %ecx
-+ pop %ebx
-+ pop %ebp
-+ ret
-+
-+/*
-+ * set_videomode(mode)
-+ * BIOS call "INT 10H Function 0h" to set video mode
-+ * Call with %ah = 0x0
-+ * %al = video mode
-+ */
-+ENTRY(set_videomode)
-+ push %ebp
-+ push %ebx
-+ push %ecx
-+
-+ movb 0x10(%esp), %cl
-+
-+ call EXT_C(prot_to_real)
-+ .code16
-+
-+ xorw %bx, %bx
-+ movb $0xf, %ah
-+ int $0x10 /* Get Current Video mode */
-+ movb %al, %ch
-+ xorb %ah, %ah
-+ movb %cl, %al
-+ int $0x10 /* Set Video mode */
-+
-+ DATA32 call EXT_C(real_to_prot)
-+ .code32
-+
-+ xorb %ah, %ah
-+ movb %ch, %al
-+
-+ pop %ecx
-+ pop %ebx
-+ pop %ebp
-+ ret
-+
-+/*
-+ * set_palette(index, red, green, blue)
-+ * BIOS call "INT 10H Function 10h" to set individual dac register
-+ * Call with %ah = 0x10
-+ * %bx = register number
-+ * %ch = new value for green (0-63)
-+ * %cl = new value for blue (0-63)
-+ * %dh = new value for red (0-63)
-+ */
-+
-+ENTRY(set_palette)
-+ push %ebp
-+ push %eax
-+ push %ebx
-+ push %ecx
-+ push %edx
-+
-+ movw $0x3c8, %bx /* address write mode register */
-+
-+ /* wait vertical retrace */
-+
-+ movw $0x3da, %dx
-+l1b: inb %dx, %al /* wait vertical active display */
-+ test $8, %al
-+ jnz l1b
-+
-+l2b: inb %dx, %al /* wait vertical retrace */
-+ test $8, %al
-+ jnz l2b
-+
-+ mov %bx, %dx
-+ movb 0x18(%esp), %al /* index */
-+ outb %al, %dx
-+ inc %dx
-+
-+ movb 0x1c(%esp), %al /* red */
-+ outb %al, %dx
-+
-+ movb 0x20(%esp), %al /* green */
-+ outb %al, %dx
-+
-+ movb 0x24(%esp), %al /* blue */
-+ outb %al, %dx
-+
-+ movw 0x18(%esp), %bx
-+
-+ call EXT_C(prot_to_real)
-+ .code16
-+
-+ movb %bl, %bh
-+ movw $0x1000, %ax
-+ int $0x10
-+
-+ DATA32 call EXT_C(real_to_prot)
-+ .code32
-+
-+ pop %edx
-+ pop %ecx
-+ pop %ebx
-+ pop %eax
-+ pop %ebp
-+ ret
-+#endif
-
- /*
- * getrtsecs()
-diff -urN grub-0.91/stage2/builtins.c grub/stage2/builtins.c
---- grub-0.91/stage2/builtins.c Wed Jan 2 18:23:30 2002
-+++ grub/stage2/builtins.c Mon Jan 21 22:44:25 2002
-@@ -133,6 +133,36 @@
- grub_printf ("[%d,%d,%d]", sector, offset, length);
- }
-
-+#ifdef VGA16
-+/* background */
-+static int
-+background_func(char *arg, int flags)
-+{
-+ if (grub_strlen(arg) == 6) {
-+ int r = ((hex(arg[0]) << 4) | hex(arg[1])) >> 2;
-+ int g = ((hex(arg[2]) << 4) | hex(arg[3])) >> 2;
-+ int b = ((hex(arg[4]) << 4) | hex(arg[5])) >> 2;
-+
-+ background = (r << 16) | (g << 8) | b;
-+ if (vga_inited)
-+ set_palette(0, r, g, b);
-+ return (0);
-+ }
-+
-+ return (1);
-+}
-+
-+static struct builtin builtin_background =
-+{
-+ "background",
-+ background_func,
-+ BUILTIN_CMDLINE | BUILTIN_MENU,
-+ "background RRGGBB",
-+ "Sets the background color when in graphics mode."
-+ "RR is red, GG is green, and BB blue. Numbers must be in hexadecimal."
-+};
-+#endif /* VGA16 */
-+
-
- /* blocklist */
- static int
-@@ -399,6 +429,40 @@
- #endif /* SUPPORT_NETBOOT */
-
-
-+#ifdef VGA16
-+
-+/* foreground */
-+static int
-+border_func(char *arg, int flags)
-+{
-+ if (grub_strlen(arg) == 6) {
-+ int r = ((hex(arg[0]) << 4) | hex(arg[1])) >> 2;
-+ int g = ((hex(arg[2]) << 4) | hex(arg[3])) >> 2;
-+ int b = ((hex(arg[4]) << 4) | hex(arg[5])) >> 2;
-+
-+ border = (r << 16) | (g << 8) | b;
-+ if (vga_inited)
-+ set_palette(0x11, r, g, b);
-+
-+ return (0);
-+ }
-+
-+ return (1);
-+}
-+
-+static struct builtin builtin_border =
-+{
-+ "border",
-+ border_func,
-+ BUILTIN_CMDLINE | BUILTIN_MENU,
-+ "border RRGGBB",
-+ "Sets the border video color when in graphics mode."
-+ "RR is red, GG is green, and BB blue. Numbers must be in hexadecimal."
-+};
-+
-+#endif /* VGA16 */
-+
-+
- /* cat */
- static int
- cat_func (char *arg, int flags)
-@@ -409,7 +473,7 @@
- return 1;
-
- while (grub_read (&c, 1))
-- grub_putchar (c);
-+ putchar (c);
-
- grub_close ();
- return 0;
-@@ -963,6 +1027,44 @@
- return 0;
- }
-
-+
-+#ifdef VGA16
-+/* display */
-+static int
-+display_func(char *arg, int flags)
-+{
-+ int i;
-+
-+ for (i = 0; i < MAX_DISPLAYS; i++) {
-+ if (grub_strcmp(arg, display_entries[i].name) == 0)
-+ break;
-+ }
-+
-+ if (i >= MAX_DISPLAYS)
-+ return (1);
-+
-+ display_idx = i;
-+ if (display->End)
-+ (*display->End)();
-+ display = &display_entries[display_idx];
-+
-+ /* Restart cmain */
-+ grub_longjmp (restart_env, 0);
-+ /*NOTREACHED*/
-+
-+ return (0);
-+}
-+
-+static struct builtin builtin_display =
-+{
-+ "display",
-+ display_func,
-+ BUILTIN_CMDLINE,
-+ "display MODEL",
-+ "Changes display type. Available modes are \"text\" and \"vga16\"."
-+};
-+#endif /* VGA16 */
-+
- static struct builtin builtin_displaymem =
- {
- "displaymem",
-@@ -1238,6 +1340,39 @@
- " the devices which contain the file."
- };
-
-+#ifdef VGA16
-+
-+/* foreground */
-+static int
-+foreground_func(char *arg, int flags)
-+{
-+ if (grub_strlen(arg) == 6) {
-+ int r = ((hex(arg[0]) << 4) | hex(arg[1])) >> 2;
-+ int g = ((hex(arg[2]) << 4) | hex(arg[3])) >> 2;
-+ int b = ((hex(arg[4]) << 4) | hex(arg[5])) >> 2;
-+
-+ foreground = (r << 16) | (g << 8) | b;
-+ if (vga_inited)
-+ set_palette(15, r, g, b);
-+
-+ return (0);
-+ }
-+
-+ return (1);
-+}
-+
-+static struct builtin builtin_foreground =
-+{
-+ "foreground",
-+ foreground_func,
-+ BUILTIN_CMDLINE | BUILTIN_MENU,
-+ "foreground RRGGBB",
-+ "Sets the foreground color when in graphics mode."
-+ "RR is red, GG is green, and BB blue. Numbers must be in hexadecimal."
-+};
-+
-+#endif /* VGA16 */
-+
-
- /* fstest */
- static int
-@@ -1390,12 +1525,13 @@
-
-
- /* help */
--#define MAX_SHORT_DOC_LEN 39
--#define MAX_LONG_DOC_LEN 66
-
- static int
- help_func (char *arg, int flags)
- {
-+ int MAX_SHORT_DOC_LEN = (view_x1 - view_x0 + 1) / 2 - 1;
-+ int MAX_LONG_DOC_LEN = (view_x1 - view_x0) - 14;
-+
- if (! *arg)
- {
- /* Invoked with no argument. Print the list of the short docs. */
-@@ -1418,13 +1554,13 @@
- len = MAX_SHORT_DOC_LEN - 1;
-
- for (i = 0; i < len; i++)
-- grub_putchar ((*builtin)->short_doc[i]);
-+ putchar ((*builtin)->short_doc[i]);
-
- for (; i < MAX_SHORT_DOC_LEN; i++)
-- grub_putchar (' ');
-+ putchar (' ');
-
- if (! left)
-- grub_putchar ('\n');
-+ putchar ('\n');
-
- left = ! left;
- }
-@@ -1474,8 +1610,8 @@
-
- grub_printf (" ");
- for (i = 0; i < len; i++)
-- grub_putchar (*doc++);
-- grub_putchar ('\n');
-+ putchar (*doc++);
-+ putchar ('\n');
- }
- }
- }
-@@ -3149,6 +3285,74 @@
- "Save the current entry as the default boot entry."
- };
-
-+#ifdef VGA16
-+/*splashimage*/
-+static int
-+splashimage_func(char *arg, int flags)
-+{
-+ if (strlen(arg) > 63)
-+ return (1);
-+ if (flags == BUILTIN_CMDLINE) {
-+ if (!grub_open(arg))
-+ return (1);
-+ grub_close();
-+ }
-+
-+ if (flags == BUILTIN_CMDLINE || !splash_set) {
-+ strcpy(splashimage, arg);
-+ splash_set = 1;
-+ }
-+
-+ if (flags == BUILTIN_CMDLINE && vga_inited) {
-+ display->End();
-+ display->Begin();
-+ cls();
-+/* grub_longjmp(restart_env, 0);*/
-+ }
-+
-+ return (0);
-+}
-+
-+static struct builtin builtin_splashimage =
-+{
-+ "splashimage",
-+ splashimage_func,
-+ BUILTIN_CMDLINE | BUILTIN_MENU,
-+ "splashimage FILE",
-+ "Load FILE as the background image when in graphics mode."
-+};
-+
-+/*shade*/
-+static int
-+shade_func(char *arg, int flags)
-+{
-+ int new_shade;
-+
-+ if (!arg || safe_parse_maxint(&arg, &new_shade) == 0)
-+ return (1);
-+
-+ if (shade != new_shade) {
-+ shade = new_shade;
-+ if (flags == BUILTIN_CMDLINE && vga_inited) {
-+ display->End();
-+ display->Begin();
-+ cls();
-+ }
-+ }
-+
-+ return (0);
-+}
-+
-+static struct builtin builtin_shade =
-+{
-+ "shade",
-+ shade_func,
-+ BUILTIN_CMDLINE | BUILTIN_MENU,
-+ "shade INTEGER",
-+ "If set to 0, disables the use of shaded text, else enables it."
-+};
-+#endif /* VGA16 */
-+
-
- #ifdef SUPPORT_SERIAL
- /* serial */
-@@ -4438,16 +4642,79 @@
- "Probe VBE information. If the mode number MODE is specified, show only"
- " the information about only the mode."
- };
--
-+
-+#ifdef VGA16
-
-+/* viewport */
-+static int
-+viewport_func (char *arg, int flags)
-+{
-+ int i;
-+ int x0 = 80, y0 = 25, x1 = 0, y1 = 0;
-+ int *pos[4] = { &x0, &y0, &x1, &y1 };
-+ extern int viewport_set;
-+
-+ if (!arg)
-+ return (1);
-+ for (i = 0; i < 4; i++) {
-+ if (!*arg)
-+ return (1);
-+ while (*arg && (*arg == ' ' || *arg == '\t'))
-+ ++arg;
-+ if (!safe_parse_maxint(&arg, pos[i]))
-+ return (1);
-+ while (*arg && (*arg != ' ' && *arg != '\t'))
-+ ++arg;
-+ }
-+
-+ x1 += x0;
-+ y1 += y0;
-+
-+ /* minimum size is 60 colums and 16 rows */
-+ if (x0 > x1 - 60 || y0 > y1 - 16 || x0 < 0 || y0 < 0 || x1 > 80 || y1 > 30)
-+ return (1);
-+
-+ viewport_set = 1;
-+ view_x0 = x0;
-+ view_y0 = y0;
-+ view_x1 = x1;
-+ view_y1 = y1;
-+
-+ if (flags == BUILTIN_CMDLINE && vga_inited) {
-+ display->End();
-+ display->Begin();
-+ cls();
-+ }
-+
-+ return (0);
-+}
-+
-+static struct builtin builtin_viewport =
-+{
-+ "viewport",
-+ viewport_func,
-+ BUILTIN_CMDLINE | BUILTIN_MENU,
-+ "viewport x y width height",
-+ "Changes grub internals to output text in the window defined by"
-+ " four parameters. The x and y parameters are 0 based. This option"
-+ " only works with the vga interface."
-+};
-+#endif /* VGA16 */
-+
- /* The table of builtin commands. Sorted in dictionary order. */
- struct builtin *builtin_table[] =
- {
-+#ifdef VGA16
-+ &builtin_background,
-+#endif /* VGA16 */
- &builtin_blocklist,
- &builtin_boot,
- #ifdef SUPPORT_NETBOOT
- &builtin_bootp,
- #endif /* SUPPORT_NETBOOT */
-+#ifdef VGA16
-+ &builtin_border,
-+#endif /* VGA16 */
- &builtin_cat,
- &builtin_chainloader,
- &builtin_cmp,
-@@ -4461,11 +4728,17 @@
- #ifdef SUPPORT_NETBOOT
- &builtin_dhcp,
- #endif /* SUPPORT_NETBOOT */
-+#ifdef VGA16
-+ &builtin_display,
-+#endif /* VGA16 */
- &builtin_displayapm,
- &builtin_displaymem,
- &builtin_embed,
- &builtin_fallback,
- &builtin_find,
-+#ifdef VGA16
-+ &builtin_foreground,
-+#endif /* VGA16 */
- &builtin_fstest,
- &builtin_geometry,
- &builtin_halt,
-@@ -4508,6 +4781,10 @@
- #endif /* SUPPORT_SERIAL */
- &builtin_setkey,
- &builtin_setup,
-+#ifdef VGA16
-+ &builtin_shade,
-+ &builtin_splashimage,
-+#endif /* VGA16 */
- #if defined(SUPPORT_SERIAL) || defined(SUPPORT_HERCULES)
- &builtin_terminal,
- #endif /* SUPPORT_SERIAL || SUPPORT_HERCULES */
-@@ -4521,5 +4798,8 @@
- &builtin_unhide,
- &builtin_uppermem,
- &builtin_vbeprobe,
-+#ifdef VGA16
-+ &builtin_viewport,
-+#endif /* VGA16 */
- 0
- };
-diff -urN grub-0.91/stage2/char_io.c grub/stage2/char_io.c
---- grub-0.91/stage2/char_io.c Fri Jan 18 13:01:26 2002
-+++ grub/stage2/char_io.c Mon Jan 21 22:47:43 2002
-@@ -262,8 +262,8 @@
-
- /* XXX: These should be defined in shared.h, but I leave these here,
- until this code is freezed. */
--#define CMDLINE_WIDTH 78
--#define CMDLINE_MARGIN 10
-+ int CMDLINE_WIDTH = (view_x1 - view_x0) - 2;
-+ int CMDLINE_MARGIN = 10;
-
- int xpos, lpos, c, section;
- /* The length of PROMPT. */
-@@ -313,7 +313,7 @@
- {
- int y = getxy () & 0xFF;
-
-- gotoxy (xpos, y);
-+ gotoxy (xpos + view_x0, y);
- }
- # ifdef SUPPORT_SERIAL
- else if (! (terminal & TERMINAL_DUMB) && (count > 4))
-@@ -325,7 +325,7 @@
- int i;
-
- for (i = 0; i < count; i++)
-- grub_putchar ('\b');
-+ putchar ('\b');
- }
- # endif /* SUPPORT_SERIAL */
- }
-@@ -351,7 +351,7 @@
- {
- int y = getxy () & 0xFF;
-
-- gotoxy (xpos, y);
-+ gotoxy (xpos + view_x0, y);
- }
- # ifdef SUPPORT_SERIAL
- else if (! (terminal & TERMINAL_DUMB) && (count > 4))
-@@ -365,9 +365,9 @@
- for (i = lpos - count; i < lpos; i++)
- {
- if (! echo_char)
-- grub_putchar (buf[i]);
-+ putchar (buf[i]);
- else
-- grub_putchar (echo_char);
-+ putchar (echo_char);
- }
- }
- # endif /* SUPPORT_SERIAL */
-@@ -395,7 +395,7 @@
- /* From the start to the end. */
- len = CMDLINE_WIDTH;
- pos = 0;
-- grub_putchar ('\r');
-+ putchar ('\r');
-
- /* If SECTION is the first section, print the prompt, otherwise,
- print `<'. */
-@@ -407,7 +407,7 @@
- }
- else
- {
-- grub_putchar ('<');
-+ putchar ('<');
- len--;
- pos++;
- }
-@@ -443,9 +443,9 @@
- for (i = start; i < start + len && i < llen; i++)
- {
- if (! echo_char)
-- grub_putchar (buf[i]);
-+ putchar (buf[i]);
- else
-- grub_putchar (echo_char);
-+ putchar (echo_char);
-
- pos++;
- }
-@@ -455,7 +455,7 @@
- /* Fill up the rest of the line with spaces. */
- for (; i < start + len; i++)
- {
-- grub_putchar (' ');
-+ putchar (' ');
- pos++;
- }
-
-@@ -464,9 +464,9 @@
- if (pos == CMDLINE_WIDTH)
- {
- if (start + len < llen)
-- grub_putchar ('>');
-+ putchar ('>');
- else
-- grub_putchar (' ');
-+ putchar (' ');
-
- pos++;
- }
-@@ -480,7 +480,7 @@
- {
- int y = getxy () & 0xFF;
-
-- gotoxy (xpos, y);
-+ gotoxy (xpos + view_x0, y);
- }
- # ifdef SUPPORT_SERIAL
- else if (! (terminal & TERMINAL_SERIAL) && (pos - xpos > 4))
-@@ -490,7 +490,7 @@
- else
- {
- for (i = 0; i < pos - xpos; i++)
-- grub_putchar ('\b');
-+ putchar ('\b');
- }
- # endif /* SUPPORT_SERIAL */
- }
-@@ -500,7 +500,7 @@
- void cl_init (void)
- {
- /* Distinguish us from other lines and error messages! */
-- grub_putchar ('\n');
-+ putchar ('\n');
-
- /* Print full line and set position here. */
- cl_refresh (1, 0);
-@@ -631,7 +631,7 @@
- /* There are more than one candidates, so print
- the list. */
-
-- grub_putchar ('\n');
-+ putchar ('\n');
- /* Enable the auto fill mode temporarily. */
- auto_fill = 1;
- print_completions (is_filename, 0);
-@@ -773,7 +773,7 @@
- }
- }
-
-- grub_putchar ('\n');
-+ putchar ('\n');
-
- /* If ECHO_CHAR is NUL, remove the leading spaces. */
- lpos = 0;
-@@ -1119,7 +1119,7 @@
- {
- /* Fold a line only if AUTO_FILL is true. */
- if (auto_fill && col >= 79)
-- grub_putchar ('\n');
-+ putchar ('\n');
-
- col++;
- }
-@@ -1142,7 +1142,7 @@
-
- #ifndef STAGE1_5
- void
--gotoxy (int x, int y)
-+grub_gotoxy (int x, int y)
- {
- if (terminal & TERMINAL_CONSOLE)
- console_gotoxy (x, y);
-@@ -1166,7 +1166,7 @@
- #endif /* SUPPORT_SERIAL */
-
- int
--getxy (void)
-+grub_getxy (void)
- {
- int ret = 0;
-
-@@ -1271,7 +1271,7 @@
- #endif /* SUPPORT_SERIAL */
-
- void
--cls (void)
-+grub_cls (void)
- {
- if (terminal & TERMINAL_CONSOLE)
- console_cls ();
-@@ -1292,7 +1292,7 @@
- {
- /* If the terminal is dumb, there is no way to clean the terminal. */
- if (terminal & TERMINAL_DUMB)
-- grub_putchar ('\n');
-+ putchar ('\n');
- else
- grub_printf ("\e[H\e[J");
- }
-diff -urN grub-0.91/stage2/cmdline.c grub/stage2/cmdline.c
---- grub-0.91/stage2/cmdline.c Wed Jan 2 18:23:30 2002
-+++ grub/stage2/cmdline.c Mon Jan 21 22:44:25 2002
-@@ -125,7 +125,7 @@
- init_page ();
- #ifdef SUPPORT_DISKLESS
- print_network_configuration ();
-- grub_putchar ('\n');
-+ putchar ('\n');
- #endif
- print_cmdline_message (forever);
-
-diff -urN grub-0.91/stage2/disk_io.c grub/stage2/disk_io.c
---- grub-0.91/stage2/disk_io.c Wed Nov 28 13:43:56 2001
-+++ grub/stage2/disk_io.c Mon Jan 21 22:44:25 2002
-@@ -1267,7 +1267,7 @@
- }
-
- if (! is_completion)
-- grub_putchar ('\n');
-+ putchar ('\n');
-
- print_error ();
- do_completion = 0;
-@@ -1334,7 +1334,7 @@
- }
-
- if (! is_completion)
-- grub_putchar ('\n');
-+ putchar ('\n');
- }
- else
- {
-@@ -1408,7 +1408,7 @@
- }
-
- if (! is_completion)
-- grub_putchar ('\n');
-+ putchar ('\n');
- }
- else
- errnum = ERR_BAD_FILENAME;
-diff -urN grub-0.91/stage2/shared.h grub/stage2/shared.h
---- grub-0.91/stage2/shared.h Mon Jan 7 21:57:36 2002
-+++ grub/stage2/shared.h Mon Jan 21 22:44:25 2002
-@@ -44,6 +44,12 @@
- # define RAW_SEG(x) (x)
- #endif
-
-+#if defined(VGA16)
-+#if defined(GRUB_UTIL) || defined(STAGE1_5)
-+#undef VGA16
-+#endif
-+#endif
-+
- /*
- * Integer sizes
- */
-@@ -367,8 +373,10 @@
- #define isspace grub_isspace
- #define printf grub_printf
- #define sprintf grub_sprintf
-+#ifndef VGA16
- #undef putchar
- #define putchar grub_putchar
-+#endif
- #define strncat grub_strncat
- #define strstr grub_strstr
- #define memcmp grub_memcmp
-@@ -383,6 +391,9 @@
- /*
- * Below this should be ONLY defines and other constructs for C code.
- */
-+#ifdef VGA16
-+#define VIDEO 0xA0000
-+#endif
-
- /* multiboot stuff */
-
-@@ -773,26 +784,26 @@
- int currticks (void);
-
- /* Clear the screen. */
--void cls (void);
-+void grub_cls (void);
-
- /* The console part of cls. */
- void console_cls (void);
-
- #ifndef GRUB_UTIL
- /* Turn off cursor. */
--void nocursor (void);
-+void grub_nocursor (void);
- #endif
-
- /* Get the current cursor position (where 0,0 is the top left hand
- corner of the screen). Returns packed values, (RET >> 8) is x,
- (RET & 0xff) is y. */
--int getxy (void);
-+int grub_getxy (void);
-
- /* The console part of getxy. */
- int console_getxy (void);
-
- /* Set the cursor position. */
--void gotoxy (int x, int y);
-+void grub_gotoxy (int x, int y);
-
- /* The console part of gotoxy. */
- void console_gotoxy (int x, int y);
-@@ -822,8 +833,64 @@
- constants defined above. */
- void set_attrib (int attr);
-
-+extern int view_x0, view_y0, view_x1, view_y1;
-+#ifdef VGA16
-+#define MAX_DISPLAYS 2
-+
-+#define cls() (display->Cls ? (*display->Cls)() : 0)
-+#define gotoxy(x, y) (display->Gotoxy ? (*display->Gotoxy)(x, y) : 0)
-+#define putchar(c) (display->Putchar ? (*display->Putchar)(c) : 0)
-+#define console_set_attrib(a) (display->SetAttrib ? (*display->SetAttrib)(a) : 0)
-+#define getxy() (display->Getxy ? (*display->Getxy)() : 0)
-+#define nocursor() (display->Nocursor ? (*display->Nocursor)() : 0)
-+struct display_entry {
-+ char *name;
-+ int (*Begin)(void);
-+ void (*End)(void);
-+ void (*Cls)(void);
-+ void (*Gotoxy)(int x, int y);
-+ void (*Putchar)(int ch);
-+ void (*SetAttrib)(int attr);
-+ int (*Getxy)(void);
-+ void (*Nocursor)(void);
-+};
-+struct display_entry display_entries[MAX_DISPLAYS + 1];
-+extern struct display_entry *display;
-+
-+extern int vga_inited, foreground, background, shade, border;
-+extern int display_idx, splash_set;
-+extern short cursorX, cursorY, cursorWidth, cursorHeight;
-+extern char cursorBuf[16], splashimage[64];
-+
-+int vga16_begin(void);
-+void vga16_end(void);
-+void vga16_cls(void);
-+void vga16_gotoxy(int x, int y);
-+void vga16_putchar(int ch);
-+int vga16_getxy(void);
-+void vga16_nocursor(void);
-+void vga16_set_attrib(int attr);
-+
-+int read_image();
-+void set_palette(int index, int red, int green, int blue);
-+void *get_font(void);
-+/* return previous video mode */
-+int set_videomode(int mode);
-+
-+int hex(int);
-+void set_int1c_handler();
-+void unset_int1c_handler();
-+void cursor(int state);
-+#else
-+#define cls grub_cls
-+#define gotoxy grub_gotoxy
-+#define console_set_attrib grub_set_attrib
-+#define getxy grub_getxy
-+#define nocursor grub_nocursor
-+#endif
-+
- /* The console part of set_attrib. */
--void console_set_attrib (int attr);
-+void grub_set_attrib (int attr);
-
- /* Low-level disk I/O */
- int get_diskinfo (int drive, struct geometry *geometry);
-diff -urN grub-0.91/stage2/stage2.c grub/stage2/stage2.c
---- grub-0.91/stage2/stage2.c Mon Jan 7 21:56:45 2002
-+++ grub/stage2/stage2.c Mon Jan 21 22:45:49 2002
-@@ -19,7 +19,12 @@
-
- #include "shared.h"
-
-+int view_x0 = 0, view_y0 = 0, view_x1 = 80, view_y1 = 25;
- grub_jmp_buf restart_env;
-+#ifdef VGA16
-+int vga_disabled = 0, viewport_set = 0;
-+int sx0, sy0, sx1, sy1;
-+#endif
-
- #if defined(PRESET_MENU_STRING) || defined(SUPPORT_DISKLESS)
-
-@@ -109,12 +114,12 @@
- }
- #endif /* SUPPORT_SERIAL */
-
-- gotoxy (77, y + 1);
-+ gotoxy (view_x1 - 3, y + 1);
-
- if (first)
-- grub_putchar (disp_up);
-+ putchar (disp_up);
- else
-- grub_putchar (' ');
-+ putchar (' ');
-
- menu_entries = get_entry (menu_entries, first, 0);
-
-@@ -122,13 +127,13 @@
- {
- int j = 0;
-
-- gotoxy (3, y + i);
-+ gotoxy (view_x0 + 3, y + i);
-
- while (*menu_entries)
- {
-- if (j < 71)
-+ if (j < (view_x1 - view_x0) - 9)
- {
-- grub_putchar (*menu_entries);
-+ putchar (*menu_entries);
- j++;
- }
-
-@@ -138,16 +143,16 @@
- if (*(menu_entries - 1))
- menu_entries++;
-
-- for (; j < 71; j++)
-- grub_putchar (' ');
-+ for (; j < (view_x1 - view_x0) - 9; j++)
-+ putchar (' ');
- }
-
-- gotoxy (77, y + size);
-+ gotoxy (view_x0 + 3, y + size);
-
- if (*menu_entries)
-- grub_putchar (disp_down);
-+ putchar (disp_down);
- else
-- grub_putchar (' ');
-+ putchar (' ');
- }
-
-
-@@ -211,10 +216,10 @@
- )
- # endif
- {
-- for (i = 0; i < 14; i++)
-+ for (i = 0; i < 12; i++)
- {
- int j;
-- for (j = 0; j < 75; j++)
-+ for (j = view_x0; j < (view_x1 - view_x0) - 5; j++)
- {
- gotoxy (j + 1, i + y);
- set_attrib (normal_color);
-@@ -223,33 +228,33 @@
- }
- #endif
-
-- gotoxy (1, y);
-+ gotoxy (view_x0 + 1, y);
-
-- grub_putchar (disp_ul);
-- for (i = 0; i < 73; i++)
-- grub_putchar (disp_horiz);
-- grub_putchar (disp_ur);
-+ putchar (disp_ul);
-+ for (i = view_x0; i < view_x1 - 7; i++)
-+ putchar (disp_horiz);
-+ putchar (disp_ur);
-
- i = 1;
-
- while (1)
- {
-- gotoxy (1, y + i);
-+ gotoxy (view_x0 + 1, y + i);
-
- if (i > size)
- break;
-
-- grub_putchar (disp_vert);
-- gotoxy (75, y + i);
-- grub_putchar (disp_vert);
-+ putchar (disp_vert);
-+ gotoxy (view_x1 - 5, y + i);
-+ putchar (disp_vert);
-
- i++;
- }
-
-- grub_putchar (disp_ll);
-- for (i = 0; i < 73; i++)
-- grub_putchar (disp_horiz);
-- grub_putchar (disp_lr);
-+ putchar (disp_ll);
-+ for (i = view_x0; i < view_x1 - 7; i++)
-+ putchar (disp_horiz);
-+ putchar (disp_lr);
- }
-
- static void
-@@ -261,27 +266,27 @@
- if (terminal & TERMINAL_SERIAL)
- {
- menu_entries = get_entry (menu_entries, entryno, 0);
-- gotoxy (2, y);
-- grub_putchar (' ');
-- for (x = 3; x < 75; x++)
-+ gotoxy (view_x0 + 2, y);
-+ putchar (' ');
-+ for (x = view_x0 + 3; x < view_x1 - 5; x++)
- {
-- if (*menu_entries && x < 71)
-- grub_putchar (*menu_entries++);
-+ if (*menu_entries && x < view_x1 - 9)
-+ putchar (*menu_entries++);
- else
-- grub_putchar (' ');
-+ putchar (' ');
- }
- }
- else
- #endif /* SUPPORT_SERIAL */
- {
-- for (x = 2; x < 75; x++)
-+ for (x = view_x0 + 2; x < view_x1 - 5; x++)
- {
- gotoxy (x, y);
- set_attrib (attr);
- }
- }
-
-- gotoxy (74, y);
-+ gotoxy (view_x1 - 6, y);
- }
-
- /* Set the attribute of the line Y to normal state. */
-@@ -334,7 +339,8 @@
- invariant for TERMINAL_DUMB: first_entry == 0 */
- if (! (terminal & TERMINAL_DUMB))
- {
-- while (entryno > 11)
-+ errnum = ERR_NONE;
-+ while (entryno > 9)
- {
- first_entry++;
- entryno--;
-@@ -399,7 +405,7 @@
- #endif /* ! GRUB_UTIL */
-
- if (! (terminal & TERMINAL_DUMB))
-- print_border (3, 12);
-+ print_border (3 + view_y0, 12);
-
- #ifdef GRUB_UTIL
- /* In the grub shell, always use ACS_*. */
-@@ -455,10 +461,10 @@
- grub_printf ("\n\nThe selected entry is %d ", entryno);
- else
- {
-- print_entries (3, 12, first_entry, menu_entries);
-+ print_entries (view_y0 + 3, 12, first_entry, menu_entries);
-
- /* highlight initial line */
-- set_line_highlight (4 + entryno, first_entry + entryno,
-+ set_line_highlight (view_y0 + 4 + entryno, first_entry + entryno,
- menu_entries);
- }
- }
-@@ -487,9 +493,9 @@
- entryno, grub_timeout);
- else
- {
-- gotoxy (3, 22);
-+ gotoxy (view_x0 + 3, view_y1 - 3);
- printf ("The highlighted entry will be booted automatically in %d seconds. ", grub_timeout);
-- gotoxy (74, 4 + entryno);
-+ gotoxy (view_x0 - 6, view_y0 + 4 + entryno);
- }
-
- grub_timeout--;
-@@ -515,12 +521,12 @@
- if (terminal & TERMINAL_DUMB)
- grub_putchar ('\r');
- else
-- gotoxy (3, 22);
-+ gotoxy (view_x0 + 3, 22);
- printf (" ");
- grub_timeout = -1;
- fallback_entry = -1;
- if (! (terminal & TERMINAL_DUMB))
-- gotoxy (74, 4 + entryno);
-+ gotoxy (view_x1 - 6, view_x0 + 4 + entryno);
- }
-
- /* We told them above (at least in SUPPORT_SERIAL) to use
-@@ -536,17 +542,17 @@
- {
- if (entryno > 0)
- {
-- set_line_normal (4 + entryno, first_entry + entryno,
-+ set_line_normal (view_y0 + 4 + entryno, first_entry + entryno,
- menu_entries);
- entryno--;
-- set_line_highlight (4 + entryno, first_entry + entryno,
-+ set_line_highlight (view_y0 + 4 + entryno, first_entry + entryno,
- menu_entries);
- }
- else if (first_entry > 0)
- {
- first_entry--;
-- print_entries (3, 12, first_entry, menu_entries);
-- set_line_highlight (4, first_entry + entryno,
-+ print_entries (view_y0 + 3, 12, first_entry, menu_entries);
-+ set_line_highlight (view_y0 + 4, first_entry + entryno,
- menu_entries);
- }
- }
-@@ -558,17 +564,17 @@
- else
- if (entryno < 11)
- {
-- set_line_normal (4 + entryno, first_entry + entryno,
-+ set_line_normal (view_y0 + 4 + entryno, first_entry + entryno,
- menu_entries);
- entryno++;
-- set_line_highlight (4 + entryno, first_entry + entryno,
-+ set_line_highlight (view_y0 + 4 + entryno, first_entry + entryno,
- menu_entries);
- }
- else if (num_entries > 12 + first_entry)
- {
- first_entry++;
-- print_entries (3, 12, first_entry, menu_entries);
-- set_line_highlight (15, first_entry + entryno, menu_entries);
-+ print_entries (view_y0 + 3, 12, first_entry, menu_entries);
-+ set_line_highlight (view_y0 + 15, first_entry + entryno, menu_entries);
- }
- }
-
-@@ -582,7 +588,7 @@
- if ((c == 'd') || (c == 'o') || (c == 'O'))
- {
- if (! (terminal & TERMINAL_DUMB))
-- set_line_normal (4 + entryno, first_entry + entryno,
-+ set_line_normal (view_y0 + 4 + entryno, first_entry + entryno,
- menu_entries);
-
- /* insert after is almost exactly like insert before */
-@@ -640,8 +646,8 @@
- }
- else
- {
-- print_entries (3, 12, first_entry, menu_entries);
-- set_line_highlight (4 + entryno, first_entry + entryno,
-+ print_entries (view_y0 + 3, 12, first_entry, menu_entries);
-+ set_line_highlight (view_y0 + 4 + entryno, first_entry + entryno,
- menu_entries);
- }
- }
-@@ -664,7 +670,7 @@
- if (terminal & TERMINAL_DUMB)
- grub_printf ("\r ");
- else
-- gotoxy (1, 21);
-+ gotoxy (view_x0 + 1, view_y1 + 21);
-
- /* Wipe out the previously entered password */
- memset (entered, 0, sizeof (entered));
-@@ -811,6 +817,11 @@
- while (1)
- {
- cls ();
-+#ifdef VGA16
-+ if (display->End)
-+ (*display->End)();
-+ display = &display_entries[0];
-+#endif
-
- if (config_entries)
- printf (" Booting \'%s\'\n\n",
-@@ -840,6 +851,16 @@
- break;
- }
-
-+#ifdef VGA16
-+ if (display_idx >= 0)
-+ display = &display_entries[display_idx];
-+ else if (!vga_disabled)
-+ display = &display_entries[1];
-+
-+ if (!display->Begin || !(*display->Begin)())
-+ display = &display_entries[0];
-+#endif
-+
- show_menu = 1;
- goto restart;
- }
-@@ -904,6 +925,560 @@
- return pos;
- }
-
-+#ifdef VGA16
-+struct display_entry display_entries[MAX_DISPLAYS + 1] = {
-+ {"text", 0, 0, grub_cls, grub_gotoxy, grub_putchar, grub_set_attrib,
-+ grub_getxy, grub_nocursor},
-+ {"vga16",
-+ vga16_begin, vga16_end, vga16_cls, vga16_gotoxy, vga16_putchar,
-+ vga16_set_attrib, vga16_getxy, vga16_nocursor},
-+ {0, 0, 0, 0, 0, 0, 0, 0, 0}
-+};
-+struct display_entry *display;
-+int display_idx = -1;
-+
-+/* default vga palette */
-+char vga16pal[16][3] = {
-+ { 0, 0, 0},
-+ { 0, 0, 42},
-+ { 0, 42, 0},
-+ { 0, 42, 42},
-+ {42, 0, 0},
-+ {42, 0, 42},
-+ {42, 21, 0},
-+ {42, 42, 42},
-+ {21, 21, 21},
-+ {21, 21, 63},
-+ {21, 63, 21},
-+ {21, 63, 63},
-+ {63, 21, 21},
-+ {63, 21, 63},
-+ {63, 63, 21},
-+ {63, 63, 63},
-+};
-+
-+int fontx, fonty;
-+unsigned char *font8x16;
-+int saved_videomode, no_scroll = 0, no_cursor = 0, shade = 1, vga_inited = 0;
-+unsigned short text[80 * 30];
-+int foreground = (63 << 16) | (63 << 8) | (63), background = 0, border = 0;
-+int splash_set;
-+char splashimage[64];
-+#define VSHADOW VSHADOW1
-+unsigned char VSHADOW1[38400];
-+unsigned char VSHADOW2[38400];
-+unsigned char VSHADOW4[38400];
-+unsigned char VSHADOW8[38400];
-+
-+static inline void
-+outb(unsigned short port, unsigned char val)
-+{
-+ __asm __volatile ("outb %0,%1"::"a" (val), "d" (port));
-+}
-+
-+static void
-+ModeReg(int value)
-+{
-+ outb(0x3ce, 5);
-+ outb(0x3cf, value);
-+}
-+
-+static void
-+MapMask(int value)
-+{
-+ outb(0x3c4, 2);
-+ outb(0x3c5, value);
-+}
-+
-+/* set/reset register */
-+static void
-+SetRes(int value)
-+{
-+ outb(0x3ce, 0);
-+ outb(0x3cf, value);
-+}
-+
-+/* enable set/reset register */
-+static void
-+ESetRes(int value)
-+{
-+ outb(0x3ce, 1);
-+ outb(0x3cf, value);
-+}
-+
-+static void
-+ReadMap(int value)
-+{
-+ outb(0x3ce, 4);
-+ outb(0x3cf, value);
-+}
-+
-+/* bit mask register */
-+static void
-+BitMask(int value)
-+{
-+ outb(0x3ce, 8);
-+ outb(0x3cf, value);
-+}
-+
-+void
-+grub_memcpy(void *dest, const void *src, int len)
-+{
-+ int i;
-+ register char *d = (char*)dest, *s = (char*)src;
-+
-+ for (i = 0; i < len; i++)
-+ d[i] = s[i];
-+}
-+
-+int
-+hex(int v)
-+{
-+ if (v >= 'A' && v <= 'F')
-+ return (v - 'A' + 10);
-+ if (v >= 'a' && v <= 'f')
-+ return (v - 'a' + 10);
-+ return (v - '0');
-+}
-+
-+static void
-+SetXY(int col, int row)
-+{
-+ if (col >= view_x0 && col < view_x1) {
-+ fontx = col;
-+ cursorX = col << 3;
-+ }
-+ if (row >= view_y0 && row < view_y1) {
-+ fonty = row;
-+ cursorY = row << 4;
-+ }
-+}
-+
-+void
-+cursor(int set)
-+{
-+ unsigned char *pat, *mem, *ptr, chr[16 << 2];
-+ int i, ch, invert, offset;
-+
-+ if (set && (no_cursor || no_scroll))
-+ return;
-+
-+ offset = cursorY * 80 + fontx;
-+ ch = text[fonty * 80 + fontx] & 0xff;
-+ invert = (text[fonty * 80 + fontx] & 0xff00) != 0;
-+ pat = font8x16 + (ch << 4);
-+
-+ mem = (unsigned char*)VIDEO + offset;
-+
-+ if (!set) {
-+ for (i = 0; i < 16; i++) {
-+ unsigned char mask = pat[i];
-+
-+ if (!invert) {
-+ chr[i ] = ((unsigned char*)VSHADOW1)[offset];
-+ chr[16 + i] = ((unsigned char*)VSHADOW2)[offset];
-+ chr[32 + i] = ((unsigned char*)VSHADOW4)[offset];
-+ chr[48 + i] = ((unsigned char*)VSHADOW8)[offset];
-+
-+ if (shade) {
-+ if (ch == DISP_VERT || ch == DISP_LL ||
-+ ch == DISP_UR || ch == DISP_LR) {
-+ unsigned char pmask = ~(pat[i] >> 1);
-+
-+ chr[i ] &= pmask;
-+ chr[16 + i] &= pmask;
-+ chr[32 + i] &= pmask;
-+ chr[48 + i] &= pmask;
-+ }
-+ if (i > 0 && ch != DISP_VERT) {
-+ unsigned char pmask = ~(pat[i - 1] >> 1);
-+
-+ chr[i ] &= pmask;
-+ chr[16 + i] &= pmask;
-+ chr[32 + i] &= pmask;
-+ chr[48 + i] &= pmask;
-+ if (ch == DISP_HORIZ || ch == DISP_UR || ch == DISP_LR) {
-+ pmask = ~pat[i - 1];
-+
-+ chr[i ] &= pmask;
-+ chr[16 + i] &= pmask;
-+ chr[32 + i] &= pmask;
-+ chr[48 + i] &= pmask;
-+ }
-+ }
-+ }
-+ chr[i ] |= mask;
-+ chr[16 + i] |= mask;
-+ chr[32 + i] |= mask;
-+ chr[48 + i] |= mask;
-+
-+ offset += 80;
-+ }
-+ else {
-+ chr[i ] = mask;
-+ chr[16 + i] = mask;
-+ chr[32 + i] = mask;
-+ chr[48 + i] = mask;
-+ }
-+ }
-+ }
-+ else {
-+ MapMask(15);
-+ ptr = mem;
-+ for (i = 0; i < 16; i++, ptr += 80) {
-+ cursorBuf[i] = pat[i];
-+ *ptr = ~pat[i];
-+ }
-+ return;
-+ }
-+
-+ offset = 0;
-+ for (i = 1; i < 16; i <<= 1, offset += 16) {
-+ int j;
-+
-+ MapMask(i);
-+ ptr = mem;
-+ for (j = 0; j < 16; j++, ptr += 80)
-+ *ptr = chr[j + offset];
-+ }
-+
-+ MapMask(15);
-+}
-+
-+int
-+read_image(void)
-+{
-+ char buf[32], pal[16];
-+ unsigned char c, base, mask, *s1, *s2, *s4, *s8;
-+ unsigned i, len, idx, colors, x, y, width, height;
-+
-+ if (!grub_open(splashimage))
-+ return (0);
-+
-+ /* read header */
-+ if (!grub_read((char*)&buf, 10) || grub_memcmp(buf, "/* XPM */\n", 10)) {
-+ grub_close();
-+ return (0);
-+ }
-+
-+ /* parse info */
-+ while (grub_read(&c, 1)) {
-+ if (c == '"')
-+ break;
-+ }
-+
-+ while (grub_read(&c, 1) && (c == ' ' || c == '\t'))
-+ ;
-+
-+ i = 0;
-+ width = c - '0';
-+ while (grub_read(&c, 1)) {
-+ if (c >= '0' && c <= '9')
-+ width = width * 10 + c - '0';
-+ else
-+ break;
-+ }
-+ while (grub_read(&c, 1) && (c == ' ' || c == '\t'))
-+ ;
-+
-+ height = c - '0';
-+ while (grub_read(&c, 1)) {
-+ if (c >= '0' && c <= '9')
-+ height = height * 10 + c - '0';
-+ else
-+ break;
-+ }
-+ while (grub_read(&c, 1) && (c == ' ' || c == '\t'))
-+ ;
-+
-+ colors = c - '0';
-+ while (grub_read(&c, 1)) {
-+ if (c >= '0' && c <= '9')
-+ colors = colors * 10 + c - '0';
-+ else
-+ break;
-+ }
-+
-+ base = 0;
-+ while (grub_read(&c, 1) && c != '"')
-+ ;
-+
-+ /* palette */
-+ for (i = 0, idx = 1; i < colors; i++) {
-+ len = 0;
-+
-+ while (grub_read(&c, 1) && c != '"')
-+ ;
-+ grub_read(&c, 1); /* char */
-+ base = c;
-+ grub_read(buf, 4); /* \t c # */
-+
-+ while (grub_read(&c, 1) && c != '"') {
-+ if (len < sizeof(buf))
-+ buf[len++] = c;
-+ }
-+
-+ if (len == 6 && idx < 15) {
-+ int r = ((hex(buf[0]) << 4) | hex(buf[1])) >> 2;
-+ int g = ((hex(buf[2]) << 4) | hex(buf[3])) >> 2;
-+ int b = ((hex(buf[4]) << 4) | hex(buf[5])) >> 2;
-+
-+ pal[idx] = base;
-+ set_palette(idx, r, g, b);
-+ ++idx;
-+ }
-+ }
-+
-+ x = y = len = 0;
-+
-+ s1 = (unsigned char*)VSHADOW1;
-+ s2 = (unsigned char*)VSHADOW2;
-+ s4 = (unsigned char*)VSHADOW4;
-+ s8 = (unsigned char*)VSHADOW8;
-+
-+ for (i = 0; i < 38400; i++)
-+ s1[i] = s2[i] = s4[i] = s8[i] = 0;
-+
-+ /* parse xpm data */
-+ while (y < height) {
-+ while (1) {
-+ if (!grub_read(&c, 1)) {
-+ grub_close();
-+ return (0);
-+ }
-+ if (c == '"')
-+ break;
-+ }
-+
-+ while (grub_read(&c, 1) && c != '"') {
-+ for (i = 1; i < 15; i++)
-+ if (pal[i] == c) {
-+ c = i;
-+ break;
-+ }
-+
-+ mask = 0x80 >> (x & 7);
-+ if (c & 1)
-+ s1[len + (x >> 3)] |= mask;
-+ if (c & 2)
-+ s2[len + (x >> 3)] |= mask;
-+ if (c & 4)
-+ s4[len + (x >> 3)] |= mask;
-+ if (c & 8)
-+ s8[len + (x >> 3)] |= mask;
-+
-+ if (++x >= 640) {
-+ x = 0;
-+
-+ if (y < 480)
-+ len += 80;
-+ ++y;
-+ }
-+ }
-+ }
-+
-+ grub_close();
-+
-+ set_palette(0, (background >> 16), (background >> 8) & 63, background & 63);
-+ set_palette(15, (foreground >> 16), (foreground >> 8) & 63, foreground & 63);
-+
-+ set_palette(0x11, (border >> 16), (border >> 8) & 63, border & 63);
-+
-+ return (1);
-+}
-+
-+int
-+vga16_begin(void)
-+{
-+ if (vga_inited)
-+ return (1);
-+
-+ if (!*splashimage)
-+ grub_strcpy(splashimage, "/boot/grub/splash.xpm");
-+
-+ saved_videomode = set_videomode(0x12);
-+ if (!read_image()) {
-+ set_videomode(saved_videomode);
-+ return (0);
-+ }
-+
-+ font8x16 = (unsigned char*)get_font();
-+
-+ cursorWidth = 8;
-+ cursorHeight = 16;
-+
-+ set_int1c_handler();
-+
-+ view_x0 = sx0;
-+ view_y0 = sy0;
-+ view_x1 = sx1;
-+ view_y1 = sy1;
-+
-+ return (vga_inited = 1);
-+}
-+
-+void
-+vga16_end(void)
-+{
-+ if (vga_inited) {
-+ unset_int1c_handler();
-+ set_videomode(saved_videomode);
-+ vga_inited = 0;
-+ no_cursor = 0;
-+ }
-+
-+ sx0 = view_x0;
-+ sy0 = view_y0;
-+ sx1 = view_x1;
-+ sy1 = view_y1;
-+ view_x0 = 0;
-+ view_x1 = 80;
-+ view_y0 = 0;
-+ view_y1 = 25;
-+}
-+
-+void
-+vga16_cls(void)
-+{
-+ int i;
-+ unsigned char *mem, *s1, *s2, *s4, *s8;
-+
-+ SetXY(view_x0, view_y0);
-+
-+ mem = (unsigned char*)VIDEO;
-+ s1 = (unsigned char*)VSHADOW1;
-+ s2 = (unsigned char*)VSHADOW2;
-+ s4 = (unsigned char*)VSHADOW4;
-+ s8 = (unsigned char*)VSHADOW8;
-+
-+ for (i = 0; i < 80 * 30; i++)
-+ text[i] = ' ';
-+
-+ BitMask(0xff);
-+
-+ /* plano 1 */
-+ MapMask(1);
-+ grub_memcpy(mem, s1, 38400);
-+
-+ /* plano 2 */
-+ MapMask(2);
-+ grub_memcpy(mem, s2, 38400);
-+
-+ /* plano 3 */
-+ MapMask(4);
-+ grub_memcpy(mem, s4, 38400);
-+
-+ /* plano 4 */
-+ MapMask(8);
-+ grub_memcpy(mem, s8, 38400);
-+
-+ MapMask(15);
-+
-+ if (no_cursor) {
-+ no_cursor = 0;
-+ set_int1c_handler();
-+ }
-+}
-+
-+void
-+vga16_gotoxy(int x, int y)
-+{
-+ cursor(0);
-+
-+ SetXY(x, y);
-+
-+ cursor(1);
-+}
-+
-+static void
-+scroll(void)
-+{
-+ int i, j;
-+
-+ if (no_scroll)
-+ return;
-+
-+ no_scroll = 1;
-+
-+ for (j = view_y0 + 1; j < view_y1; j++) {
-+ gotoxy(view_x0, j - 1);
-+ for (i = view_x0; i < view_x1; i++)
-+ putchar(text[j * 80 + i]);
-+ }
-+
-+ gotoxy(view_x0, view_y1 - 1);
-+ for (i = view_x0; i < view_x1; i++)
-+ putchar(' ');
-+
-+ SetXY(view_x0, view_y1 - 1);
-+
-+ no_scroll = 0;
-+}
-+
-+void
-+vga16_putchar(int ch)
-+{
-+ ch &= 0xff;
-+
-+ cursor(0);
-+
-+ if (ch == '\n') {
-+ SetXY(view_x0, fonty);
-+ if (fonty + 1 < view_y1)
-+ SetXY(view_x0, fonty + 1);
-+ else
-+ scroll();
-+ cursor(1);
-+ return;
-+ }
-+ else if (ch == '\r') {
-+ SetXY(view_x0, fonty);
-+ cursor(1);
-+ return;
-+ }
-+
-+ text[fonty * 80 + fontx] = ch;
-+
-+ cursor(0);
-+
-+ if ((fontx + 1) >= view_x1) {
-+ SetXY(view_x0, fonty);
-+ if (fonty + 1 < view_y1)
-+ SetXY(view_x0, fonty + 1);
-+ else
-+ scroll();
-+ }
-+ else
-+ SetXY(fontx + 1, fonty);
-+
-+ cursor(1);
-+}
-+
-+int
-+vga16_getxy()
-+{
-+ return ((fontx << 8) | fonty);
-+}
-+
-+void
-+vga16_nocursor()
-+{
-+ if (!no_cursor) {
-+ no_cursor = 1;
-+ unset_int1c_handler();
-+ cursor(0);
-+ }
-+}
-+
-+void
-+vga16_set_attrib(int attrib)
-+{
-+ text[fonty * 80 + fontx] &= 0x00ff;
-+ if (attrib & 0xf0)
-+ text[fonty * 80 + fontx] |= 0x100;
-+ cursor(0);
-+}
-+#endif
-
- /* This is the starting function in C. */
- void
-@@ -924,6 +1499,14 @@
- menu_entries = (char *) MENU_BUF;
- init_config ();
- }
-+
-+#ifdef VGA16
-+ /* Make sure it points to a valid entry */
-+ display = &display_entries[0];
-+
-+ if (ASCII_CHAR(checkkey()) == 0x1b)
-+ vga_disabled = 1;
-+#endif
-
- /* Initialize the environment for restarting Stage 2. */
- grub_setjmp (restart_env);
-@@ -1069,6 +1652,29 @@
- while (is_preset);
- }
-
-+#ifdef VGA16
-+ if (display_idx >= 0)
-+ display = &display_entries[display_idx];
-+ else if (!vga_disabled) {
-+ display = &display_entries[1];
-+ }
-+ if (!viewport_set)
-+ view_y1 = 30;
-+ sx0 = view_x0;
-+ sy0 = view_y0;
-+ sx1 = view_x1;
-+ sy1 = view_y1;
-+
-+ if (!display->Begin || !(*display->Begin)())
-+ display = &display_entries[0];
-+
-+ if (!vga_inited) {
-+ sx0 = sy0 = view_x0 = view_y0 = 0;
-+ sx1 = view_x1 = 80;
-+ sy1 = view_y1 = 25;
-+ }
-+#endif
-+
- if (! num_entries)
- {
- /* If no acceptable config file, goto command-line, starting