mirror of
https://github.com/flatcar/scripts.git
synced 2025-09-27 16:41:11 +02:00
Enhance build_image to support new grub2 1.99+
BUG=chromium-os:21244 TEST=./build_image works with both old and new grub Change-Id: Idca80f777b7da72da1690bc374a156f910d487b0 Reviewed-on: https://gerrit.chromium.org/gerrit/11876 Reviewed-by: Bill Richardson <wfrichar@chromium.org> Tested-by: Anush Elangovan <anush@chromium.org> Commit-Ready: Anush Elangovan <anush@chromium.org>
This commit is contained in:
parent
7f48fbd72c
commit
2d7d6fd17b
@ -146,8 +146,17 @@ EOF
|
||||
|
||||
# To cover all of our bases, now populate templated boot support for efi.
|
||||
sudo mkdir -p "${FLAGS_to}"/efi/boot
|
||||
sudo grub-mkimage -p /efi/boot -o "${FLAGS_to}/efi/boot/bootx64.efi" \
|
||||
part_gpt fat ext2 normal boot sh chain configfile linux
|
||||
|
||||
if [[ -f /bin/grub2-mkimage ]];then
|
||||
# Use the newer grub2 1.99+
|
||||
sudo grub2-mkimage -p /efi/boot -O x86_64-efi \
|
||||
-o "${FLAGS_to}/efi/boot/bootx64.efi" \
|
||||
part_gpt fat ext2 hfs hfsplus normal boot chain configfile linux
|
||||
else
|
||||
# Remove this else case after a few weeks (sometime in Dec 2011)
|
||||
sudo grub-mkimage -p /efi/boot -o "${FLAGS_to}/efi/boot/bootx64.efi" \
|
||||
part_gpt fat ext2 normal boot sh chain configfile linux
|
||||
fi
|
||||
# Templated variables:
|
||||
# DMTABLEA, DMTABLEB -> '0 xxxx verity ... '
|
||||
# This should be replaced during postinst when updating the ESP.
|
||||
|
Loading…
x
Reference in New Issue
Block a user