For EFI, hardcode the partition number in the core image's prefix.
This commit is contained in:
parent
6ed71f4831
commit
fdff6f0be9
1 changed files with 5 additions and 0 deletions
|
@ -498,6 +498,7 @@ if [ "x${devabstraction_module}" = "x" ] ; then
|
||||||
grub_drive="`$grub_probe --target=drive --device ${grub_device}`" || exit 1
|
grub_drive="`$grub_probe --target=drive --device ${grub_device}`" || exit 1
|
||||||
|
|
||||||
# Strip partition number
|
# Strip partition number
|
||||||
|
grub_partition="`echo ${grub_drive} | sed -e 's/^[^,]*,//; s/)$//'`"
|
||||||
grub_drive="`echo ${grub_drive} | sed -e s/,[a-z0-9,]*//g`"
|
grub_drive="`echo ${grub_drive} | sed -e s/,[a-z0-9,]*//g`"
|
||||||
if [ "$disk_module" = ata ] ; then
|
if [ "$disk_module" = ata ] ; then
|
||||||
# generic method (used on coreboot and ata mod)
|
# generic method (used on coreboot and ata mod)
|
||||||
|
@ -520,6 +521,10 @@ if [ "x${devabstraction_module}" = "x" ] ; then
|
||||||
echo 'set prefix=($root)'"${relative_grubdir}" >> ${grubdir}/load.cfg
|
echo 'set prefix=($root)'"${relative_grubdir}" >> ${grubdir}/load.cfg
|
||||||
config_opt="-c ${grubdir}/load.cfg "
|
config_opt="-c ${grubdir}/load.cfg "
|
||||||
modules="$modules search_fs_uuid"
|
modules="$modules search_fs_uuid"
|
||||||
|
elif [ "x$platform" = xefi ]; then
|
||||||
|
# No grub-setup, so we need to hardcode the partition number in the
|
||||||
|
# core image's prefix.
|
||||||
|
prefix_drive="(,$grub_partition)"
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
prefix_drive=`$grub_probe --target=drive --device ${grub_device}` || exit 1
|
prefix_drive=`$grub_probe --target=drive --device ${grub_device}` || exit 1
|
||||||
|
|
Loading…
Reference in a new issue