From 75ac7671300d0ef911464b3b5b234e7b5f15e4a8 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Wed, 28 Aug 2013 14:24:02 -0700 Subject: [PATCH] feat(update_bootloaders.sh) add UEFI boot support This creates the EFI/BOOT/ directory in the boot partition and copies a version of the kernel into there so that UEFI bioses can boot directly into the kernel, no bootloader needed. --- update_bootloaders.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/update_bootloaders.sh b/update_bootloaders.sh index 2144b180e7..24b2d6e9d9 100755 --- a/update_bootloaders.sh +++ b/update_bootloaders.sh @@ -114,6 +114,11 @@ if [[ "${FLAGS_arch}" = "x86" || "${FLAGS_arch}" = "amd64" ]]; then sudo cp -f "${FLAGS_vmlinuz}" "${ESP_FS_DIR}"/syslinux/vmlinuz.A sudo cp -f "${FLAGS_vmlinuz}" "${ESP_FS_DIR}"/syslinux/vmlinuz.B + # create the EFI directory tree as a fall-back for UEFI builds and put a copy + # of the kernel in there. + sudo mkdir -p "${ESP_FS_DIR}"/EFI/boot + sudo cp -f "${FLAGS_vmlinuz}" "${ESP_FS_DIR}"/EFI/boot/bootx64.efi + # Extract kernel flags kernel_cfg="cros_debug" old_root="%U+1"