X-Git-Url: https://git.grml.org/?p=grml-debootstrap.git;a=blobdiff_plain;f=chroot-script;h=a06aa7e9d422d1b26be498fc795b07f16c840f4e;hp=1a74aef6be2550296f3d6057429ef1c17b0362e2;hb=c7c6cfd5ea3dcdfe0c2b627f8e1d698f819a79e4;hpb=5adf8f682756357f82f26b7400b1c140f1924bcf diff --git a/chroot-script b/chroot-script index 1a74aef..a06aa7e 100755 --- a/chroot-script +++ b/chroot-script @@ -575,7 +575,16 @@ grub_install() { done else echo "Installing grub on ${GRUB}:" - grub-install --no-floppy "$GRUB" + case "$RELEASE" in + lenny|squeeze|wheezy) + grub-install --no-floppy "$(readlink -f "${GRUB}")" + ;; + *) + echo "(hd0) ${GRUB}" > /boot/grub/device.map + grub-install "(hd0)" + rm /boot/grub/device.map + ;; + esac fi echo "Adjusting grub configuration for use on ${GRUB}."