]> code.ossystems Code Review - openembedded-core.git/commitdiff
bitbake.conf: rename 'gobject-introspection-data' machine feature to 'qemu-usermode'
authorAlexander Kanavin <alexander.kanavin@linux.intel.com>
Wed, 23 Mar 2016 12:52:05 +0000 (14:52 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 28 Mar 2016 14:54:50 +0000 (15:54 +0100)
The new value is more general and better reflects what having the feature really means.
Introspection data, then, is built only if 'gobject-introspection-data' is in
DISTRO_FEATURES and 'qemu-usermode' is in MACHINE_FEATURES.

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/gobject-introspection-data.bbclass [new file with mode: 0644]
meta/classes/gobject-introspection.bbclass
meta/conf/bitbake.conf
meta/conf/machine/include/x86/arch-x86.inc
meta/recipes-gnome/gobject-introspection/gobject-introspection_1.46.0.bb
meta/recipes-sato/webkit/webkitgtk_2.10.7.bb

diff --git a/meta/classes/gobject-introspection-data.bbclass b/meta/classes/gobject-introspection-data.bbclass
new file mode 100644 (file)
index 0000000..b1bdd26
--- /dev/null
@@ -0,0 +1,9 @@
+# This variable is set to True if gobject-introspection-data is in
+# DISTRO_FEATURES and qemu-usermode is in MACHINE_FEATURES, and False otherwise.
+#
+# It should be used in recipes to determine whether introspection data should be built,
+# so that qemu use can be avoided when necessary.
+GI_DATA_ENABLED = "${@bb.utils.contains('DISTRO_FEATURES', 'gobject-introspection-data', \
+                      bb.utils.contains('MACHINE_FEATURES', 'qemu-usermode', 'True', 'False', d), 'False', d)}"
+
+
index d8b8b3ed2720b26ac97e5e3ad9ef95bccc53c6f1..2d73e402ce9af8b91b34a868f142ffad86e5c81c 100644 (file)
@@ -1,9 +1,9 @@
 # Inherit this class in recipes to enable building their introspection files
 
-# This allows disabling introspection support (and therefore avoiding the use
-# of qemu) in recipes if gobject-introspection-data is omitted from
-# DISTRO_FEATURES or MACHINE_FEATURES.
-EXTRA_OECONF_prepend = "${@bb.utils.contains('COMBINED_FEATURES', 'gobject-introspection-data', '--enable-introspection', '--disable-introspection', d)} "
+# This sets up autoconf-based recipes to build introspection data (or not),
+# depending on distro and machine features (see gobject-introspection-data class).
+inherit gobject-introspection-data
+EXTRA_OECONF_prepend = "${@bb.utils.contains('GI_DATA_ENABLED', 'True', '--enable-introspection', '--disable-introspection', d)} "
 
 UNKNOWN_CONFIGURE_WHITELIST_append = " --enable-introspection --disable-introspection"
 
index e3db5041f3c64852944a07d264812f87ba66f65b..d4fb5f35713672ee377ae09a879112ac9e6ef341 100644 (file)
@@ -762,7 +762,7 @@ EXTRA_IMAGE_FEATURES ??= ""
 IMAGE_FEATURES += "${EXTRA_IMAGE_FEATURES}"
 
 DISTRO_FEATURES_BACKFILL = "pulseaudio sysvinit bluez5 gobject-introspection-data"
-MACHINE_FEATURES_BACKFILL = "rtc gobject-introspection-data"
+MACHINE_FEATURES_BACKFILL = "rtc qemu-usermode"
 
 COMBINED_FEATURES = "${@oe.utils.set_intersect('DISTRO_FEATURES', 'MACHINE_FEATURES', d)}"
 COMBINED_FEATURES[vardeps] += "DISTRO_FEATURES MACHINE_FEATURES"
index ba7be8ad655357175d02f53fb088c63a0a1b3ba9..e51d595f74764a58b19c0cecb2c499d7864eb1e4 100644 (file)
@@ -25,7 +25,7 @@ TUNE_CCARGS .= "${@bb.utils.contains('TUNE_FEATURES', 'mx32', ' -mx32', '', d)}"
 TUNE_LDARGS += "${@bb.utils.contains('TUNE_FEATURES', 'mx32', '-m elf32_x86_64', '', d)}"
 TUNE_ASARGS += "${@bb.utils.contains('TUNE_FEATURES', 'mx32', '-x32', '', d)}"
 # user mode qemu doesn't support x32
-MACHINE_FEATURES_BACKFILL_CONSIDERED_append = " ${@bb.utils.contains('TUNE_FEATURES', 'mx32', 'gobject-introspection-data', '', d)}"
+MACHINE_FEATURES_BACKFILL_CONSIDERED_append = " ${@bb.utils.contains('TUNE_FEATURES', 'mx32', 'qemu-usermode', '', d)}"
 
 # ELF64 ABI
 TUNEVALID[m64] = "IA32e (x86_64) ELF64 standard ABI"
index b8b88234e7aab1c29990353a0f64121f995f7c67..9b16147da3e6df6c4bd6af41dcab4bf798211c34 100644 (file)
@@ -16,7 +16,7 @@ SRC_URI = "${GNOME_MIRROR}/${BPN}/1.46/${BPN}-${PV}.tar.xz \
 SRC_URI[md5sum] = "adb40a31c7c80b65b0f4c8fd71b493dc"
 SRC_URI[sha256sum] = "6658bd3c2b8813eb3e2511ee153238d09ace9d309e4574af27443d87423e4233"
 
-inherit autotools pkgconfig gtk-doc pythonnative qemu
+inherit autotools pkgconfig gtk-doc pythonnative qemu gobject-introspection-data
 BBCLASSEXTEND = "native"
 
 # necessary to let the call for python-config from configure.ac succeed
@@ -105,7 +105,7 @@ EOF
 EXTRA_OECONF_class-target += "--enable-host-gi \
                               --enable-gi-cross-wrapper=${B}/g-ir-scanner-qemuwrapper \
                               --enable-gi-ldd-wrapper=${B}/g-ir-scanner-lddwrapper \
-                              ${@bb.utils.contains('COMBINED_FEATURES', 'gobject-introspection-data', '--enable-introspection-data', '--disable-introspection-data', d)} \
+                              ${@bb.utils.contains('GI_DATA_ENABLED', 'True', '--enable-introspection-data', '--disable-introspection-data', d)} \
                              "
 
 
index 849a33a1e7439ff14835f556ff606a7c4225f1e3..8eb6b9f3b28b83ddf4cb826b4b0d8d2b33467db9 100644 (file)
@@ -54,7 +54,7 @@ PACKAGECONFIG[libhyphen] = "-DUSE_LIBHYPHEN=ON,-DUSE_LIBHYPHEN=OFF,libhyphen"
 EXTRA_OECMAKE = " \
                -DPORT=GTK \
                -DCMAKE_BUILD_TYPE=Release \
-               ${@bb.utils.contains('COMBINED_FEATURES', 'gobject-introspection-data', '-DENABLE_INTROSPECTION=ON', '-DENABLE_INTROSPECTION=OFF', d)} \
+               ${@bb.utils.contains('GI_DATA_ENABLED', 'True', '-DENABLE_INTROSPECTION=ON', '-DENABLE_INTROSPECTION=OFF', d)} \
                -DENABLE_GTKDOC=OFF \
                -DENABLE_MINIBROWSER=ON \
                "