]> code.ossystems Code Review - openembedded-core.git/commitdiff
classes/packagegroup: drop complementary -ptest if ptest not in DISTRO_FEATURES
authorPaul Eggleton <paul.eggleton@linux.intel.com>
Mon, 21 Mar 2016 05:10:57 +0000 (18:10 +1300)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Wed, 23 Mar 2016 14:24:24 +0000 (14:24 +0000)
If ptest isn't in DISTRO_FEATURES, there won't be any -ptest packages
and thus no need for the -ptest package for the packagegroup either.

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/packagegroup.bbclass

index 92e0bbe9de32a4cc43a92268589165468e9bf771..d56248f2de199361df6f41dfe26c30a9040e4955 100644 (file)
@@ -27,8 +27,11 @@ python () {
     if d.getVar('PACKAGEGROUP_DISABLE_COMPLEMENTARY', True) != '1':
         # Add complementary packagegroups
         genpackages = []
+        complementary_types = ['-dbg', '-dev']
+        if bb.utils.contains('DISTRO_FEATURES', 'ptest', True, False, d):
+            complementary_types.append('-ptest')
         for pkg in packages:
-            for postfix in ['-dbg', '-dev', '-ptest']:
+            for postfix in complementary_types:
                 genpackages.append(pkg+postfix)
                 d.setVar("ALLOW_EMPTY_%s" % pkg+postfix, "1")
         d.setVar('PACKAGES', ' '.join(packages+genpackages))