diff options
author | Patrick Ohly <patrick.ohly@intel.com> | 2016-07-29 17:58:52 +0300 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-08-18 09:27:53 +0100 |
commit | ff3a455ee84b91e797052760c8d4618109b54c63 (patch) | |
tree | 50314a0d569d832601d87a5a72495e82ff132b03 /meta/classes/image.bbclass | |
parent | 10e44fe6fb9f0676dfd4ef10f79eceac61011874 (diff) | |
download | poky-ff3a455ee84b91e797052760c8d4618109b54c63.tar.gz |
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]
(From OE-Core rev: 9d68c024790850cab72ead1e3372a5fcec4ef7b0)
Signed-off-by: Patrick Ohly <patrick.ohly@intel.com>
Signed-off-by: Ed Bartosh <ed.bartosh@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/image.bbclass')
-rw-r--r-- | meta/classes/image.bbclass | 9 |
1 files changed, 5 insertions, 4 deletions
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): | |||
118 | 'IMAGE_ROOTFS_MAXSIZE','IMAGE_NAME','IMAGE_LINK_NAME','IMAGE_MANIFEST','DEPLOY_DIR_IMAGE','RM_OLD_IMAGE','IMAGE_FSTYPES','IMAGE_INSTALL_COMPLEMENTARY','IMAGE_LINGUAS', | 118 | 'IMAGE_ROOTFS_MAXSIZE','IMAGE_NAME','IMAGE_LINK_NAME','IMAGE_MANIFEST','DEPLOY_DIR_IMAGE','RM_OLD_IMAGE','IMAGE_FSTYPES','IMAGE_INSTALL_COMPLEMENTARY','IMAGE_LINGUAS', |
119 | 'MULTILIBRE_ALLOW_REP','MULTILIB_TEMP_ROOTFS','MULTILIB_VARIANTS','MULTILIBS','ALL_MULTILIB_PACKAGE_ARCHS','MULTILIB_GLOBAL_VARIANTS','BAD_RECOMMENDATIONS','NO_RECOMMENDATIONS', | 119 | 'MULTILIBRE_ALLOW_REP','MULTILIB_TEMP_ROOTFS','MULTILIB_VARIANTS','MULTILIBS','ALL_MULTILIB_PACKAGE_ARCHS','MULTILIB_GLOBAL_VARIANTS','BAD_RECOMMENDATIONS','NO_RECOMMENDATIONS', |
120 | 'PACKAGE_ARCHS','PACKAGE_CLASSES','TARGET_VENDOR','TARGET_ARCH','TARGET_OS','OVERRIDES','BBEXTENDVARIANT','FEED_DEPLOYDIR_BASE_URI','INTERCEPT_DIR','USE_DEVFS', | 120 | 'PACKAGE_ARCHS','PACKAGE_CLASSES','TARGET_VENDOR','TARGET_ARCH','TARGET_OS','OVERRIDES','BBEXTENDVARIANT','FEED_DEPLOYDIR_BASE_URI','INTERCEPT_DIR','USE_DEVFS', |
121 | 'COMPRESSIONTYPES', 'IMAGE_GEN_DEBUGFS', 'ROOTFS_RO_UNNEEDED'] | 121 | 'CONVERSIONTYPES', 'IMAGE_GEN_DEBUGFS', 'ROOTFS_RO_UNNEEDED'] |
122 | variables.extend(rootfs_command_variables(d)) | 122 | variables.extend(rootfs_command_variables(d)) |
123 | variables.extend(variable_depends(d)) | 123 | variables.extend(variable_depends(d)) |
124 | return " ".join(variables) | 124 | return " ".join(variables) |
@@ -343,7 +343,7 @@ python setup_debugfs () { | |||
343 | 343 | ||
344 | python () { | 344 | python () { |
345 | vardeps = set() | 345 | vardeps = set() |
346 | # We allow COMPRESSIONTYPES to have duplicates. That avoids breaking | 346 | # We allow CONVERSIONTYPES to have duplicates. That avoids breaking |
347 | # derived distros when OE-core or some other layer independently adds | 347 | # derived distros when OE-core or some other layer independently adds |
348 | # the same type. There is still only one command for each type, but | 348 | # the same type. There is still only one command for each type, but |
349 | # presumably the commands will do the same when the type is the same, | 349 | # presumably the commands will do the same when the type is the same, |
@@ -351,7 +351,7 @@ python () { | |||
351 | # | 351 | # |
352 | # Without de-duplication, gen_conversion_cmds() below | 352 | # Without de-duplication, gen_conversion_cmds() below |
353 | # would create the same compression command multiple times. | 353 | # would create the same compression command multiple times. |
354 | ctypes = set(d.getVar('COMPRESSIONTYPES', True).split()) | 354 | ctypes = set(d.getVar('CONVERSIONTYPES', True).split()) |
355 | old_overrides = d.getVar('OVERRIDES', 0) | 355 | old_overrides = d.getVar('OVERRIDES', 0) |
356 | 356 | ||
357 | def _image_base_type(type): | 357 | def _image_base_type(type): |
@@ -456,9 +456,10 @@ python () { | |||
456 | # Create input image first. | 456 | # Create input image first. |
457 | gen_conversion_cmds(type) | 457 | gen_conversion_cmds(type) |
458 | localdata.setVar('type', type) | 458 | localdata.setVar('type', type) |
459 | cmd = "\t" + localdata.getVar("COMPRESS_CMD_" + ctype, True) | 459 | cmd = "\t" + (localdata.getVar("CONVERSION_CMD_" + ctype, True) or localdata.getVar("COMPRESS_CMD_" + ctype, True)) |
460 | if cmd not in cmds: | 460 | if cmd not in cmds: |
461 | cmds.append(cmd) | 461 | cmds.append(cmd) |
462 | vardeps.add('CONVERSION_CMD_' + ctype) | ||
462 | vardeps.add('COMPRESS_CMD_' + ctype) | 463 | vardeps.add('COMPRESS_CMD_' + ctype) |
463 | subimage = type + "." + ctype | 464 | subimage = type + "." + ctype |
464 | if subimage not in subimages: | 465 | if subimage not in subimages: |