From 9d68c024790850cab72ead1e3372a5fcec4ef7b0 Mon Sep 17 00:00:00 2001 From: Patrick Ohly Date: Fri, 29 Jul 2016 17:58:52 +0300 Subject: image.bbclass: rename COMPRESS(ION) to CONVERSION With the enhanced functionality, the term "compression" is no longer accurate, because the mechanism also gets used for conversion operations that do not actually compress data. It is possible to remove this naming problem in a backward-compatible manner by including COMPRESSIONTYPES in CONVERSIONTYPES and checking for the old COMPRESS_CMD/DEPENDS as fallbacks. [YOCTO #9346] Signed-off-by: Patrick Ohly Signed-off-by: Ed Bartosh Signed-off-by: Ross Burton --- meta/classes/image.bbclass | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'meta/classes/image.bbclass') diff --git a/meta/classes/image.bbclass b/meta/classes/image.bbclass index af789f4588..c06dee2f0c 100644 --- a/meta/classes/image.bbclass +++ b/meta/classes/image.bbclass @@ -118,7 +118,7 @@ def rootfs_variables(d): 'IMAGE_ROOTFS_MAXSIZE','IMAGE_NAME','IMAGE_LINK_NAME','IMAGE_MANIFEST','DEPLOY_DIR_IMAGE','RM_OLD_IMAGE','IMAGE_FSTYPES','IMAGE_INSTALL_COMPLEMENTARY','IMAGE_LINGUAS', 'MULTILIBRE_ALLOW_REP','MULTILIB_TEMP_ROOTFS','MULTILIB_VARIANTS','MULTILIBS','ALL_MULTILIB_PACKAGE_ARCHS','MULTILIB_GLOBAL_VARIANTS','BAD_RECOMMENDATIONS','NO_RECOMMENDATIONS', 'PACKAGE_ARCHS','PACKAGE_CLASSES','TARGET_VENDOR','TARGET_ARCH','TARGET_OS','OVERRIDES','BBEXTENDVARIANT','FEED_DEPLOYDIR_BASE_URI','INTERCEPT_DIR','USE_DEVFS', - 'COMPRESSIONTYPES', 'IMAGE_GEN_DEBUGFS', 'ROOTFS_RO_UNNEEDED'] + 'CONVERSIONTYPES', 'IMAGE_GEN_DEBUGFS', 'ROOTFS_RO_UNNEEDED'] variables.extend(rootfs_command_variables(d)) variables.extend(variable_depends(d)) return " ".join(variables) @@ -343,7 +343,7 @@ python setup_debugfs () { python () { vardeps = set() - # We allow COMPRESSIONTYPES to have duplicates. That avoids breaking + # We allow CONVERSIONTYPES to have duplicates. That avoids breaking # derived distros when OE-core or some other layer independently adds # the same type. There is still only one command for each type, but # presumably the commands will do the same when the type is the same, @@ -351,7 +351,7 @@ python () { # # Without de-duplication, gen_conversion_cmds() below # would create the same compression command multiple times. - ctypes = set(d.getVar('COMPRESSIONTYPES', True).split()) + ctypes = set(d.getVar('CONVERSIONTYPES', True).split()) old_overrides = d.getVar('OVERRIDES', 0) def _image_base_type(type): @@ -456,9 +456,10 @@ python () { # Create input image first. gen_conversion_cmds(type) localdata.setVar('type', type) - cmd = "\t" + localdata.getVar("COMPRESS_CMD_" + ctype, True) + cmd = "\t" + (localdata.getVar("CONVERSION_CMD_" + ctype, True) or localdata.getVar("COMPRESS_CMD_" + ctype, True)) if cmd not in cmds: cmds.append(cmd) + vardeps.add('CONVERSION_CMD_' + ctype) vardeps.add('COMPRESS_CMD_' + ctype) subimage = type + "." + ctype if subimage not in subimages: -- cgit v1.2.3