grub-efi, gummiboot: Emit correct path in startup.nsh
PATCH 1/1 grub-efi, gummiboot: Emit correct path in startup.nsh
when we generate hddimage and use it to prepare SD card using scripts/contrib/mkefidisk.sh as described here
http://elinux.org/Minnowboard:MinnowMaxYoctoProject
The content of startup.nsh contains
bootx64.efi
but this file is actually not in same dir as startup.nsh its in /EFI/BOOT so for this to work entry in startup.nsh should be
fs0:\EFI\BOOT\bootx64.efi
Otherwise the image is D-O-A
Signed-off-by Khem Raj <[email protected]>
--- meta/classes/grub-efi.bbclass | 3 ++- meta/classes/gummiboot.bbclass | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-)
meta/classes/grub-efi.bbclass +2 -1
@@ -52,7 +52,8 @@ efi_iso_populate() { mkdir -p ${EFIIMGDIR}/${EFIDIR} cp $iso_dir/${EFIDIR}/* ${EFIIMGDIR}${EFIDIR} cp $iso_dir/vmlinuz ${EFIIMGDIR} - echo "${GRUB_IMAGE}" > ${EFIIMGDIR}/startup.nsh + EFIPATH=$(echo "${EFIDIR}" | sed 's/\//\\/g') + echo "fs0:${EFIPATH}\\${GRUB_IMAGE}" > ${EFIIMGDIR}/startup.nsh if [ -f "$iso_dir/initrd" ] ; then cp $iso_dir/initrd ${EFIIMGDIR} fi
meta/classes/gummiboot.bbclass +2 -1
@@ -46,7 +46,8 @@ efi_iso_populate() { mkdir -p ${EFIIMGDIR}/${EFIDIR} cp $iso_dir/${EFIDIR}/* ${EFIIMGDIR}${EFIDIR} cp $iso_dir/vmlinuz ${EFIIMGDIR} - echo "${DEST_EFI_IMAGE}" > ${EFIIMGDIR}/startup.nsh + EFIPATH=$(echo "${EFIDIR}" | sed 's/\//\\/g') + echo "fs0:${EFIPATH}\\${DEST_EFI_IMAGE}" > ${EFIIMGDIR}/startup.nsh if [ -f "$iso_dir/initrd" ] ; then cp $iso_dir/initrd ${EFIIMGDIR} fi
Signature · 1 line
2.6.1