From 4ad3130c20bfb4eac7c1fd4eedb7d10e49c364c9 Mon Sep 17 00:00:00 2001 From: Dmitry Eremin-Solenikov Date: Wed, 18 Sep 2019 16:12:47 +0300 Subject: live-vm-common.bbclass: provide efi population functions for live images Define common functions for populating EFI directories in live image by reusing common code from grub-efi and systemd-boot bbclasses. (From OE-Core rev: 3728899a0cd543793db258da0976362b4bde7133) Signed-off-by: Dmitry Eremin-Solenikov Signed-off-by: Richard Purdie --- meta/classes/grub-efi.bbclass | 28 +--------------------------- 1 file changed, 1 insertion(+), 27 deletions(-) (limited to 'meta/classes/grub-efi.bbclass') diff --git a/meta/classes/grub-efi.bbclass b/meta/classes/grub-efi.bbclass index 724bbe8684..8fc6999e52 100644 --- a/meta/classes/grub-efi.bbclass +++ b/meta/classes/grub-efi.bbclass @@ -2,33 +2,7 @@ inherit grub-efi-cfg require conf/image-uefi.conf efi_populate() { - # DEST must be the root of the image so that EFIDIR is not - # nested under a top level directory. - DEST=$1 - - install -d ${DEST}${EFIDIR} - - install -m 0644 ${DEPLOY_DIR_IMAGE}/grub-efi-${EFI_BOOT_IMAGE} ${DEST}${EFIDIR}/${EFI_BOOT_IMAGE} - EFIPATH=$(echo "${EFIDIR}" | sed 's/\//\\/g') - printf 'fs0:%s\%s\n' "$EFIPATH" "${EFI_BOOT_IMAGE}" >${DEST}/startup.nsh + efi_populate_common "$1" grub-efi install -m 0644 ${GRUB_CFG} ${DEST}${EFIDIR}/grub.cfg } - -efi_iso_populate() { - iso_dir=$1 - efi_populate $iso_dir - # Build a EFI directory to create efi.img - mkdir -p ${EFIIMGDIR}/${EFIDIR} - cp $iso_dir/${EFIDIR}/* ${EFIIMGDIR}${EFIDIR} - cp $iso_dir/${KERNEL_IMAGETYPE} ${EFIIMGDIR} - EFIPATH=$(echo "${EFIDIR}" | sed 's/\//\\/g') - printf 'fs0:%s\%s\n' "$EFIPATH" "grub-efi-${EFI_BOOT_IMAGE}" > ${EFIIMGDIR}/startup.nsh - if [ -f "$iso_dir/initrd" ] ; then - cp $iso_dir/initrd ${EFIIMGDIR} - fi -} - -efi_hddimg_populate() { - efi_populate $1 -} -- cgit v1.2.3-54-g00ecf