Merge "Handle non-script grub2-install"

This commit is contained in:
Jenkins 2014-07-25 19:52:33 +00:00 committed by Gerrit Code Review
commit 42bb303005

View File

@ -42,9 +42,9 @@ function install_grub2 {
# XXX: grub-probe on the nbd0/loop0 device returns nothing - workaround, manually # XXX: grub-probe on the nbd0/loop0 device returns nothing - workaround, manually
# specify modules. https://bugs.launchpad.net/ubuntu/+source/grub2/+bug/1073731 # specify modules. https://bugs.launchpad.net/ubuntu/+source/grub2/+bug/1073731
GRUBNAME=`which grub-install` || echo "trying grub2-install" GRUBNAME=$(which grub-install) || echo "trying grub2-install"
if [ -z "$GRUBNAME" ]; then if [ -z "$GRUBNAME" ]; then
GRUBNAME="bash -x `which grub2-install`" GRUBNAME=$(which grub2-install)
fi fi
# If no GRUB2 is found, fallback to extlinux # If no GRUB2 is found, fallback to extlinux