summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHongxu Jia <hongxu.jia@windriver.com>2014-01-27 10:05:10 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2014-02-11 11:53:42 +0000
commit4d8982a1c630f88d2610a85705d68b8a0ec3c1ec (patch)
treea5db40d5386becb1cdce29ea90ab8832fb81af39
parentee175b5161c4d080bd5971b2e9cfafe1ba88909f (diff)
downloadpoky-4d8982a1c630f88d2610a85705d68b8a0ec3c1ec.tar.gz
image.bbclass/populate_sdk_base.bbclass: shift position of sdk complementary install definition
The sdk complementary install operation was defined in image.bbclass, but the sdk recipe (such as meta-toolchain.bb) didn't inherit this bbclass but populate_sdk, and both of image and populate_sdk bbclass inherited populate_sdk_base bbclass, so move the sdk complementary install definition to populate_sdk_base bbclass fixed this issue. (From OE-Core rev: 907458935bab391f5bfba8f581ea9835078548d9) Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/classes/image.bbclass19
-rw-r--r--meta/classes/populate_sdk_base.bbclass21
2 files changed, 21 insertions, 19 deletions
diff --git a/meta/classes/image.bbclass b/meta/classes/image.bbclass
index e5ec42ce3d..8f4be13796 100644
--- a/meta/classes/image.bbclass
+++ b/meta/classes/image.bbclass
@@ -35,26 +35,7 @@ FEATURE_INSTALL_OPTIONAL = "${@' '.join(oe.packagegroup.optional_packages(oe.dat
35SPLASH ?= "psplash" 35SPLASH ?= "psplash"
36PACKAGE_GROUP_splash = "${SPLASH}" 36PACKAGE_GROUP_splash = "${SPLASH}"
37 37
38# Wildcards specifying complementary packages to install for every package that has been explicitly
39# installed into the rootfs
40COMPLEMENTARY_GLOB[dev-pkgs] = '*-dev'
41COMPLEMENTARY_GLOB[staticdev-pkgs] = '*-staticdev'
42COMPLEMENTARY_GLOB[doc-pkgs] = '*-doc'
43COMPLEMENTARY_GLOB[dbg-pkgs] = '*-dbg'
44COMPLEMENTARY_GLOB[ptest-pkgs] = '*-ptest'
45
46def complementary_globs(featurevar, d):
47 all_globs = d.getVarFlags('COMPLEMENTARY_GLOB')
48 globs = []
49 features = set((d.getVar(featurevar, True) or '').split())
50 for name, glob in all_globs.items():
51 if name in features:
52 globs.append(glob)
53 return ' '.join(globs)
54
55IMAGE_INSTALL_COMPLEMENTARY = '${@complementary_globs("IMAGE_FEATURES", d)}' 38IMAGE_INSTALL_COMPLEMENTARY = '${@complementary_globs("IMAGE_FEATURES", d)}'
56SDKIMAGE_FEATURES ??= "dev-pkgs dbg-pkgs"
57SDKIMAGE_INSTALL_COMPLEMENTARY = '${@complementary_globs("SDKIMAGE_FEATURES", d)}'
58 39
59def check_image_features(d): 40def check_image_features(d):
60 valid_features = (d.getVarFlag('IMAGE_FEATURES', 'validitems', True) or "").split() 41 valid_features = (d.getVarFlag('IMAGE_FEATURES', 'validitems', True) or "").split()
diff --git a/meta/classes/populate_sdk_base.bbclass b/meta/classes/populate_sdk_base.bbclass
index 0c17aac251..ee2a7c1d59 100644
--- a/meta/classes/populate_sdk_base.bbclass
+++ b/meta/classes/populate_sdk_base.bbclass
@@ -1,4 +1,25 @@
1inherit meta toolchain-scripts 1inherit meta toolchain-scripts
2
3# Wildcards specifying complementary packages to install for every package that has been explicitly
4# installed into the rootfs
5COMPLEMENTARY_GLOB[dev-pkgs] = '*-dev'
6COMPLEMENTARY_GLOB[staticdev-pkgs] = '*-staticdev'
7COMPLEMENTARY_GLOB[doc-pkgs] = '*-doc'
8COMPLEMENTARY_GLOB[dbg-pkgs] = '*-dbg'
9COMPLEMENTARY_GLOB[ptest-pkgs] = '*-ptest'
10
11def complementary_globs(featurevar, d):
12 all_globs = d.getVarFlags('COMPLEMENTARY_GLOB')
13 globs = []
14 features = set((d.getVar(featurevar, True) or '').split())
15 for name, glob in all_globs.items():
16 if name in features:
17 globs.append(glob)
18 return ' '.join(globs)
19
20SDKIMAGE_FEATURES ??= "dev-pkgs dbg-pkgs"
21SDKIMAGE_INSTALL_COMPLEMENTARY = '${@complementary_globs("SDKIMAGE_FEATURES", d)}'
22
2inherit populate_sdk_${IMAGE_PKGTYPE} 23inherit populate_sdk_${IMAGE_PKGTYPE}
3 24
4SDK_DIR = "${WORKDIR}/sdk" 25SDK_DIR = "${WORKDIR}/sdk"