From 13eaa40e5ead14d21a3ee61648a045369103f240 Mon Sep 17 00:00:00 2001 From: Ian Wienand Date: Tue, 15 Jul 2014 10:41:35 +1000 Subject: [PATCH] Handle non-script grub2-install grub2-install has been re-written [1] so isn't always a shell script, so just exec it directly. Also use $() as that follows the rest of the file. [1] http://git.savannah.gnu.org/cgit/grub.git/commit?id=cd46aa6cefabd7b0fcb15cd614577e1ab8c7a841 Change-Id: Ib4fd7c6854fb485c0da6a79babf4a3d45a8a0f2c --- elements/vm/finalise.d/51-bootloader | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/elements/vm/finalise.d/51-bootloader b/elements/vm/finalise.d/51-bootloader index c1a40d4a..250982f2 100755 --- a/elements/vm/finalise.d/51-bootloader +++ b/elements/vm/finalise.d/51-bootloader @@ -42,9 +42,9 @@ function install_grub2 { # XXX: grub-probe on the nbd0/loop0 device returns nothing - workaround, manually # 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 - GRUBNAME="bash -x `which grub2-install`" + GRUBNAME=$(which grub2-install) fi # If no GRUB2 is found, fallback to extlinux