From f05ae5f57d9d1bd839fae0e3f353d4e0e303a183 Mon Sep 17 00:00:00 2001 From: Valentin Popa Date: Fri, 27 Sep 2013 15:34:24 +0300 Subject: image types: split live into iso and hddimg Changes to split live into iso and hddimg without adding a new image type class. This patch has only a visible effect on HOB and solves part 2 of #3197 [YOCTO #3197] Signed-off-by: Valentin Popa Signed-off-by: Richard Purdie --- meta/classes/image.bbclass | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'meta/classes/image.bbclass') diff --git a/meta/classes/image.bbclass b/meta/classes/image.bbclass index 7650594f8c..422a8261bd 100644 --- a/meta/classes/image.bbclass +++ b/meta/classes/image.bbclass @@ -90,7 +90,17 @@ do_rootfs[depends] += "makedevs-native:do_populate_sysroot virtual/fakeroot-nati do_rootfs[depends] += "virtual/update-alternatives-native:do_populate_sysroot update-rc.d-native:do_populate_sysroot" do_rootfs[recrdeptask] += "do_packagedata" -IMAGE_TYPE_live = '${@base_contains("IMAGE_FSTYPES", "live", "live", "empty", d)}' +def build_live(d): + if base_contains("IMAGE_FSTYPES", "live", "live", "0", d) == "0": # live is not set but hob might set iso or hddimg + d.setVar('NOISO', base_contains('IMAGE_FSTYPES', "iso", "0", "1", d)) + d.setVar('NOHDD', base_contains('IMAGE_FSTYPES', "hddimg", "0", "1", d)) + if d.getVar('NOISO', True) == "0" or d.getVar('NOHDD', True) == "0": + return "live" + return "empty" + return "live" + +IMAGE_TYPE_live = "${@build_live(d)}" + inherit image-${IMAGE_TYPE_live} IMAGE_TYPE_vmdk = '${@base_contains("IMAGE_FSTYPES", "vmdk", "vmdk", "empty", d)}' inherit image-${IMAGE_TYPE_vmdk} -- cgit v1.2.3