From 63d164b755b984021f7e3cdba7280918ded6e821 Mon Sep 17 00:00:00 2001 From: Jason Wessel Date: Tue, 17 Sep 2013 13:32:17 +0000 Subject: boot-directdisk.bbclass: Fix media generation problems with vmdk The various populate methods need to accept a path as an argument vs using hard expanded variables. In the case of the boot-directdisk class it uses a different path for HDDDIR but it gets eclipsed by the the class definition at the point in time ${HDDDIR} gets expanded. The logical fix is to pass the arguments to the functions as opposed to using globally expanded variables from the class definitions. This patch changes 3 things: 1) syslinux_hddimg_populate takes an argument for the destination 2) syslinux_iso_populate takes an argument for the destination 3) populate is changed to boot_direct_populate because there was a conflict with it overriding the populate in bootimg.bbclass [YOCTO #3994] Signed-off-by: Jason Wessel Signed-off-by: Saul Wold Signed-off-by: Richard Purdie --- meta/classes/boot-directdisk.bbclass | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'meta/classes/boot-directdisk.bbclass') diff --git a/meta/classes/boot-directdisk.bbclass b/meta/classes/boot-directdisk.bbclass index 4b9d7bd128..c58c6f0c53 100644 --- a/meta/classes/boot-directdisk.bbclass +++ b/meta/classes/boot-directdisk.bbclass @@ -61,15 +61,15 @@ DISK_SIGNATURE ?= "${DISK_SIGNATURE_GENERATED}" SYSLINUX_ROOT ?= "root=/dev/sda2" SYSLINUX_TIMEOUT ?= "10" -populate() { - DEST=$1 - install -d ${DEST} +boot_direct_populate() { + dest=$1 + install -d $dest # Install bzImage, initrd, and rootfs.img in DEST for all loaders to use. - install -m 0644 ${STAGING_KERNEL_DIR}/bzImage ${DEST}/vmlinuz + install -m 0644 ${STAGING_KERNEL_DIR}/bzImage $dest/vmlinuz if [ -n "${INITRD}" ] && [ -s "${INITRD}" ]; then - install -m 0644 ${INITRD} ${DEST}/initrd + install -m 0644 ${INITRD} $dest/initrd fi } @@ -79,13 +79,13 @@ build_boot_dd() { HDDIMG="${S}/hdd.image" IMAGE=${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.hdddirect - populate ${HDDDIR} + boot_direct_populate $HDDDIR if [ "${PCBIOS}" = "1" ]; then - syslinux_hddimg_populate + syslinux_hddimg_populate $HDDDIR fi if [ "${EFI}" = "1" ]; then - grubefi_hddimg_populate + grubefi_hddimg_populate $HDDDIR fi BLOCKS=`du -bks $HDDDIR | cut -f 1` -- cgit 1.2.3-korg