Support for newer grub-common package.

A recent change in grub-common package (#584415) has mandated
the use of a destination format in calls to grub-mkimage, a
parameter that was not previously supported.
This commit is contained in:
Luigi Capriotti 2011-01-17 09:55:29 +01:00 committed by Daniel Baumann
parent 2ddc0cef5d
commit 218610081a
1 changed files with 8 additions and 1 deletions

View File

@ -163,7 +163,14 @@ input_dir=/usr/lib/grub/i386-pc
# build core.img
core_img=\$(mktemp)
grub-mkimage -d \${input_dir} -o \${core_img} biosdisk iso9660
# first version requiring -O is 1.98+20100527, see #584415
if [ "$(grub-mkimage --help | grep '\-O')" ]
then
grub-mkimage -d \${input_dir} -o \${core_img} -O i386-pc biosdisk iso9660
else
grub-mkimage -d \${input_dir} -o \${core_img} biosdisk iso9660
fi
# build grub_eltorito image
cat \${input_dir}/cdboot.img \${core_img} > binary/boot/grub/grub_eltorito