x86.tmpl: add eltorito alt boot entry for macboot.img

This should allow us to boot the created image on Apple EFI systems.
This commit is contained in:
Will Woods 2011-10-31 14:59:35 -04:00
parent f1ff48243d
commit 1ec2fe9fbd

View File

@ -50,8 +50,10 @@ hardlink ${KERNELDIR}/initrd.img ${BOOTDIR}
%if exists("boot/efi/EFI/redhat/grub.efi") and basearch != 'i386':
<%
efiarch = 'X64' if basearch=='x86_64' else 'IA32'
efiargs="-eltorito-alt-boot -e images/efiboot.img -no-emul-boot"
efigraft="EFI/BOOT={0}/EFI/BOOT images/efiboot.img={0}/images/efiboot.img".format(outroot)
efigraft="EFI/BOOT={0}/EFI/BOOT".format(outroot)
for img in ("images/efiboot.img", "images/macboot.img"):
efiargs += " -eltorito-alt-boot -e {0} -no-emul-boot".format(img)
efigraft += " {0}={1}/{0}".format(img,outroot)
efihybrid="-u"
%>
<%include file="efi.tmpl" args="configdir=configdir, KERNELDIR=KERNELDIR, efiarch=efiarch"/>