diff options
Diffstat (limited to 'meta')
| -rw-r--r-- | meta/classes-recipe/image.bbclass | 3 | ||||
| -rw-r--r-- | meta/lib/oeqa/selftest/cases/imagefeatures.py | 13 |
2 files changed, 10 insertions, 6 deletions
diff --git a/meta/classes-recipe/image.bbclass b/meta/classes-recipe/image.bbclass index 24a19fce1a..ccad308b93 100644 --- a/meta/classes-recipe/image.bbclass +++ b/meta/classes-recipe/image.bbclass | |||
| @@ -481,6 +481,7 @@ python () { | |||
| 481 | for ctype in sorted(ctypes): | 481 | for ctype in sorted(ctypes): |
| 482 | if bt.endswith("." + ctype): | 482 | if bt.endswith("." + ctype): |
| 483 | type = bt[0:-len(ctype) - 1] | 483 | type = bt[0:-len(ctype) - 1] |
| 484 | original_type = type | ||
| 484 | if type.startswith("debugfs_"): | 485 | if type.startswith("debugfs_"): |
| 485 | type = type[8:] | 486 | type = type[8:] |
| 486 | # Create input image first. | 487 | # Create input image first. |
| @@ -493,7 +494,7 @@ python () { | |||
| 493 | subimage = type + "." + ctype | 494 | subimage = type + "." + ctype |
| 494 | if subimage not in subimages: | 495 | if subimage not in subimages: |
| 495 | subimages.append(subimage) | 496 | subimages.append(subimage) |
| 496 | if type not in alltypes: | 497 | if original_type not in alltypes: |
| 497 | rm_tmp_images.add(localdata.expand("${IMAGE_NAME}.${type}")) | 498 | rm_tmp_images.add(localdata.expand("${IMAGE_NAME}.${type}")) |
| 498 | 499 | ||
| 499 | for bt in basetypes[t]: | 500 | for bt in basetypes[t]: |
diff --git a/meta/lib/oeqa/selftest/cases/imagefeatures.py b/meta/lib/oeqa/selftest/cases/imagefeatures.py index 94d01ba116..87c3da228a 100644 --- a/meta/lib/oeqa/selftest/cases/imagefeatures.py +++ b/meta/lib/oeqa/selftest/cases/imagefeatures.py | |||
| @@ -277,16 +277,19 @@ SKIP_RECIPE[busybox] = "Don't build this" | |||
| 277 | """ | 277 | """ |
| 278 | 278 | ||
| 279 | image = 'core-image-minimal' | 279 | image = 'core-image-minimal' |
| 280 | image_fstypes_debugfs = 'tar.bz2' | 280 | config = """ |
| 281 | features = 'IMAGE_GEN_DEBUGFS = "1"\n' | 281 | IMAGE_GEN_DEBUGFS = "1" |
| 282 | features += 'IMAGE_FSTYPES_DEBUGFS = "%s"\n' % image_fstypes_debugfs | 282 | IMAGE_FSTYPES_DEBUGFS = "tar.bz2 tar.bz2.sha256sum" |
| 283 | self.write_config(features) | 283 | """ |
| 284 | self.write_config(config) | ||
| 284 | 285 | ||
| 285 | bitbake(image) | 286 | bitbake(image) |
| 286 | bb_vars = get_bb_vars(['DEPLOY_DIR_IMAGE', 'IMAGE_LINK_NAME'], image) | 287 | bb_vars = get_bb_vars(['DEPLOY_DIR_IMAGE', 'IMAGE_LINK_NAME'], image) |
| 287 | 288 | ||
| 288 | dbg_tar_file = os.path.join(bb_vars['DEPLOY_DIR_IMAGE'], "%s-dbg.%s" % (bb_vars['IMAGE_LINK_NAME'], image_fstypes_debugfs)) | 289 | dbg_tar_file = os.path.join(bb_vars['DEPLOY_DIR_IMAGE'], "%s-dbg.tar.bz2" % bb_vars['IMAGE_LINK_NAME']) |
| 289 | self.assertTrue(os.path.exists(dbg_tar_file), 'debug filesystem not generated at %s' % dbg_tar_file) | 290 | self.assertTrue(os.path.exists(dbg_tar_file), 'debug filesystem not generated at %s' % dbg_tar_file) |
| 291 | dbg_tar_sha_file = os.path.join(bb_vars['DEPLOY_DIR_IMAGE'], "%s-dbg.tar.bz2.sha256sum" % bb_vars['IMAGE_LINK_NAME']) | ||
| 292 | self.assertTrue(os.path.exists(dbg_tar_sha_file), 'debug filesystem sha256sum not generated at %s' % dbg_tar_sha_file) | ||
| 290 | result = runCmd('cd %s; tar xvf %s' % (bb_vars['DEPLOY_DIR_IMAGE'], dbg_tar_file)) | 293 | result = runCmd('cd %s; tar xvf %s' % (bb_vars['DEPLOY_DIR_IMAGE'], dbg_tar_file)) |
| 291 | self.assertEqual(result.status, 0, msg='Failed to extract %s: %s' % (dbg_tar_file, result.output)) | 294 | self.assertEqual(result.status, 0, msg='Failed to extract %s: %s' % (dbg_tar_file, result.output)) |
| 292 | result = runCmd('find %s -name %s' % (bb_vars['DEPLOY_DIR_IMAGE'], "udevadm")) | 295 | result = runCmd('find %s -name %s' % (bb_vars['DEPLOY_DIR_IMAGE'], "udevadm")) |
