[PATCH] Configure grub only if it is installed
- Subject: [PATCH] Configure grub only if it is installed
- From: Christian Kastner <ckk@kvr.at>
- Date: Sat, 21 Feb 2015 17:52:56 +0100
---
tools/adt-setup-vm | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/adt-setup-vm b/tools/adt-setup-vm
index 9be5bd5..d978f3f 100755
--- a/tools/adt-setup-vm
+++ b/tools/adt-setup-vm
@@ -127,7 +127,7 @@ if [ -n "${ADT_APT_PROXY:-}" ]; then
fi
# bump vmalloc on i386, necessary for tests like udisks2
-if [ "$(chroot "$root" dpkg --print-architecture)" = "i386" ]; then
+if [ "$(chroot "$root" dpkg --print-architecture)" = "i386" ] && [ -d "$root/etc/default/grub.d" ]; then
echo 'GRUB_CMDLINE_LINUX_DEFAULT="console=ttyS0 vmalloc=512M"' > \
"$root/etc/default/grub.d/90-adt-vmalloc.cfg"
chroot "$root" update-grub
--
2.1.4
Reply to: