summaryrefslogtreecommitdiff
path: root/classes/native.bbclass
diff options
context:
space:
mode:
Diffstat (limited to 'classes/native.bbclass')
-rw-r--r--classes/native.bbclass12
1 files changed, 11 insertions, 1 deletions
diff --git a/classes/native.bbclass b/classes/native.bbclass
index 6698b61cfc..345bd8028d 100644
--- a/classes/native.bbclass
+++ b/classes/native.bbclass
@@ -1,8 +1,12 @@
+# We want native packages to be relocatable
+inherit relocatable
+
# Native packages are built indirectly via dependency,
# no need for them to be a direct target of 'world'
EXCLUDE_FROM_WORLD = "1"
PACKAGES = ""
+PACKAGES_virtclass-native = ""
PACKAGE_ARCH = "${BUILD_ARCH}"
BASE_PACKAGE_ARCH = "${BUILD_ARCH}"
@@ -37,6 +41,7 @@ STAGING_BINDIR = "${STAGING_BINDIR_NATIVE}"
STAGING_BINDIR_CROSS = "${STAGING_BINDIR_NATIVE}"
STAGING_DIR_JAVA = "${STAGING_DATADIR_JAVA_NATIVE}"
+DEPENDS_GETTEXT = "gettext-native"
# Don't use site files for native builds
export CONFIG_SITE = ""
@@ -86,6 +91,12 @@ ORIG_DEPENDS := "${DEPENDS}"
DEPENDS_virtclass-native ?= "${ORIG_DEPENDS}"
+def native_virtclass_add_override(d):
+ if "native" in (bb.data.getVar('BBCLASSEXTEND', d, True) or ""):
+ bb.data.setVar("OVERRIDES", bb.data.getVar("OVERRIDES", d, False) + ":virtclass-native", d)
+
+OVERRIDES .= "${@native_virtclass_add_override(d)}"
+
python __anonymous () {
# If we've a legacy native do_stage, we need to neuter do_install
stagefunc = bb.data.getVar('do_stage', d, True)
@@ -119,6 +130,5 @@ python __anonymous () {
provides = provides.replace(prov, prov + "-native")
bb.data.setVar("PROVIDES", provides, d)
- bb.data.setVar("OVERRIDES", bb.data.getVar("OVERRIDES", d, False) + ":virtclass-native", d)
}