diff options
author | Adrian Dudau <adrian.dudau@enea.com> | 2014-06-26 14:36:22 +0200 |
---|---|---|
committer | Adrian Dudau <adrian.dudau@enea.com> | 2014-06-26 15:32:53 +0200 |
commit | f4cf9fe05bb3f32fabea4e54dd92d368967a80da (patch) | |
tree | 487180fa9866985ea7b28e625651765d86f515c3 /meta/classes/packagegroup.bbclass | |
download | poky-f4cf9fe05bb3f32fabea4e54dd92d368967a80da.tar.gz |
initial commit for Enea Linux 4.0
Migrated from the internal git server on the daisy-enea branch
Signed-off-by: Adrian Dudau <adrian.dudau@enea.com>
Diffstat (limited to 'meta/classes/packagegroup.bbclass')
-rw-r--r-- | meta/classes/packagegroup.bbclass | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/meta/classes/packagegroup.bbclass b/meta/classes/packagegroup.bbclass new file mode 100644 index 0000000000..9bc9cc22ad --- /dev/null +++ b/meta/classes/packagegroup.bbclass | |||
@@ -0,0 +1,47 @@ | |||
1 | # Class for packagegroup (package group) recipes | ||
2 | |||
3 | # By default, only the packagegroup package itself is in PACKAGES. | ||
4 | # -dbg and -dev flavours are handled by the anonfunc below. | ||
5 | # This means that packagegroup recipes used to build multiple packagegroup | ||
6 | # packages have to modify PACKAGES after inheriting packagegroup.bbclass. | ||
7 | PACKAGES = "${PN}" | ||
8 | |||
9 | # By default, packagegroup packages do not depend on a certain architecture. | ||
10 | # Only if dependencies are modified by MACHINE_FEATURES, packages | ||
11 | # need to be set to MACHINE_ARCH after inheriting packagegroup.bbclass | ||
12 | inherit allarch | ||
13 | |||
14 | # This automatically adds -dbg and -dev flavours of all PACKAGES | ||
15 | # to the list. Their dependencies (RRECOMMENDS) are handled as usual | ||
16 | # by package_depchains in a following step. | ||
17 | # Also mark all packages as ALLOW_EMPTY | ||
18 | python () { | ||
19 | packages = d.getVar('PACKAGES', True).split() | ||
20 | genpackages = [] | ||
21 | for pkg in packages: | ||
22 | d.setVar("ALLOW_EMPTY_%s" % pkg, "1") | ||
23 | for postfix in ['-dbg', '-dev', '-ptest']: | ||
24 | genpackages.append(pkg+postfix) | ||
25 | if d.getVar('PACKAGEGROUP_DISABLE_COMPLEMENTARY', True) != '1': | ||
26 | d.setVar('PACKAGES', ' '.join(packages+genpackages)) | ||
27 | } | ||
28 | |||
29 | # We don't want to look at shared library dependencies for the | ||
30 | # dbg packages | ||
31 | DEPCHAIN_DBGDEFAULTDEPS = "1" | ||
32 | |||
33 | # We only need the packaging tasks - disable the rest | ||
34 | do_fetch[noexec] = "1" | ||
35 | do_unpack[noexec] = "1" | ||
36 | do_patch[noexec] = "1" | ||
37 | do_configure[noexec] = "1" | ||
38 | do_compile[noexec] = "1" | ||
39 | do_install[noexec] = "1" | ||
40 | do_populate_sysroot[noexec] = "1" | ||
41 | |||
42 | python () { | ||
43 | initman = d.getVar("VIRTUAL-RUNTIME_init_manager", True) | ||
44 | if initman and initman in ['sysvinit', 'systemd'] and not base_contains('DISTRO_FEATURES', initman, True, False, d): | ||
45 | bb.fatal("Please ensure that your setting of VIRTUAL-RUNTIME_init_manager (%s) matches the entries enabled in DISTRO_FEATURES" % initman) | ||
46 | } | ||
47 | |||