summaryrefslogtreecommitdiffstats
path: root/import-layers/yocto-poky/meta/classes/gobject-introspection.bbclass
diff options
context:
space:
mode:
authorPatrick Williams <patrick@stwcx.xyz>2016-08-17 14:31:25 -0500
committerPatrick Williams <patrick@stwcx.xyz>2016-08-22 16:43:26 +0000
commit60f9d69e016b11c468c98ea75ba0a60c44afbbc4 (patch)
treeecb49581a9e41a37943c22cd9ef3f63451b20ee7 /import-layers/yocto-poky/meta/classes/gobject-introspection.bbclass
parente18c61205e0234b03697129c20cc69c9b3940efc (diff)
downloadtalos-openbmc-60f9d69e016b11c468c98ea75ba0a60c44afbbc4.tar.gz
talos-openbmc-60f9d69e016b11c468c98ea75ba0a60c44afbbc4.zip
yocto-poky: Move to import-layers subdir
We are going to import additional layers, so create a subdir to hold all of the layers that we import with git-subtree. Change-Id: I6f732153a22be8ca663035c518837e3cc5ec0799 Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
Diffstat (limited to 'import-layers/yocto-poky/meta/classes/gobject-introspection.bbclass')
-rw-r--r--import-layers/yocto-poky/meta/classes/gobject-introspection.bbclass37
1 files changed, 37 insertions, 0 deletions
diff --git a/import-layers/yocto-poky/meta/classes/gobject-introspection.bbclass b/import-layers/yocto-poky/meta/classes/gobject-introspection.bbclass
new file mode 100644
index 000000000..2d73e402c
--- /dev/null
+++ b/import-layers/yocto-poky/meta/classes/gobject-introspection.bbclass
@@ -0,0 +1,37 @@
+# Inherit this class in recipes to enable building their introspection files
+
+# 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"
+
+# Generating introspection data depends on a combination of native and target
+# introspection tools, and qemu to run the target tools.
+DEPENDS_append = " gobject-introspection gobject-introspection-native qemu-native"
+
+# This is necessary for python scripts to succeed - distutils fails if these
+# are not set
+export BUILD_SYS
+export HOST_SYS
+export STAGING_INCDIR
+export STAGING_LIBDIR
+
+# This is used by introspection tools to find .gir includes
+export XDG_DATA_DIRS = "${STAGING_DATADIR}"
+
+do_configure_prepend_class-target () {
+ # introspection.m4 pre-packaged with upstream tarballs does not yet
+ # have our fixes
+ mkdir -p ${S}/m4
+ cp ${STAGING_DIR_TARGET}/${datadir}/aclocal/introspection.m4 ${S}/m4
+}
+
+# .typelib files are needed at runtime and so they go to the main package (so
+# they'll be together with libraries they support).
+FILES_${PN}_append = " ${libdir}/girepository-*/*.typelib"
+
+# .gir files go to dev package, as they're needed for developing (but not for
+# running) things that depends on introspection.
+FILES_${PN}-dev_append = " ${datadir}/gir-*/*.gir"
OpenPOWER on IntegriCloud