summaryrefslogtreecommitdiff
path: root/util/grub-mkconfig.in
diff options
context:
space:
mode:
authorBVK Chaitanya <bvk.groups@gmail.com>2010-09-19 08:45:38 +0530
committerBVK Chaitanya <bvk.groups@gmail.com>2010-09-19 08:45:38 +0530
commit7431d7a49cf2ae9750244489537e9566fd7d58c9 (patch)
tree8e2342accaebe55d335f58064a811c47bf1d261c /util/grub-mkconfig.in
parent75d8c629fc17944e9696ff9c34d466c5d3fce1a8 (diff)
parent75831c341920a08becbc6f11da17d057822e19be (diff)
merge with mainline
Diffstat (limited to 'util/grub-mkconfig.in')
-rw-r--r--util/grub-mkconfig.in19
1 files changed, 5 insertions, 14 deletions
diff --git a/util/grub-mkconfig.in b/util/grub-mkconfig.in
index 3233043c8..145143a4b 100644
--- a/util/grub-mkconfig.in
+++ b/util/grub-mkconfig.in
@@ -38,6 +38,8 @@ self=`basename $0`
grub_mkdevicemap=${sbindir}/`echo grub-mkdevicemap | sed ${transform}`
grub_probe=${sbindir}/`echo grub-probe | sed ${transform}`
+GRUB_PREFIX=`echo '/@bootdirname@/@grubdirname@' | sed "s,//*,/,g"`
+
# Usage: usage
# Print the usage.
usage () {
@@ -93,18 +95,6 @@ done
. ${libdir}/grub/grub-mkconfig_lib
-case "$host_os" in
-netbsd* | openbsd*)
- # Because /boot is used for the boot block in NetBSD and OpenBSD, use /grub
- # instead of /boot/grub.
- GRUB_PREFIX=`echo /grub | sed ${transform}`
- ;;
-*)
- # Use /boot/grub by default.
- GRUB_PREFIX=`echo /boot/grub | sed ${transform}`
- ;;
-esac
-
if [ "x$EUID" = "x" ] ; then
EUID=`id -u`
fi
@@ -158,7 +148,7 @@ GRUB_DEVICE_BOOT_UUID="`${grub_probe} --device ${GRUB_DEVICE_BOOT} --target=fs_u
# Filesystem for the device containing our userland. Used for stuff like
# choosing Hurd filesystem module.
-GRUB_FS="`${grub_probe} --target=fs / 2> /dev/null || echo unknown`"
+GRUB_FS="`${grub_probe} --device ${GRUB_DEVICE} --target=fs 2> /dev/null || echo unknown`"
if test -f ${sysconfdir}/default/grub ; then
. ${sysconfdir}/default/grub
@@ -200,7 +190,7 @@ for x in ${GRUB_TERMINAL_OUTPUT}; do
exit 1
fi
else
- for dir in ${pkgdatadir} /boot/grub /usr/share/grub ; do
+ for dir in ${pkgdatadir} ${GRUB_PREFIX} /usr/share/grub ; do
for basename in unicode unifont ascii; do
path="${dir}/${basename}.pf2"
if is_path_readable_by_grub ${path} > /dev/null ; then
@@ -255,6 +245,7 @@ export GRUB_DEFAULT \
GRUB_HIDDEN_TIMEOUT_BUTTON \
GRUB_TIMEOUT_BUTTON \
GRUB_BUTTON_CMOS_ADDRESS \
+ GRUB_BUTTON_CMOS_CLEAN \
GRUB_DISTRIBUTOR \
GRUB_CMDLINE_LINUX \
GRUB_CMDLINE_LINUX_DEFAULT \