diff options
Diffstat (limited to 'meta/classes/grub-efi.bbclass')
-rw-r--r-- | meta/classes/grub-efi.bbclass | 20 |
1 files changed, 4 insertions, 16 deletions
diff --git a/meta/classes/grub-efi.bbclass b/meta/classes/grub-efi.bbclass index ec692f1646..724bbe8684 100644 --- a/meta/classes/grub-efi.bbclass +++ b/meta/classes/grub-efi.bbclass | |||
@@ -1,4 +1,5 @@ | |||
1 | inherit grub-efi-cfg | 1 | inherit grub-efi-cfg |
2 | require conf/image-uefi.conf | ||
2 | 3 | ||
3 | efi_populate() { | 4 | efi_populate() { |
4 | # DEST must be the root of the image so that EFIDIR is not | 5 | # DEST must be the root of the image so that EFIDIR is not |
@@ -7,22 +8,9 @@ efi_populate() { | |||
7 | 8 | ||
8 | install -d ${DEST}${EFIDIR} | 9 | install -d ${DEST}${EFIDIR} |
9 | 10 | ||
10 | GRUB_IMAGE="grub-efi-bootia32.efi" | 11 | install -m 0644 ${DEPLOY_DIR_IMAGE}/grub-efi-${EFI_BOOT_IMAGE} ${DEST}${EFIDIR}/${EFI_BOOT_IMAGE} |
11 | DEST_IMAGE="bootia32.efi" | ||
12 | if [ -n "${MLPREFIX}" ]; then | ||
13 | if [ "${TARGET_ARCH_MULTILIB_ORIGINAL}" = "x86_64" ]; then | ||
14 | GRUB_IMAGE="grub-efi-bootx64.efi" | ||
15 | DEST_IMAGE="bootx64.efi" | ||
16 | fi | ||
17 | else | ||
18 | if [ "${TARGET_ARCH}" = "x86_64" ]; then | ||
19 | GRUB_IMAGE="grub-efi-bootx64.efi" | ||
20 | DEST_IMAGE="bootx64.efi" | ||
21 | fi | ||
22 | fi | ||
23 | install -m 0644 ${DEPLOY_DIR_IMAGE}/${GRUB_IMAGE} ${DEST}${EFIDIR}/${DEST_IMAGE} | ||
24 | EFIPATH=$(echo "${EFIDIR}" | sed 's/\//\\/g') | 12 | EFIPATH=$(echo "${EFIDIR}" | sed 's/\//\\/g') |
25 | printf 'fs0:%s\%s\n' "$EFIPATH" "$DEST_IMAGE" >${DEST}/startup.nsh | 13 | printf 'fs0:%s\%s\n' "$EFIPATH" "${EFI_BOOT_IMAGE}" >${DEST}/startup.nsh |
26 | 14 | ||
27 | install -m 0644 ${GRUB_CFG} ${DEST}${EFIDIR}/grub.cfg | 15 | install -m 0644 ${GRUB_CFG} ${DEST}${EFIDIR}/grub.cfg |
28 | } | 16 | } |
@@ -35,7 +23,7 @@ efi_iso_populate() { | |||
35 | cp $iso_dir/${EFIDIR}/* ${EFIIMGDIR}${EFIDIR} | 23 | cp $iso_dir/${EFIDIR}/* ${EFIIMGDIR}${EFIDIR} |
36 | cp $iso_dir/${KERNEL_IMAGETYPE} ${EFIIMGDIR} | 24 | cp $iso_dir/${KERNEL_IMAGETYPE} ${EFIIMGDIR} |
37 | EFIPATH=$(echo "${EFIDIR}" | sed 's/\//\\/g') | 25 | EFIPATH=$(echo "${EFIDIR}" | sed 's/\//\\/g') |
38 | printf 'fs0:%s\%s\n' "$EFIPATH" "$GRUB_IMAGE" > ${EFIIMGDIR}/startup.nsh | 26 | printf 'fs0:%s\%s\n' "$EFIPATH" "grub-efi-${EFI_BOOT_IMAGE}" > ${EFIIMGDIR}/startup.nsh |
39 | if [ -f "$iso_dir/initrd" ] ; then | 27 | if [ -f "$iso_dir/initrd" ] ; then |
40 | cp $iso_dir/initrd ${EFIIMGDIR} | 28 | cp $iso_dir/initrd ${EFIIMGDIR} |
41 | fi | 29 | fi |