]> code.ossystems Code Review - openembedded-core.git/commitdiff
meta: Convert IMAGE_TYPEDEP to use override syntax
authorRichard Purdie <richard.purdie@linuxfoundation.org>
Wed, 4 Aug 2021 10:34:00 +0000 (11:34 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Wed, 4 Aug 2021 19:41:46 +0000 (20:41 +0100)
The IMAGE_TYPEDEP variable would make more sense to match the form of the
other image override variables, convert it to use the overrides format.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/image-container.bbclass
meta/classes/image-live.bbclass
meta/classes/image.bbclass
meta/classes/image_types.bbclass
meta/lib/oeqa/selftest/cases/containerimage.py
meta/lib/oeqa/selftest/cases/image_typedep.py
scripts/contrib/convert-overrides.py

index f002858bd242ea80ed9f5dae093554caa410212a..3d1993576a071e1e789d795e4006fe43a5143f81 100644 (file)
@@ -1,6 +1,6 @@
 ROOTFS_BOOTSTRAP_INSTALL = ""
 IMAGE_TYPES_MASKED += "container"
-IMAGE_TYPEDEP_container = "tar.bz2"
+IMAGE_TYPEDEP:container = "tar.bz2"
 
 python __anonymous() {
     if "container" in d.getVar("IMAGE_FSTYPES") and \
index fd876ed8e1cd00561b340016ca2194299ddd92a4..2c948190cfe04c0fcfdd6446302867a0b1bdfa75 100644 (file)
@@ -42,9 +42,9 @@ INITRD_LIVE ?= "${DEPLOY_DIR_IMAGE}/${INITRD_IMAGE_LIVE}-${MACHINE}.${INITRAMFS_
 LIVE_ROOTFS_TYPE ?= "ext4"
 ROOTFS ?= "${IMGDEPLOYDIR}/${IMAGE_LINK_NAME}.${LIVE_ROOTFS_TYPE}"
 
-IMAGE_TYPEDEP_live = "${LIVE_ROOTFS_TYPE}"
-IMAGE_TYPEDEP_iso = "${LIVE_ROOTFS_TYPE}"
-IMAGE_TYPEDEP_hddimg = "${LIVE_ROOTFS_TYPE}"
+IMAGE_TYPEDEP:live = "${LIVE_ROOTFS_TYPE}"
+IMAGE_TYPEDEP:iso = "${LIVE_ROOTFS_TYPE}"
+IMAGE_TYPEDEP:hddimg = "${LIVE_ROOTFS_TYPE}"
 IMAGE_TYPES_MASKED += "live hddimg iso"
 
 python() {
index 45dd56b544c7dd605488fe21816648873b5a787d..0321b4f7ae04f6adf8cf9fe42526c06bc364851f 100644 (file)
@@ -382,8 +382,8 @@ python () {
         if t.startswith("debugfs_"):
             t = t[8:]
             debug = "debugfs_"
-        deps = (d.getVar('IMAGE_TYPEDEP_' + t) or "").split()
-        vardeps.add('IMAGE_TYPEDEP_' + t)
+        deps = (d.getVar('IMAGE_TYPEDEP:' + t) or "").split()
+        vardeps.add('IMAGE_TYPEDEP:' + t)
         if baset not in typedeps:
             typedeps[baset] = set()
         deps = [debug + dep for dep in deps]
index 3620931224ebaff27b67c91a484edce4468c5f6b..6a88ac85adfaa865a16fedba88a2c6cbd4d399a2 100644 (file)
@@ -29,7 +29,7 @@ def imagetypes_getdepends(d):
         if d.getVar(var) is not None:
             deprecated.add(var)
 
-        for typedepends in (d.getVar("IMAGE_TYPEDEP_%s" % basetype) or "").split():
+        for typedepends in (d.getVar("IMAGE_TYPEDEP:%s" % basetype) or "").split():
             base, rest = split_types(typedepends)
             resttypes += rest
 
@@ -197,7 +197,7 @@ IMAGE_CMD:multiubi () {
 IMAGE_CMD:ubi () {
        multiubi_mkfs "${MKUBIFS_ARGS}" "${UBINIZE_ARGS}"
 }
-IMAGE_TYPEDEP_ubi = "ubifs"
+IMAGE_TYPEDEP:ubi = "ubifs"
 
 IMAGE_CMD:ubifs = "mkfs.ubifs -r ${IMAGE_ROOTFS} -o ${IMGDEPLOYDIR}/${IMAGE_NAME}${IMAGE_NAME_SUFFIX}.ubifs ${MKUBIFS_ARGS}"
 
index b92e520bc2b7c07e0861f86df2df455a0a7342c5..3068c9ba26ed7972c2475be0396f529e11e69f60 100644 (file)
@@ -22,7 +22,7 @@ from oeqa.utils.commands import bitbake, get_bb_vars, runCmd
 #
 class ContainerImageTests(OESelftestTestCase):
 
-    # Verify that when specifying a IMAGE_TYPEDEP_ of the form "foo.bar" that
+    # Verify that when specifying a IMAGE_TYPEDEP: of the form "foo.bar" that
     # the conversion type bar gets added as a dep as well
     def test_expected_files(self):
 
index 52e1080f1307fc6585386ed87981b712e1f28eeb..5b182a8f94002a2f30aa11e17b327b6cc3ab38cc 100644 (file)
@@ -9,7 +9,7 @@ from oeqa.utils.commands import bitbake
 
 class ImageTypeDepTests(OESelftestTestCase):
 
-    # Verify that when specifying a IMAGE_TYPEDEP_ of the form "foo.bar" that
+    # Verify that when specifying a IMAGE_TYPEDEP: of the form "foo.bar" that
     # the conversion type bar gets added as a dep as well
     def test_conversion_typedep_added(self):
 
@@ -22,7 +22,7 @@ LICENSE = "MIT"
 IMAGE_FSTYPES = "testfstype"
 
 IMAGE_TYPES_MASKED += "testfstype"
-IMAGE_TYPEDEP_testfstype = "tar.bz2"
+IMAGE_TYPEDEP:testfstype = "tar.bz2"
 
 inherit image
 
index e3e271d32bd58a56232623151c073a7e47942ad3..f7f1b79ca094391d0aa8d80eba1dcff370b17f35 100755 (executable)
@@ -64,7 +64,7 @@ skips = skips + ["get_appends_for_files", "test_doubleref_remove", "test_bitbake
 skips = skips + ["test_rpm_remove", "test_bitbakelayers_add_remove", "recipe_append_file", "log_data_removed", "recipe_append", "systemd_machine_unit_append"]
 skips = skips + ["recipetool_append", "changetype_remove", "try_appendfile_wc", "test_qemux86_directdisk", "test_layer_appends", "tgz_removed"]
 
-imagevars = ["IMAGE_CMD", "EXTRA_IMAGECMD"]
+imagevars = ["IMAGE_CMD", "EXTRA_IMAGECMD", "IMAGE_TYPEDEP"]
 packagevars = packagevars + imagevars
 
 vars_re = {}