aboutsummaryrefslogtreecommitdiffstats
path: root/meta/classes
diff options
context:
space:
mode:
authorMartin Jansa <martin.jansa@gmail.com>2016-10-12 14:06:12 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-10-15 09:55:34 +0100
commite6b21d1b3716ee6f4aec1674e56f06b2963a7968 (patch)
tree9cd4b3f876ac09b3ec338120927bf5cc6bf6166e /meta/classes
parent1a961b4becf677c9eb07c5b24a8ddb75044663d1 (diff)
downloadopenembedded-core-e6b21d1b3716ee6f4aec1674e56f06b2963a7968.tar.gz
live-vm-common.bbclass: Allow to use different kernel image than KERNEL_IMAGETYPE for /vmlinuz
* syslinux config hardcodes kernel image as /vmlinuz add warning message when the selected image doesn't exist and allow to select different image with VM_DEFAULT_KERNEL variable (qemuboot.bbclass is using QB_DEFAULT_KERNEL) Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Diffstat (limited to 'meta/classes')
-rw-r--r--meta/classes/live-vm-common.bbclass8
1 files changed, 6 insertions, 2 deletions
diff --git a/meta/classes/live-vm-common.bbclass b/meta/classes/live-vm-common.bbclass
index c751385e7d..734697f9e6 100644
--- a/meta/classes/live-vm-common.bbclass
+++ b/meta/classes/live-vm-common.bbclass
@@ -31,14 +31,18 @@ inherit ${EFI_CLASS}
inherit ${PCBIOS_CLASS}
KERNEL_IMAGETYPE ??= "bzImage"
+VM_DEFAULT_KERNEL ??= "${KERNEL_IMAGETYPE}"
populate_kernel() {
dest=$1
install -d $dest
# Install bzImage, initrd, and rootfs.img in DEST for all loaders to use.
- if [ -e ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE} ]; then
- install -m 0644 ${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE} $dest/vmlinuz
+ bbnote "Trying to install ${DEPLOY_DIR_IMAGE}/${VM_DEFAULT_KERNEL} as $dest/vmlinuz"
+ if [ -e ${DEPLOY_DIR_IMAGE}/${VM_DEFAULT_KERNEL} ]; then
+ install -m 0644 ${DEPLOY_DIR_IMAGE}/${VM_DEFAULT_KERNEL} $dest/vmlinuz
+ else
+ bbwarn "${DEPLOY_DIR_IMAGE}/${VM_DEFAULT_KERNEL} doesn't exist"
fi
# initrd is made of concatenation of multiple filesystem images