diff options
author | nwhitehorn <nwhitehorn@FreeBSD.org> | 2014-07-02 15:23:13 +0000 |
---|---|---|
committer | nwhitehorn <nwhitehorn@FreeBSD.org> | 2014-07-02 15:23:13 +0000 |
commit | 56276a9f5228a6d02a3e579a4f51b9b1e0d68e7b (patch) | |
tree | 22d2c8991f3e809110ce966ec00fe690c5529a22 /release/amd64/mkisoimages.sh | |
parent | 833365590a1e25d740e7038dfcd0228baa905d5b (diff) | |
download | FreeBSD-src-56276a9f5228a6d02a3e579a4f51b9b1e0d68e7b.zip FreeBSD-src-56276a9f5228a6d02a3e579a4f51b9b1e0d68e7b.tar.gz |
Now that GENERIC can boot on UEFI systems (r268158), switch the build to use
UEFI-compatible images. These will boot as before on BIOS systems, but will
boot using the UEFI loader on UEFI-aware systems.
Diffstat (limited to 'release/amd64/mkisoimages.sh')
-rw-r--r-- | release/amd64/mkisoimages.sh | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/release/amd64/mkisoimages.sh b/release/amd64/mkisoimages.sh index e4093d7..2b89d89 100644 --- a/release/amd64/mkisoimages.sh +++ b/release/amd64/mkisoimages.sh @@ -26,6 +26,20 @@ if [ "x$1" = "x-b" ]; then # This is highly x86-centric and will be used directly below. bootable="-o bootimage=i386;$4/boot/cdboot -o no-emul-boot" + + # Make EFI system partition (should be done with makefs in the future) + dd if=/dev/zero of=efiboot.img bs=4k count=100 + device=`mdconfig -a -t vnode -f efiboot.img` + newfs_msdos -F 12 -m 0xf8 /dev/$device + mkdir efi + mount -t msdosfs /dev/$device efi + mkdir -p efi/efi/boot + cp ${4}/boot/loader.efi efi/efi/boot/bootx64.efi + umount efi + rmdir efi + mdconfig -d -u $device + bootable="-o bootimage=i386;efiboot.img -o no-emul-boot $bootable" + shift else bootable="" @@ -43,3 +57,4 @@ publisher="The FreeBSD Project. http://www.FreeBSD.org/" echo "/dev/iso9660/$LABEL / cd9660 ro 0 0" > $1/etc/fstab makefs -t cd9660 $bootable -o rockridge -o label=$LABEL -o publisher="$publisher" $NAME $* rm $1/etc/fstab +rm -f efiboot.img |