From: Ross Burton Date: Wed, 9 Nov 2022 19:31:35 +0000 (+0000) Subject: classes/testexport: move to classes-recipe X-Git-Tag: lucaceresoli/bug-15201-perf-libtraceevent-missing~2530 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=87fcee9fed915ff3af528b976d7d44737f9f1a95;p=thirdparty%2Fopenembedded%2Fopenembedded-core-contrib.git classes/testexport: move to classes-recipe This class should be in classes-recipe as, like testimage, it is specific to image recipes. This also solves a regression where simply IMAGE_CLASSES += "testexport" doesn't work if testimage isn't already in IMAGE_CLASSES. The testexport class adds testimage to IMAGE_CLASSES, but by this point it's too late. Now that the class can only be inherited via IMAGE_CLASSES, we can simply inherit testimage directly. Signed-off-by: Ross Burton Signed-off-by: Alexandre Belloni --- diff --git a/meta/classes/testexport.bbclass b/meta/classes-recipe/testexport.bbclass similarity index 98% rename from meta/classes/testexport.bbclass rename to meta/classes-recipe/testexport.bbclass index f7c5242dc5e..0f0c56107f8 100644 --- a/meta/classes/testexport.bbclass +++ b/meta/classes-recipe/testexport.bbclass @@ -7,12 +7,14 @@ # To use it add testexport to global inherit and call your target image with -c testexport # You can try it out like this: # - First build an image. i.e. core-image-sato -# - Add INHERIT += "testexport" in local.conf +# - Add IMAGE_CLASSES += "testexport" in local.conf # - Then bitbake core-image-sato -c testexport. That will generate the directory structure # to execute the runtime tests using runexported.py. # # For more information on TEST_SUITES check testimage class. +inherit testimage + TEST_LOG_DIR ?= "${WORKDIR}/testexport" TEST_EXPORT_DIR ?= "${TMPDIR}/testexport/${PN}" TEST_EXPORT_PACKAGED_DIR ?= "packages/packaged" @@ -176,5 +178,3 @@ def testexport_create_tarball(d, tar_name, src_dir): tar.add(base_name) tar.close() os.chdir(current_dir) - -IMAGE_CLASSES += "testimage"