All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 00/24] Add gobject introspection support to oe-core
@ 2016-03-09 15:01 Alexander Kanavin
  2016-03-09 15:01 ` [PATCH 01/24] qemu.bbclass: add qemu_wrapper_cmdline() Alexander Kanavin
                   ` (23 more replies)
  0 siblings, 24 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:01 UTC (permalink / raw)
  To: openembedded-core

0. Changelog

09 Mar 2016
- a lot of fixes based on review comments and autobuilder runs
- moved 'gobject-introspection-data' from DISTRO_FEATURES_DEFAULT
to DISTRO/MACHINE_FEATURES_BACKFILL
- gnombase.bbclass no longer enables gobject-introspection by default,
any gnome-related package should enable it individually.
- a complementary patchset for meta-oe has been developed:
http://cgit.openembedded.org/meta-openembedded-contrib/log/?h=akanavin/gobject-introspection-fixes

26 Nov 2015
- added a DISTRO_FEATURE that makes it possible to skip generation
of introspection data, and therefore avoid running qemu
- rebased the patchset to latest oe-core master
- updated gobject-introspection and pygobject recipes to latest
upstream versions

9 Nov 2015
- initial version

1. Introduction

This patchset adds support for gobject introspection to oe-core.

Gir files go to -dev packages, typelib files go to main packages
(they are packaged together with libraries that are introspected)

The work is based on a meta-gir layer, which was used as a proof of
concept; overall approach is same and some implementation ideas were
used, but this implementation is otherwise different, and hopefully
simpler and cleaner.

Generation of introspection data (.gir and typelib files) is done by
running target architecture binaries through qemu. This may not work
for all architectures/machines, so when it doesn't work, it can be
disabled distro-wide by adding 'gobject-introspection-data' to
DISTRO_FEATURES_BACKFILL_CONSIDERED or only for a specific machine by
adding the same string to MACHINE_FEATURES_BACKFILL_CONSIDERED. In this
case, introspection data can be obtained through other means (for
example, by copying the data from a suitable sysroot, or generating
it on the target hardware).

2. 30 second tutorial for adding introspection support to a package:

a. Inherit gobject-introspection class (or a class that inherits it,
such as gnome-base).

b. Make sure introspection is not disabled anywhere in the recipe or
its includes. Also, make sure that 'gobject-introspection-data' is neither in
DISTRO_FEATURES_BACKFILL_CONSIDERED nor in MACHINE_FEATURES_BACKFILL_CONSIDERED,
or nothing will happen.

c. Try to build the recipe; if this results in build errors that look
like something is unable to find .so libraries, check where these libraries
are in the source tree and add GIR_EXTRA_LIBS_PATH=${B}/something/.libs
to the recipe.

c. Any other errors probably mean that introspection support in a package
is not entirely standard, and breaks down in a cross-compilation environment.
Custom-made fixing is needed then.


3. How to verify that introspection works in an image:

a. Make sure that 'gobject-introspection-data' is not in
DISTRO_FEATURES_BACKFILL_CONSIDERED or MACHINE_FEATURES_BACKFILL_CONSIDERED.

b. Build core-image-sato.

c. Start terminal, start python3 in the terminal.

d. Type out something like:

>>> from gi.repository import GLib
>>> GLib.get_host_name()

e. Also, try something more advanced, for example:
http://python-gtk-3-tutorial.readthedocs.org/en/latest/introduction.html


4. Request for testing - I would like this patchset to be checked on three
levels:

a. Test it in all of the build environments you have. Let me know any errors
or warnings. Also let me know, if some package can be built with introspection
enabled, but is not.

b. Check the patchset for correct use of Yocto idioms. It touches a lot of things
in a lot of different ways, and maybe there are better ways to do what it does.

c. Check that the overall design is sensible: how things work is hopefully
explained in comments and commit messages.


5. Known issues:

- qemu-ppc64 crashes out immediately; so introspection data
cannot be built on that architecture:
Invalid data memory access: 0x00000040d89c5008
...

- x32 is not supported by qemu; therefore introspection data is disabled there.

- musl is causing transient glib binaries to crash on assertion failures,
so generating introspection data is disabled there as well

- there are sporadic qemu crashes when building for ppc32 and mips32 architectures,
these haven't yet been investigated

- gcr introspection is disabled in x86_64, because introspection helper binary
goes into an infinite loop under qemu (on that architecture only).

- gcr and libsecret introspection is disabled in mips64, because introspection helper
binary fails an assertion in libgpg-error

- webkit introspection is disabled in powerpc, because qemu-ppc crashes out when
running g-ir-compiler

- the whole thing should be documented in Yocto manuals

The following changes since commit 5ac3dc76a5afc2ed35b1abfc8e330e0c580eadf0:

  image.bbclass: fix incomplete .rootfs customization (2016-03-07 22:10:54 +0000)

are available in the git repository at:

  git://git.yoctoproject.org/poky-contrib akanavin/gobject-introspection-experimental
  http://git.yoctoproject.org/cgit.cgi/poky-contrib/log/?h=akanavin/gobject-introspection-experimental

Alexander Kanavin (23):
  qemu.bbclass: add qemu_wrapper_cmdline()
  python3-native: use the previous version of python-config script
  python3: fix patching get_python_lib() in distutils/sysconfig.py
  gobject-introspection: add the recipe
  gtk-doc-stub: remove introspection stubs
  gobject-introspection.bbclass: add a class that enables gobject
    introspection
  vala: enable the use of vapigen by packages with vala support
  vala.bbclass: remove pre-packaged vapigen.m4 from tarballs
  avahi-ui: remove the dependency on python-pygtk by disabling
    avahi-discover
  python-pygtk: remove the recipe
  avahi: enable gobject-introspection
  gtk+: enable gobject introspection
  gtk+3: enable gobject-introspection
  clutter: enable gobject introspection
  libsoup-2.4: enable gobject introspection
  gstreamer: enable gobject introspection
  gnomebase.bbclass: do not disable gobject introspection
  python-pygobject: update to 3.18.2
  recipes-gnome: fix introspection support
  webkitgtk: enable gobject introspection
  packagegroup-core-x11-sato: add python-pygobject and gtk+3
  bitbake.conf: add 'gobject-introspection-data' to
    DISTRO/MACHINE_FEATURES_BACKFILL
  musl: disable building of gobject introspection data

Richard Purdie (1):
  machine/include/arch-x86: Make x32 ABI not supporting
    gobject-introspection-data

 meta/classes/gnomebase.bbclass                     |   3 -
 meta/classes/gobject-introspection.bbclass         |  39 +++
 meta/classes/qemu.bbclass                          |  23 +-
 meta/classes/vala.bbclass                          |   6 +
 meta/conf/bitbake.conf                             |   4 +-
 meta/conf/distro/include/distro_alias.inc          |   1 -
 meta/conf/distro/include/tclibc-musl.inc           |   4 +
 meta/conf/machine/include/x86/arch-x86.inc         |   2 +
 meta/recipes-connectivity/avahi/avahi-ui_0.6.32.bb |  16 +-
 meta/recipes-connectivity/avahi/avahi.inc          |  15 +-
 .../packagegroups/packagegroup-self-hosted.bb      |   1 -
 ...c-add-sysroot-path-to-GI_DATADIR-don-t-se.patch |  41 +++
 .../obsolete_automake_macros.patch                 |  23 --
 .../python/python-pygobject_2.28.3.bb              |  53 ----
 .../python/python-pygobject_3.18.2.bb              |  25 ++
 .../python/python-pygtk/acinclude.m4               |  90 ------
 .../add-gtk-types.defs-into-gdk.c-dependence.patch |  32 ---
 .../python/python-pygtk/fix-gtkunixprint.patch     |  20 --
 .../python/python-pygtk/fix-pygtk-2.0.pc.patch     |  13 -
 .../python/python-pygtk/nodocs.patch               |  15 -
 .../prevent_to_get_display_during_import.patch     |  16 --
 .../python/python-pygtk/python-pygtk2/acinclude.m4 |  90 ------
 .../update-dependences-of-defs.c.patch             |  38 ---
 .../recipes-devtools/python/python-pygtk_2.24.0.bb |  55 ----
 .../python/python3-native_3.5.1.bb                 |   1 +
 ...the-shell-version-of-python-config-that-w.patch |  38 +++
 ...2-distutils-prefix-is-inside-staging-area.patch |  35 ++-
 meta/recipes-devtools/vala/vala.inc                |  34 +++
 ...001-vapigen.m4-use-PKG_CONFIG_SYSROOT_DIR.patch |  38 +++
 meta/recipes-devtools/vala/vala_0.30.1.bb          |   4 +-
 meta/recipes-gnome/gcr/gcr_3.18.0.bb               |  22 +-
 meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.32.3.bb |   7 +-
 .../gnome-desktop/gnome-desktop3_3.18.2.bb         |   2 +-
 meta/recipes-gnome/gnome/gconf_3.2.6.bb            |   6 +-
 ...config-paths-with-PKG_CONFIG_SYSROOT_DIR-.patch |  97 +++++++
 ...c-add-host-gi-gi-cross-wrapper-and-gi-ldd.patch | 204 ++++++++++++++
 ...01-giscanner-add-a-use-ldd-wrapper-option.patch |  48 ++++
 ...1-giscanner-add-use-binary-wrapper-option.patch |  52 ++++
 .../gobject-introspection_1.46.0.bb                | 159 +++++++++++
 .../gsettings-desktop-schemas_3.19.3.bb            |   4 +-
 meta/recipes-gnome/gtk+/gtk+.inc                   |   9 +-
 meta/recipes-gnome/gtk+/gtk+3.inc                  |  10 +-
 ...t-Import-introspection-stub-machinery-too.patch | 305 +++++++++++++++++++++
 .../recipes-gnome/gtk-doc-stub/gtk-doc-stub_git.bb |   6 +-
 meta/recipes-gnome/json-glib/json-glib_1.0.4.bb    |   2 +-
 meta/recipes-gnome/libgudev/libgudev_230.bb        |   2 +-
 meta/recipes-gnome/libnotify/libnotify_0.7.6.bb    |   2 +-
 meta/recipes-gnome/librsvg/librsvg_2.40.13.bb      |   5 +-
 meta/recipes-gnome/libsecret/libsecret_0.18.4.bb   |  14 +-
 meta/recipes-gnome/libwnck/libwnck3_3.14.1.bb      |   4 +-
 meta/recipes-graphics/clutter/clutter-1.0.inc      |   5 +-
 meta/recipes-graphics/clutter/clutter-gst-3.0.inc  |   4 +-
 meta/recipes-graphics/clutter/clutter-gtk-1.0.inc  |   3 +-
 meta/recipes-graphics/cogl/cogl-1.0.inc            |   8 +-
 meta/recipes-graphics/mx/mx.inc                    |   5 +-
 ...op-introspection-macros-from-acinclude.m4.patch | 121 ++++++++
 meta/recipes-graphics/pango/pango_1.38.1.bb        |  10 +-
 ...on.m4-prefix-pkgconfig-paths-with-PKG_CON.patch |  42 +++
 .../recipes-multimedia/gstreamer/gst-player_git.bb |   2 +-
 .../gstreamer/gst-plugins-package.inc              |   1 +
 ...-don-t-hardcode-libtool-name-when-running.patch |  57 ++++
 .../gstreamer/gstreamer1.0-plugins-bad_1.6.3.bb    |   1 +
 .../gstreamer/gstreamer1.0-plugins-base.inc        |   4 +
 ...-don-t-hardcode-libtool-name-when-running.patch | 168 ++++++++++++
 ...-prefix-calls-to-pkg-config-with-PKG_CONF.patch | 298 ++++++++++++++++++++
 ...ssing-include-directories-when-calling-in.patch |  28 ++
 ...ncorrect-reference-to-gstreamer-sdp-in-Ma.patch |  27 ++
 .../gstreamer/gstreamer1.0-plugins-base_1.6.3.bb   |   4 +
 .../gstreamer/gstreamer1.0-plugins.inc             |  11 +-
 .../gstreamer/gstreamer1.0-rtsp-server.inc         |  14 +-
 ...ode-libtool-name-when-using-introspection.patch |  27 ++
 meta/recipes-multimedia/gstreamer/gstreamer1.0.inc |  13 +-
 .../gstreamer/gstreamer1.0_1.6.3.bb                |   1 +
 .../packagegroups/packagegroup-core-x11-sato.bb    |   2 +
 ...Introspection.cmake-prefix-variables-obta.patch |  27 ++
 ...cmake-drop-the-hardcoded-introspection-gt.patch |  35 +++
 ...ng-introspection-files-add-CMAKE_C_FLAGS-.patch |  40 +++
 meta/recipes-sato/webkit/webkitgtk_2.10.7.bb       |  14 +-
 meta/recipes-support/atk/at-spi2-core_2.18.3.bb    |   4 +-
 meta/recipes-support/atk/atk_2.18.0.bb             |   4 +-
 meta/recipes-support/libsoup/libsoup-2.4_2.52.2.bb |   2 +-
 meta/recipes-support/vte/vte.inc                   |   6 +-
 meta/recipes-support/vte/vte_0.28.2.bb             |   3 +-
 83 files changed, 2170 insertions(+), 556 deletions(-)
 create mode 100644 meta/classes/gobject-introspection.bbclass
 create mode 100644 meta/recipes-devtools/python/python-pygobject/0001-configure.ac-add-sysroot-path-to-GI_DATADIR-don-t-se.patch
 delete mode 100644 meta/recipes-devtools/python/python-pygobject/obsolete_automake_macros.patch
 delete mode 100644 meta/recipes-devtools/python/python-pygobject_2.28.3.bb
 create mode 100644 meta/recipes-devtools/python/python-pygobject_3.18.2.bb
 delete mode 100644 meta/recipes-devtools/python/python-pygtk/acinclude.m4
 delete mode 100644 meta/recipes-devtools/python/python-pygtk/add-gtk-types.defs-into-gdk.c-dependence.patch
 delete mode 100644 meta/recipes-devtools/python/python-pygtk/fix-gtkunixprint.patch
 delete mode 100644 meta/recipes-devtools/python/python-pygtk/fix-pygtk-2.0.pc.patch
 delete mode 100644 meta/recipes-devtools/python/python-pygtk/nodocs.patch
 delete mode 100644 meta/recipes-devtools/python/python-pygtk/prevent_to_get_display_during_import.patch
 delete mode 100644 meta/recipes-devtools/python/python-pygtk/python-pygtk2/acinclude.m4
 delete mode 100644 meta/recipes-devtools/python/python-pygtk/update-dependences-of-defs.c.patch
 delete mode 100644 meta/recipes-devtools/python/python-pygtk_2.24.0.bb
 create mode 100644 meta/recipes-devtools/python/python3/0001-Do-not-use-the-shell-version-of-python-config-that-w.patch
 create mode 100644 meta/recipes-devtools/vala/vala/0001-vapigen.m4-use-PKG_CONFIG_SYSROOT_DIR.patch
 create mode 100644 meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-Prefix-pkg-config-paths-with-PKG_CONFIG_SYSROOT_DIR-.patch
 create mode 100644 meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-configure.ac-add-host-gi-gi-cross-wrapper-and-gi-ldd.patch
 create mode 100644 meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-a-use-ldd-wrapper-option.patch
 create mode 100644 meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-use-binary-wrapper-option.patch
 create mode 100644 meta/recipes-gnome/gobject-introspection/gobject-introspection_1.46.0.bb
 create mode 100644 meta/recipes-gnome/gtk-doc-stub/files/0001-Revert-Import-introspection-stub-machinery-too.patch
 create mode 100644 meta/recipes-graphics/pango/pango/0001-Drop-introspection-macros-from-acinclude.m4.patch
 create mode 100644 meta/recipes-multimedia/gstreamer/files/0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch
 create mode 100644 meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch
 create mode 100644 meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch
 create mode 100644 meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0002-Makefile.am-prefix-calls-to-pkg-config-with-PKG_CONF.patch
 create mode 100644 meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0003-riff-add-missing-include-directories-when-calling-in.patch
 create mode 100644 meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0004-rtsp-drop-incorrect-reference-to-gstreamer-sdp-in-Ma.patch
 create mode 100644 meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server/0001-Don-t-hardcode-libtool-name-when-using-introspection.patch
 create mode 100644 meta/recipes-sato/webkit/files/0001-FindGObjectIntrospection.cmake-prefix-variables-obta.patch
 create mode 100644 meta/recipes-sato/webkit/files/0001-OptionsGTK.cmake-drop-the-hardcoded-introspection-gt.patch
 create mode 100644 meta/recipes-sato/webkit/files/0001-When-building-introspection-files-add-CMAKE_C_FLAGS-.patch

-- 
2.7.0



^ permalink raw reply	[flat|nested] 41+ messages in thread

* [PATCH 01/24] qemu.bbclass: add qemu_wrapper_cmdline()
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
@ 2016-03-09 15:01 ` Alexander Kanavin
  2016-03-09 15:01 ` [PATCH 02/24] python3-native: use the previous version of python-config script Alexander Kanavin
                   ` (22 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:01 UTC (permalink / raw)
  To: openembedded-core

The class had qemu_run_binary() which was not suitable for gobject-introspection,
as it required the name of the binary to run.

qemu_wrapper_cmdline() returns just the command line string needed to run
binaries, and does not require the binary name.

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/classes/qemu.bbclass | 23 ++++++++++++++---------
 1 file changed, 14 insertions(+), 9 deletions(-)

diff --git a/meta/classes/qemu.bbclass b/meta/classes/qemu.bbclass
index c696085..f3d3be8 100644
--- a/meta/classes/qemu.bbclass
+++ b/meta/classes/qemu.bbclass
@@ -13,7 +13,19 @@ def qemu_target_binary(data):
         target_arch = "ppc64"
 
     return "qemu-" + target_arch
-#
+
+def qemu_wrapper_cmdline(data, rootfs_path, library_paths):
+    import string
+
+    qemu_binary = qemu_target_binary(data)
+    if qemu_binary == "qemu-allarch":
+        qemu_binary = "qemuwrapper"
+
+    qemu_options = data.getVar("QEMU_OPTIONS", True)    
+
+    return "PSEUDO_UNLOAD=1 " + qemu_binary + " " + qemu_options + " -L " + rootfs_path\
+            + " -E LD_LIBRARY_PATH=" + ":".join(library_paths) + " "
+
 # Next function will return a string containing the command that is needed to
 # to run a certain binary through qemu. For example, in order to make a certain
 # postinstall scriptlet run at do_rootfs time and running the postinstall is
@@ -23,17 +35,10 @@ def qemu_target_binary(data):
 # ${@qemu_run_binary(d, '$D', '/usr/bin/test_app')} [test_app arguments]
 #
 def qemu_run_binary(data, rootfs_path, binary):
-    qemu_binary = qemu_target_binary(data)
-    if qemu_binary == "qemu-allarch":
-        qemu_binary = "qemuwrapper"
-
     libdir = rootfs_path + data.getVar("libdir", False)
     base_libdir = rootfs_path + data.getVar("base_libdir", False)
-    qemu_options = data.getVar("QEMU_OPTIONS", True)
 
-    return "PSEUDO_UNLOAD=1 " + qemu_binary + " " + qemu_options + " -L " + rootfs_path\
-            + " -E LD_LIBRARY_PATH=" + libdir + ":" + base_libdir + " "\
-            + rootfs_path + binary
+    return qemu_wrapper_cmdline(data, rootfs_path, [libdir, base_libdir]) + rootfs_path + binary
 
 # QEMU_EXTRAOPTIONS is not meant to be directly used, the extensions are
 # PACKAGE_ARCH, *NOT* overrides.
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 02/24] python3-native: use the previous version of python-config script
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
  2016-03-09 15:01 ` [PATCH 01/24] qemu.bbclass: add qemu_wrapper_cmdline() Alexander Kanavin
@ 2016-03-09 15:01 ` Alexander Kanavin
  2016-03-10 21:24   ` Andreas Müller
  2016-03-09 15:01 ` [PATCH 03/24] python3: fix patching get_python_lib() in distutils/sysconfig.py Alexander Kanavin
                   ` (21 subsequent siblings)
  23 siblings, 1 reply; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:01 UTC (permalink / raw)
  To: openembedded-core

In python 3.4 python-config was rewritten in shell, ironically
to support cross-compilation:
https://bugs.python.org/issue16235

This new shell version is broken in several ways, and doesn't
have our oe-specific tweaks. Let's revert to the old script,
which is still provided.

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 .../python/python3-native_3.5.1.bb                 |  1 +
 ...the-shell-version-of-python-config-that-w.patch | 38 ++++++++++++++++++++++
 2 files changed, 39 insertions(+)
 create mode 100644 meta/recipes-devtools/python/python3/0001-Do-not-use-the-shell-version-of-python-config-that-w.patch

diff --git a/meta/recipes-devtools/python/python3-native_3.5.1.bb b/meta/recipes-devtools/python/python3-native_3.5.1.bb
index 152da1c..7bad11a 100644
--- a/meta/recipes-devtools/python/python3-native_3.5.1.bb
+++ b/meta/recipes-devtools/python/python3-native_3.5.1.bb
@@ -25,6 +25,7 @@ file://unixccompiler.patch \
 ${DISTRO_SRC_URI} \
 file://sysconfig.py-add-_PYTHON_PROJECT_SRC.patch \
 file://setup.py-check-cross_compiling-when-get-FLAGS.patch \
+file://0001-Do-not-use-the-shell-version-of-python-config-that-w.patch \
 "
 SRC_URI[md5sum] = "e9ea6f2623fffcdd871b7b19113fde80"
 SRC_URI[sha256sum] = "c6d57c0c366d9060ab6c0cdf889ebf3d92711d466cc0119c441dbf2746f725c9"
diff --git a/meta/recipes-devtools/python/python3/0001-Do-not-use-the-shell-version-of-python-config-that-w.patch b/meta/recipes-devtools/python/python3/0001-Do-not-use-the-shell-version-of-python-config-that-w.patch
new file mode 100644
index 0000000..b7e0ac6
--- /dev/null
+++ b/meta/recipes-devtools/python/python3/0001-Do-not-use-the-shell-version-of-python-config-that-w.patch
@@ -0,0 +1,38 @@
+From 045c99b5f1eb6e4e0d8ad1ef9f0ba6574f738150 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Fri, 23 Oct 2015 12:25:09 +0300
+Subject: [PATCH] Do not use the shell version of python-config that was
+ introduced in 3.4
+
+Revert instead to the original python version: it has our tweaks and
+outputs directories correctly.
+
+Upstream-Status: Inappropriate [oe-specific]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ Makefile.pre.in | 9 +++------
+ 1 file changed, 3 insertions(+), 6 deletions(-)
+
+diff --git a/Makefile.pre.in b/Makefile.pre.in
+index d7fc9a0..47e60bc 100644
+--- a/Makefile.pre.in
++++ b/Makefile.pre.in
+@@ -1270,12 +1270,9 @@ python-config: $(srcdir)/Misc/python-config.in Misc/python-config.sh
+ 	sed -e "s,@EXENAME@,$(BINDIR)/python$(LDVERSION)$(EXE)," < $(srcdir)/Misc/python-config.in >python-config.py
+ 	# Replace makefile compat. variable references with shell script compat. ones; $(VAR) -> ${VAR}
+ 	sed -e 's,\$$(\([A-Za-z0-9_]*\)),\$$\{\1\},g' < Misc/python-config.sh >python-config
+-	# On Darwin, always use the python version of the script, the shell
+-	# version doesn't use the compiler customizations that are provided
+-	# in python (_osx_support.py).
+-	if test `uname -s` = Darwin; then \
+-		cp python-config.py python-config; \
+-	fi
++	# In OpenEmbedded, always use the python version of the script, the shell
++	# version is broken in multiple ways, and doesn't return correct directories
++	cp python-config.py python-config
+ 
+ 
+ # Install the include files
+-- 
+2.1.4
+
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 03/24] python3: fix patching get_python_lib() in distutils/sysconfig.py
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
  2016-03-09 15:01 ` [PATCH 01/24] qemu.bbclass: add qemu_wrapper_cmdline() Alexander Kanavin
  2016-03-09 15:01 ` [PATCH 02/24] python3-native: use the previous version of python-config script Alexander Kanavin
@ 2016-03-09 15:01 ` Alexander Kanavin
  2016-03-09 15:01 ` [PATCH 04/24] gobject-introspection: add the recipe Alexander Kanavin
                   ` (20 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:01 UTC (permalink / raw)
  To: openembedded-core

Previous, two things were wrong:
1) lib_basename was set from STAGING_LIBDIR only if prefix parameter was empty or missing
2) if prefix was not empty, lib_basename reverted to sys.lib, even if STAGING_LIBDIR
should've overriden it

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 ...2-distutils-prefix-is-inside-staging-area.patch | 35 +++++++++++++---------
 1 file changed, 21 insertions(+), 14 deletions(-)

diff --git a/meta/recipes-devtools/python/python3/12-distutils-prefix-is-inside-staging-area.patch b/meta/recipes-devtools/python/python3/12-distutils-prefix-is-inside-staging-area.patch
index bf02df2..8b93c1c 100644
--- a/meta/recipes-devtools/python/python3/12-distutils-prefix-is-inside-staging-area.patch
+++ b/meta/recipes-devtools/python/python3/12-distutils-prefix-is-inside-staging-area.patch
@@ -1,3 +1,8 @@
+From d4dd67daa1555bf13272cc071706338572539bad Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 14 May 2013 15:00:26 -0700
+Subject: [PATCH 01/20] python3: Add target and native recipes
+
 Upstream-Status: Inappropriate [embedded specific]
 
 02/2015 Rebased for Python 3.4.2
@@ -8,11 +13,12 @@ Upstream-Status: Inappropriate [embedded specific]
 # Signed-off-by: Khem Raj <raj.khem@gmail.com>
 # Signed-off-by: Alejandro Hernandez <alejandro.hernandez@linux.intel.com>
 
-Index: Python-3.4.2/Lib/distutils/sysconfig.py
-===================================================================
---- Python-3.4.2.orig/Lib/distutils/sysconfig.py
-+++ Python-3.4.2/Lib/distutils/sysconfig.py
-@@ -16,10 +16,11 @@ import sys
+---
+diff --git a/Lib/distutils/sysconfig.py b/Lib/distutils/sysconfig.py
+index 573724d..418b478 100644
+--- a/Lib/distutils/sysconfig.py
++++ b/Lib/distutils/sysconfig.py
+@@ -17,10 +17,11 @@ import sys
  from .errors import DistutilsPlatformError
  
  # These are needed in a couple of spots, so just compute them once.
@@ -27,8 +33,8 @@ Index: Python-3.4.2/Lib/distutils/sysconfig.py
 +
  
  # Path to the base directory of the project. On Windows the binary may
- # live in project/PCBuild9.  If we're dealing with an x64 Windows build,
-@@ -93,7 +94,9 @@ def get_python_inc(plat_specific=0, pref
+ # live in project/PCBuild/win32 or project/PCBuild/amd64.
+@@ -84,7 +85,9 @@ def get_python_inc(plat_specific=0, prefix=None):
      If 'prefix' is supplied, use it instead of sys.base_prefix or
      sys.base_exec_prefix -- i.e., ignore 'plat_specific'.
      """
@@ -39,20 +45,18 @@ Index: Python-3.4.2/Lib/distutils/sysconfig.py
          prefix = plat_specific and BASE_EXEC_PREFIX or BASE_PREFIX
      if os.name == "posix":
          if python_build:
-@@ -134,6 +137,12 @@ def get_python_lib(plat_specific=0, stan
+@@ -125,6 +128,10 @@ def get_python_lib(plat_specific=0, standard_lib=0, prefix=None):
      If 'prefix' is supplied, use it instead of sys.base_prefix or
      sys.base_exec_prefix -- i.e., ignore 'plat_specific'.
      """
++    lib_basename = os.environ['STAGING_LIBDIR'].split('/')[-1]
 +    if prefix is None and os.environ['STAGING_LIBDIR'] != "":
-+        lib_basename = os.environ['STAGING_LIBDIR'].split('/')[-1]
 +        prefix = os.environ['STAGING_LIBDIR'].rstrip(lib_basename)
-+    else:
-+        lib_basename = sys.lib
 +
      if prefix is None:
          if standard_lib:
              prefix = plat_specific and BASE_EXEC_PREFIX or BASE_PREFIX
-@@ -142,7 +151,7 @@ def get_python_lib(plat_specific=0, stan
+@@ -133,7 +140,7 @@ def get_python_lib(plat_specific=0, standard_lib=0, prefix=None):
  
      if os.name == "posix":
          libpython = os.path.join(prefix,
@@ -61,7 +65,7 @@ Index: Python-3.4.2/Lib/distutils/sysconfig.py
          if standard_lib:
              return libpython
          else:
-@@ -242,7 +251,7 @@ def get_config_h_filename():
+@@ -233,7 +240,7 @@ def get_config_h_filename():
      else:
          inc_dir = get_python_inc(plat_specific=1)
  
@@ -70,7 +74,7 @@ Index: Python-3.4.2/Lib/distutils/sysconfig.py
  
  
  def get_makefile_filename():
-@@ -251,7 +260,7 @@ def get_makefile_filename():
+@@ -242,7 +249,7 @@ def get_makefile_filename():
          return os.path.join(_sys_home or project_base, "Makefile")
      lib_dir = get_python_lib(plat_specific=0, standard_lib=1)
      config_file = 'config-{}{}'.format(get_python_version(), build_flags)
@@ -79,3 +83,6 @@ Index: Python-3.4.2/Lib/distutils/sysconfig.py
  
  
  def parse_config_h(fp, g=None):
+-- 
+2.7.0
+
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 04/24] gobject-introspection: add the recipe
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (2 preceding siblings ...)
  2016-03-09 15:01 ` [PATCH 03/24] python3: fix patching get_python_lib() in distutils/sysconfig.py Alexander Kanavin
@ 2016-03-09 15:01 ` Alexander Kanavin
  2016-03-09 15:01 ` [PATCH 05/24] gtk-doc-stub: remove introspection stubs Alexander Kanavin
                   ` (19 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:01 UTC (permalink / raw)
  To: openembedded-core

The recipe has comments that explain what is going on and why.

Also, there are patches necessary to make it work in Yocto cross-compilation environment;
they will be submitted upstream.

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 ...config-paths-with-PKG_CONFIG_SYSROOT_DIR-.patch |  97 ++++++++++
 ...c-add-host-gi-gi-cross-wrapper-and-gi-ldd.patch | 204 +++++++++++++++++++++
 ...01-giscanner-add-a-use-ldd-wrapper-option.patch |  48 +++++
 ...1-giscanner-add-use-binary-wrapper-option.patch |  52 ++++++
 .../gobject-introspection_1.46.0.bb                | 159 ++++++++++++++++
 5 files changed, 560 insertions(+)
 create mode 100644 meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-Prefix-pkg-config-paths-with-PKG_CONFIG_SYSROOT_DIR-.patch
 create mode 100644 meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-configure.ac-add-host-gi-gi-cross-wrapper-and-gi-ldd.patch
 create mode 100644 meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-a-use-ldd-wrapper-option.patch
 create mode 100644 meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-use-binary-wrapper-option.patch
 create mode 100644 meta/recipes-gnome/gobject-introspection/gobject-introspection_1.46.0.bb

diff --git a/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-Prefix-pkg-config-paths-with-PKG_CONFIG_SYSROOT_DIR-.patch b/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-Prefix-pkg-config-paths-with-PKG_CONFIG_SYSROOT_DIR-.patch
new file mode 100644
index 0000000..5026d81
--- /dev/null
+++ b/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-Prefix-pkg-config-paths-with-PKG_CONFIG_SYSROOT_DIR-.patch
@@ -0,0 +1,97 @@
+From a57604e205e6535acd9989444ad1f5f5038f4fba Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Thu, 8 Oct 2015 18:30:35 +0300
+Subject: [PATCH 1/4] Prefix pkg-config paths with PKG_CONFIG_SYSROOT_DIR
+ environment variable
+
+This environment variable sets the location of sysroot directory in cross-compilation
+environments; if the variable is not set, the prefix will be empty.
+
+Upstream-Status: Pending [review on oe-core list]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+---
+ Makefile-gir.am     | 18 +++++++++---------
+ m4/introspection.m4 |  8 ++++----
+ 2 files changed, 13 insertions(+), 13 deletions(-)
+
+diff --git a/Makefile-gir.am b/Makefile-gir.am
+index 9aca664..09b9360 100644
+--- a/Makefile-gir.am
++++ b/Makefile-gir.am
+@@ -55,8 +55,8 @@ else
+ endif
+ 
+ # glib
+-GLIB_INCLUDEDIR=$(shell "${PKG_CONFIG}" --variable=includedir glib-2.0)/glib-2.0
+-GLIB_LIBDIR=$(shell "${PKG_CONFIG}" --variable=libdir glib-2.0)
++GLIB_INCLUDEDIR=$(PKG_CONFIG_SYSROOT_DIR)$(shell "${PKG_CONFIG}" --variable=includedir glib-2.0)/glib-2.0
++GLIB_LIBDIR=$(PKG_CONFIG_SYSROOT_DIR)$(shell "${PKG_CONFIG}" --variable=libdir glib-2.0)
+ 
+ GLIB_LIBRARY=glib-2.0
+ 
+@@ -92,8 +92,8 @@ GLib-2.0.gir: g-ir-scanner g-ir-compiler$(EXEEXT)
+ gir/DBusGLib-1.0.typelib: GObject-2.0.gir
+ 
+ # gobject
+-GOBJECT_INCLUDEDIR=$(shell "${PKG_CONFIG}" --variable=includedir gobject-2.0)/glib-2.0
+-GOBJECT_LIBDIR=$(shell "${PKG_CONFIG}" --variable=libdir gobject-2.0)
++GOBJECT_INCLUDEDIR=$(PKG_CONFIG_SYSROOT_DIR)$(shell "${PKG_CONFIG}" --variable=includedir gobject-2.0)/glib-2.0
++GOBJECT_LIBDIR=$(PKG_CONFIG_SYSROOT_DIR)$(shell "${PKG_CONFIG}" --variable=libdir gobject-2.0)
+ 
+ GOBJECT_LIBRARY=gobject-2.0
+ 
+@@ -120,8 +120,8 @@ GObject_2_0_gir_FILES = \
+ BUILT_GIRSOURCES += GObject-2.0.gir
+ 
+ # gmodule
+-GMODULE_INCLUDEDIR=$(shell "${PKG_CONFIG}" --variable=includedir gmodule-2.0)/glib-2.0
+-GMODULE_LIBDIR=$(shell "${PKG_CONFIG}" --variable=libdir gmodule-2.0)
++GMODULE_INCLUDEDIR=$(PKG_CONFIG_SYSROOT_DIR)$(shell "${PKG_CONFIG}" --variable=includedir gmodule-2.0)/glib-2.0
++GMODULE_LIBDIR=$(PKG_CONFIG_SYSROOT_DIR)$(shell "${PKG_CONFIG}" --variable=libdir gmodule-2.0)
+ 
+ GMODULE_LIBRARY=gmodule-2.0
+ 
+@@ -146,13 +146,13 @@ GModule_2_0_gir_FILES = $(GLIB_INCLUDEDIR)/gmodule.h \
+ BUILT_GIRSOURCES += GModule-2.0.gir
+ 
+ # gio
+-GIO_INCLUDEDIR=$(shell "${PKG_CONFIG}" --variable=includedir gio-2.0)/glib-2.0
+-GIO_LIBDIR=$(shell "${PKG_CONFIG}" --variable=libdir gio-2.0)
++GIO_INCLUDEDIR=$(PKG_CONFIG_SYSROOT_DIR)$(shell "${PKG_CONFIG}" --variable=includedir gio-2.0)/glib-2.0
++GIO_LIBDIR=$(PKG_CONFIG_SYSROOT_DIR)$(shell "${PKG_CONFIG}" --variable=libdir gio-2.0)
+ 
+ GIO_LIBRARY=gio-2.0
+ 
+ if HAVE_GIO_UNIX
+-GIO_UNIX_HDRS=$(shell "${PKG_CONFIG}" --variable=includedir gio-unix-2.0)/gio-unix-2.0/gio/*.h
++GIO_UNIX_HDRS=$(PKG_CONFIG_SYSROOT_DIR)$(shell "${PKG_CONFIG}" --variable=includedir gio-unix-2.0)/gio-unix-2.0/gio/*.h
+ GIO_UNIX_PACKAGES = gio-unix-2.0
+ else
+ GIO_UNIX_HDRS=
+diff --git a/m4/introspection.m4 b/m4/introspection.m4
+index d89c3d9..b562266 100644
+--- a/m4/introspection.m4
++++ b/m4/introspection.m4
+@@ -56,14 +56,14 @@ m4_define([_GOBJECT_INTROSPECTION_CHECK_INTERNAL],
+     INTROSPECTION_GIRDIR=
+     INTROSPECTION_TYPELIBDIR=
+     if test "x$found_introspection" = "xyes"; then
+-       INTROSPECTION_SCANNER=`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0`
+-       INTROSPECTION_COMPILER=`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0`
+-       INTROSPECTION_GENERATE=`$PKG_CONFIG --variable=g_ir_generate gobject-introspection-1.0`
++       INTROSPECTION_SCANNER=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0`
++       INTROSPECTION_COMPILER=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0`
++       INTROSPECTION_GENERATE=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=g_ir_generate gobject-introspection-1.0`
+        INTROSPECTION_GIRDIR=`$PKG_CONFIG --variable=girdir gobject-introspection-1.0`
+        INTROSPECTION_TYPELIBDIR="$($PKG_CONFIG --variable=typelibdir gobject-introspection-1.0)"
+        INTROSPECTION_CFLAGS=`$PKG_CONFIG --cflags gobject-introspection-1.0`
+        INTROSPECTION_LIBS=`$PKG_CONFIG --libs gobject-introspection-1.0`
+-       INTROSPECTION_MAKEFILE=`$PKG_CONFIG --variable=datadir gobject-introspection-1.0`/gobject-introspection-1.0/Makefile.introspection
++       INTROSPECTION_MAKEFILE=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=datadir gobject-introspection-1.0`/gobject-introspection-1.0/Makefile.introspection
+     fi
+     AC_SUBST(INTROSPECTION_SCANNER)
+     AC_SUBST(INTROSPECTION_COMPILER)
+-- 
+2.7.0
+
diff --git a/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-configure.ac-add-host-gi-gi-cross-wrapper-and-gi-ldd.patch b/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-configure.ac-add-host-gi-gi-cross-wrapper-and-gi-ldd.patch
new file mode 100644
index 0000000..6afefab
--- /dev/null
+++ b/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-configure.ac-add-host-gi-gi-cross-wrapper-and-gi-ldd.patch
@@ -0,0 +1,204 @@
+From c6e4f83c373b577166a7e46130ce8ff025ee8515 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Mon, 19 Oct 2015 18:29:21 +0300
+Subject: [PATCH] configure.ac: add host-gi, gi-cross-wrapper, gi-ldd-wrapper
+ and introspection-data options
+
+With the first option, gobject-introspection tools (g-ir-doc-tool and g-ir-scanner)
+that are already installed in the host system will be used for building the source tree.
+
+With the second option, g-ir-scanner will be instructed to use an executable
+wrapper to run binaries it's producing, and g-ir-compiler will be run
+through the same wrapper (host system's g-ir-compiler cannot be used because
+it's producing architecture-specific output).
+
+With the third option, giscanner will be instructed to use a special ldd
+command instead of system's ldd (which does not work when the binary to inspect
+is compiled for a different architecture).
+
+With the fourth option, it is possible to disable building of introspection data
+(.gir and .typelib files), which may be difficult or impossible in cross-compilation
+environments, because of lack of emulation (or native hardware) for the target architecture
+on which the target binaries can be run.
+
+These options are useful when cross-compiling for a different target architecture.
+
+Upstream-Status: Pending [review on oe-core list]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+---
+ Makefile.am       |  2 ++
+ common.mk         | 39 +++++++++++++++++++++++++++++++++++++++
+ configure.ac      | 42 ++++++++++++++++++++++++++++++++++++++++++
+ tests/Makefile.am |  5 ++++-
+ 4 files changed, 87 insertions(+), 1 deletion(-)
+
+diff --git a/Makefile.am b/Makefile.am
+index 437c673..1eb3545 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -21,7 +21,9 @@ include Makefile-cmph.am
+ include Makefile-girepository.am
+ include Makefile-giscanner.am
+ include Makefile-examples.am
++if BUILD_INTROSPECTION_DATA
+ include Makefile-gir.am
++endif
+ include Makefile-tools.am
+ include Makefile-msvcproj.am
+ 
+diff --git a/common.mk b/common.mk
+index e26c637..9f3a65f 100644
+--- a/common.mk
++++ b/common.mk
+@@ -6,6 +6,15 @@
+ # module itself.
+ #
+ 
++if USE_HOST_GI
++INTROSPECTION_SCANNER = \
++    env PATH="$(PATH)" \
++        LPATH=.libs \
++        CC="$(CC)" \
++        PYTHONPATH=$(top_builddir):$(top_srcdir) \
++        UNINSTALLED_INTROSPECTION_BUILDDIR=$(top_builddir) \
++        g-ir-scanner
++else
+ INTROSPECTION_SCANNER = \
+     env PATH=".libs:$(PATH)" \
+         LPATH=.libs \
+@@ -14,9 +23,24 @@ INTROSPECTION_SCANNER = \
+         UNINSTALLED_INTROSPECTION_SRCDIR=$(top_srcdir) \
+         UNINSTALLED_INTROSPECTION_BUILDDIR=$(top_builddir) \
+         $(top_builddir)/g-ir-scanner
++endif
++
++if USE_CROSS_WRAPPER
++CROSS_WRAPPER_ARG = --use-binary-wrapper=$(GI_CROSS_WRAPPER)
++else
++CROSS_WRAPPER_ARG =
++endif
++
++if USE_LDD_WRAPPER
++LDD_WRAPPER_ARG = --use-ldd-wrapper=$(GI_LDD_WRAPPER)
++else
++LDD_WRAPPER_ARG =
++endif
+ 
+ INTROSPECTION_SCANNER_ARGS = \
+     --verbose \
++    $(CROSS_WRAPPER_ARG) \
++    $(LDD_WRAPPER_ARG) \
+     -I$(top_srcdir) \
+     --add-include-path=$(srcdir) \
+     --add-include-path=$(top_srcdir)/gir \
+@@ -24,9 +48,15 @@ INTROSPECTION_SCANNER_ARGS = \
+     --add-include-path=$(top_builddir) \
+     --add-include-path=$(top_builddir)/gir
+ 
++if USE_CROSS_WRAPPER
++INTROSPECTION_COMPILER = \
++    env PATH=".libs:$(PATH)" \
++        $(GI_CROSS_WRAPPER) $(top_builddir)/.libs/g-ir-compiler$(EXEEXT)
++else
+ INTROSPECTION_COMPILER = \
+     env PATH=".libs:$(PATH)" \
+         $(top_builddir)/g-ir-compiler$(EXEEXT)
++endif
+ 
+ INTROSPECTION_COMPILER_ARGS = \
+     --includedir=$(srcdir) \
+@@ -35,6 +65,14 @@ INTROSPECTION_COMPILER_ARGS = \
+     --includedir=$(top_builddir) \
+     --includedir=$(top_builddir)/gir
+ 
++if USE_HOST_GI
++INTROSPECTION_DOCTOOL = \
++    env PATH="$(PATH)" \
++        LPATH=.libs \
++        PYTHONPATH=$(top_builddir):$(top_srcdir) \
++        UNINSTALLED_INTROSPECTION_BUILDDIR=$(top_builddir) \
++        g-ir-doc-tool
++else
+ INTROSPECTION_DOCTOOL = \
+     env PATH=".libs:$(PATH)" \
+         LPATH=.libs \
+@@ -42,6 +80,7 @@ INTROSPECTION_DOCTOOL = \
+         UNINSTALLED_INTROSPECTION_SRCDIR=$(top_srcdir) \
+         UNINSTALLED_INTROSPECTION_BUILDDIR=$(top_builddir) \
+         $(top_builddir)/g-ir-doc-tool
++endif
+ 
+ INTROSPECTION_DOCTOOL_ARGS = \
+     --add-include-path=$(srcdir) \
+diff --git a/configure.ac b/configure.ac
+index b11596b..d78ae52 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -347,6 +347,48 @@ fi
+ 
+ AC_SUBST(EXTRA_LINK_FLAGS)
+ 
++AC_ARG_ENABLE([host-gi],
++[AS_HELP_STRING([--enable-host-gi],[Use gobject introspection tools installed in the host system (useful when cross-compiling)])],
++[case "${enableval}" in
++  yes) host_gi=true ;;
++  no)  host_gi=false ;;
++  *) AC_MSG_ERROR([bad value ${enableval} for --enable-host-gi]) ;;
++esac],[host_gi=false])
++AM_CONDITIONAL([USE_HOST_GI], [test x$host_gi = xtrue])
++
++AC_ARG_ENABLE([gi-cross-wrapper],
++[AS_HELP_STRING([--enable-gi-cross-wrapper=path],[Use a wrapper to run gicompiler and binaries produced by giscanner (useful when cross-compiling)])],
++[
++GI_CROSS_WRAPPER="${enableval}"
++use_wrapper=true
++],[
++GI_CROSS_WRAPPER=""
++use_wrapper=false
++])
++AC_SUBST(GI_CROSS_WRAPPER)
++AM_CONDITIONAL([USE_CROSS_WRAPPER], [test x$use_wrapper = xtrue])
++
++AC_ARG_ENABLE([gi-ldd-wrapper],
++[AS_HELP_STRING([--enable-gi-ldd-wrapper=path],[Use a ldd wrapper instead of system's ldd command in giscanner (useful when cross-compiling)])],
++[
++GI_LDD_WRAPPER="${enableval}"
++use_ldd_wrapper=true
++],[
++GI_LDD_WRAPPER=""
++use_ldd_wrapper=false
++])
++AC_SUBST(GI_LDD_WRAPPER)
++AM_CONDITIONAL([USE_LDD_WRAPPER], [test x$use_ldd_wrapper = xtrue])
++
++AC_ARG_ENABLE([introspection-data],
++[AS_HELP_STRING([--enable-introspection-data],[Build introspection data (.gir and .typelib files) in addition to library and tools])],
++[case "${enableval}" in
++  yes) introspection_data=true ;;
++  no)  introspection_data=false ;;
++  *) AC_MSG_ERROR([bad value ${enableval} for --enable-introspection-data]) ;;
++esac],[introspection_data=true])
++AM_CONDITIONAL([BUILD_INTROSPECTION_DATA], [test x$introspection_data = xtrue])
++
+ AC_CONFIG_FILES([
+ Makefile
+ tests/Makefile
+diff --git a/tests/Makefile.am b/tests/Makefile.am
+index bdd0fa7..75dd3c9 100644
+--- a/tests/Makefile.am
++++ b/tests/Makefile.am
+@@ -1,6 +1,9 @@
+ include $(top_srcdir)/common.mk
+ 
+-SUBDIRS = . scanner repository offsets warn
++SUBDIRS = . scanner repository warn
++if BUILD_INTROSPECTION_DATA
++SUBDIRS += offsets
++endif
+ 
+ EXTRA_DIST=
+ BUILT_SOURCES=
+-- 
+2.6.2
+
diff --git a/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-a-use-ldd-wrapper-option.patch b/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-a-use-ldd-wrapper-option.patch
new file mode 100644
index 0000000..f923dcc
--- /dev/null
+++ b/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-a-use-ldd-wrapper-option.patch
@@ -0,0 +1,48 @@
+From 291a92f200981a772b2d03739dffb5926a82c5a5 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Fri, 30 Oct 2015 16:28:46 +0200
+Subject: [PATCH 1/2] giscanner: add a --use-ldd-wrapper option
+
+This is useful in cross-compile environments where system's ldd
+command does not work on binaries built for a different architecture
+
+Upstream-Status: Pending [review in oe-core]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+---
+ giscanner/scannermain.py | 3 +++
+ giscanner/shlibs.py      | 4 +++-
+ 2 files changed, 6 insertions(+), 1 deletion(-)
+
+diff --git a/giscanner/scannermain.py b/giscanner/scannermain.py
+index e37d3e3..b8fff5f 100755
+--- a/giscanner/scannermain.py
++++ b/giscanner/scannermain.py
+@@ -121,6 +121,9 @@ def _get_option_parser():
+     parser.add_option("", "--use-binary-wrapper",
+                       action="store", dest="wrapper", default=None,
+                       help="wrapper to use for running programs (useful when cross-compiling)")
++    parser.add_option("", "--use-ldd-wrapper",
++                      action="store", dest="ldd_wrapper", default=None,
++                      help="wrapper to use instead of ldd (useful when cross-compiling)")
+     parser.add_option("", "--program-arg",
+                       action="append", dest="program_args", default=[],
+                       help="extra arguments to program")
+diff --git a/giscanner/shlibs.py b/giscanner/shlibs.py
+index 1ad75ee..41117c6 100644
+--- a/giscanner/shlibs.py
++++ b/giscanner/shlibs.py
+@@ -100,7 +100,9 @@ def _resolve_non_libtool(options, binary, libraries):
+             args.extend(libtool)
+             args.append('--mode=execute')
+         platform_system = platform.system()
+-        if platform_system == 'Darwin':
++        if options.ldd_wrapper:
++            args.extend([options.ldd_wrapper, binary.args[0]])
++        elif platform_system == 'Darwin':
+             args.extend(['otool', '-L', binary.args[0]])
+         else:
+             args.extend(['ldd', binary.args[0]])
+-- 
+2.1.4
+
diff --git a/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-use-binary-wrapper-option.patch b/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-use-binary-wrapper-option.patch
new file mode 100644
index 0000000..e1241a9
--- /dev/null
+++ b/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-use-binary-wrapper-option.patch
@@ -0,0 +1,52 @@
+From 2322f36056265f809aaffb74fcf5ac0c83129752 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Mon, 19 Oct 2015 18:26:40 +0300
+Subject: [PATCH 2/4] giscanner: add --use-binary-wrapper option
+
+With this option, giscanner will use a wrapper executable to run
+binaries it's producing, instead of running them directly. This
+is useful when binaries are cross-compiled and cannot be run directly,
+but they can be run using for example QEMU emulation.
+
+Upstream-Status: Pending [review on oe-core list]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+---
+ giscanner/scannermain.py | 14 ++++++++++++++
+ 1 file changed, 14 insertions(+)
+
+diff --git a/giscanner/scannermain.py b/giscanner/scannermain.py
+index b36284d..e37d3e3 100755
+--- a/giscanner/scannermain.py
++++ b/giscanner/scannermain.py
+@@ -118,6 +118,9 @@ def _get_option_parser():
+     parser.add_option("", "--program",
+                       action="store", dest="program", default=None,
+                       help="program to execute")
++    parser.add_option("", "--use-binary-wrapper",
++                      action="store", dest="wrapper", default=None,
++                      help="wrapper to use for running programs (useful when cross-compiling)")
+     parser.add_option("", "--program-arg",
+                       action="append", dest="program_args", default=[],
+                       help="extra arguments to program")
+@@ -406,6 +409,17 @@ def create_binary(transformer, options, args):
+                                               gdump_parser.get_error_quark_functions())
+ 
+     shlibs = resolve_shlibs(options, binary, options.libraries)
++    if options.wrapper:
++        # The wrapper needs the binary itself, not the libtool wrapper script,
++        # so we check if libtool has sneaked the binary into .libs subdirectory
++        # and adjust the path accordingly
++	import os.path
++        dir_name, binary_name  = os.path.split(binary.args[0])
++        libtool_binary = os.path.join(dir_name, '.libs', binary_name)
++        if os.path.exists(libtool_binary):
++	    binary.args[0] = libtool_binary
++	# Then prepend the wrapper to the command line to execute
++        binary.args = [options.wrapper] + binary.args
+     gdump_parser.set_introspection_binary(binary)
+     gdump_parser.parse()
+     return shlibs
+-- 
+2.1.4
+
diff --git a/meta/recipes-gnome/gobject-introspection/gobject-introspection_1.46.0.bb b/meta/recipes-gnome/gobject-introspection/gobject-introspection_1.46.0.bb
new file mode 100644
index 0000000..d51e607
--- /dev/null
+++ b/meta/recipes-gnome/gobject-introspection/gobject-introspection_1.46.0.bb
@@ -0,0 +1,159 @@
+HOMEPAGE = "http://gnome.org"
+BUGTRACKER = "https://bugzilla.gnome.org/"
+SECTION = "libs"
+LICENSE = "LGPLv2+ & GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=90d577535a3898e1ae5dbf0ae3509a8c \
+                    file://tools/compiler.c;endline=20;md5=fc5007fc20022720e6c0b0cdde41fabd \
+                    file://giscanner/sourcescanner.c;endline=22;md5=194d6e0c1d00662f32d030ce44de8d39 \
+                    file://girepository/giregisteredtypeinfo.c;endline=21;md5=661847611ae6979465415f31a759ba27"
+
+SRC_URI = "${GNOME_MIRROR}/${BPN}/1.46/${BPN}-${PV}.tar.xz \
+           file://0001-Prefix-pkg-config-paths-with-PKG_CONFIG_SYSROOT_DIR-.patch \
+           file://0001-giscanner-add-use-binary-wrapper-option.patch \
+           file://0001-giscanner-add-a-use-ldd-wrapper-option.patch \
+           file://0001-configure.ac-add-host-gi-gi-cross-wrapper-and-gi-ldd.patch \
+           "
+SRC_URI[md5sum] = "adb40a31c7c80b65b0f4c8fd71b493dc"
+SRC_URI[sha256sum] = "6658bd3c2b8813eb3e2511ee153238d09ace9d309e4574af27443d87423e4233"
+
+inherit autotools pkgconfig gtk-doc pythonnative qemu
+BBCLASSEXTEND = "native"
+
+# necessary to let the call for python-config from configure.ac succeed
+export BUILD_SYS
+export HOST_SYS
+export STAGING_INCDIR
+export STAGING_LIBDIR
+
+# needed for writing out the qemu wrapper script
+export STAGING_DIR_HOST
+export B
+
+DEPENDS_append = " libffi zlib glib-2.0 python"
+
+# target build needs qemu to run temporary introspection binaries created
+# on the fly by g-ir-scanner and a native version of itself to run
+# native versions of its own tools during build.
+# Also prelink-rtld is used to find out library dependencies of introspection binaries
+# (standard ldd doesn't work when cross-compiling).
+DEPENDS_class-target_append = " gobject-introspection-native qemu-native prelink-native"
+
+SSTATE_SCAN_FILES += "g-ir-scanner-qemuwrapper g-ir-scanner-wrapper g-ir-compiler-wrapper g-ir-scanner-lddwrapper Gio-2.0.gir"
+
+do_configure_prepend_class-native() {
+        # Tweak the native python scripts so that they don't refer to the
+        # full path of native python binary (the solution is taken from glib-2.0 recipe)
+        # This removes the risk of exceeding Linux kernel's shebang line limit (128 bytes)
+        sed -i -e '1s,#!.*,#!${USRBINPATH}/env nativepython,' ${S}/tools/g-ir-tool-template.in
+}
+
+do_configure_prepend_class-target() {
+        # Write out a qemu wrapper that will be given to gi-scanner so that it
+        # can run target helper binaries through that.
+        qemu_binary="${@qemu_wrapper_cmdline(d, '$STAGING_DIR_HOST', ['\$GIR_EXTRA_LIBS_PATH','.libs','$STAGING_DIR_HOST/${libdir}','$STAGING_DIR_HOST/${base_libdir}'])}"
+        cat > ${B}/g-ir-scanner-qemuwrapper << EOF
+#!/bin/sh
+$qemu_binary "\$@"
+if [ \$? -ne 0 ]; then
+    echo "If the above error message is about missing .so libraries, then setting up GIR_EXTRA_LIBS_PATH in the recipe should help."
+    echo "(typically like this: GIR_EXTRA_LIBS_PATH=\"$""{B}/something/.libs\" )"
+    exit 1
+fi
+EOF
+        chmod +x ${B}/g-ir-scanner-qemuwrapper
+
+        # Write out a wrapper for g-ir-scanner itself, which will be used when building introspection files
+        # for glib-based packages. This wrapper calls the native version of the scanner, and tells it to use
+        # a qemu wrapper for running transient target binaries produced by the scanner, and an include directory 
+        # from the target sysroot.
+        cat > ${B}/g-ir-scanner-wrapper << EOF
+#!/bin/sh
+# This prevents g-ir-scanner from writing cache data to $HOME
+export GI_SCANNER_DISABLE_CACHE=1
+
+g-ir-scanner --use-binary-wrapper=${STAGING_BINDIR}/g-ir-scanner-qemuwrapper --use-ldd-wrapper=${STAGING_BINDIR}/g-ir-scanner-lddwrapper --add-include-path=${STAGING_DATADIR}/gir-1.0 "\$@"
+EOF
+        chmod +x ${B}/g-ir-scanner-wrapper
+
+        # Write out a wrapper for g-ir-compiler, which runs the target version of it through qemu.
+        # g-ir-compiler writes out the raw content of a C struct to disk, and therefore is architecture dependent.
+        cat > ${B}/g-ir-compiler-wrapper << EOF
+#!/bin/sh
+${STAGING_BINDIR}/g-ir-scanner-qemuwrapper ${STAGING_BINDIR}/g-ir-compiler "\$@"
+EOF
+        chmod +x ${B}/g-ir-compiler-wrapper
+
+        # Write out a wrapper to use instead of ldd, which does not work when a binary is built
+        # for a different architecture
+        cat > ${B}/g-ir-scanner-lddwrapper << EOF
+#!/bin/sh
+prelink-rtld --root=$STAGING_DIR_HOST "\$@"
+EOF
+        chmod +x ${B}/g-ir-scanner-lddwrapper
+
+        # Also tweak the target python scripts so that they don't refer to the
+        # native version of python binary (the solution is taken from glib-2.0 recipe)
+        sed -i -e '1s,#!.*,#!${USRBINPATH}/env python,' ${S}/tools/g-ir-tool-template.in
+}
+
+# Configure target build to use native tools of itself and to use a qemu wrapper
+# and optionally to generate introspection data
+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)} \
+                             "
+
+
+do_compile_prepend_class-target() {
+        # This prevents g-ir-scanner from writing cache data to $HOME
+        export GI_SCANNER_DISABLE_CACHE=1
+
+        # Needed to run g-ir unit tests, which won't be able to find the built libraries otherwise
+        export GIR_EXTRA_LIBS_PATH=$B/.libs
+}
+
+# Our wrappers need to be available system-wide, because they will be used 
+# to build introspection files for all other gobject-based packages
+do_install_append_class-target() {
+        install -d ${D}${bindir}/
+        install ${B}/g-ir-scanner-qemuwrapper ${D}${bindir}/
+        install ${B}/g-ir-scanner-wrapper ${D}${bindir}/
+        install ${B}/g-ir-compiler-wrapper ${D}${bindir}/
+        install ${B}/g-ir-scanner-lddwrapper ${D}${bindir}/
+}
+
+# .typelib files are needed at runtime and so they go to the main package
+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"
+
+# These are used by gobject-based packages
+# to generate transient introspection binaries
+FILES_${PN}-dev_append = " ${datadir}/gobject-introspection-1.0/gdump.c \
+               ${datadir}/gobject-introspection-1.0/Makefile.introspection"
+
+# These are used by dependent packages (e.g. pygobject) to build their
+# testsuites.
+FILES_${PN}-dev_append = " ${datadir}/gobject-introspection-1.0/tests/*.c \
+                   ${datadir}/gobject-introspection-1.0/tests/*.h"
+
+FILES_${PN}-dbg += "${libdir}/gobject-introspection/giscanner/.debug/"
+FILES_${PN}-staticdev += "${libdir}/gobject-introspection/giscanner/*.a"
+
+# we need target versions of introspection tools in sysroot so that they can be run via qemu
+# when building introspection files in other packages
+SYSROOT_PREPROCESS_FUNCS_append_class-target += "gi_binaries_sysroot_preprocess"
+
+gi_binaries_sysroot_preprocess() {
+        sysroot_stage_dir ${D}${bindir} ${SYSROOT_DESTDIR}${bindir}
+
+        # Also, tweak the binary names in introspection pkgconfig file, so that it picks up our 
+        # wrappers which do the cross-compile and qemu magic.
+        sed -i \
+           -e "s|g_ir_scanner=.*|g_ir_scanner=${bindir}/g-ir-scanner-wrapper|" \
+           -e "s|g_ir_compiler=.*|g_ir_compiler=${bindir}/g-ir-compiler-wrapper|" \
+           ${SYSROOT_DESTDIR}${libdir}/pkgconfig/gobject-introspection-1.0.pc
+}
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 05/24] gtk-doc-stub: remove introspection stubs
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (3 preceding siblings ...)
  2016-03-09 15:01 ` [PATCH 04/24] gobject-introspection: add the recipe Alexander Kanavin
@ 2016-03-09 15:01 ` Alexander Kanavin
  2016-03-09 15:01 ` [PATCH 06/24] gobject-introspection.bbclass: add a class that enables gobject introspection Alexander Kanavin
                   ` (18 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:01 UTC (permalink / raw)
  To: openembedded-core

As we provide the full introspection support, we need to remove
the stubs from this package that conflict with it.

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 ...t-Import-introspection-stub-machinery-too.patch | 305 +++++++++++++++++++++
 .../recipes-gnome/gtk-doc-stub/gtk-doc-stub_git.bb |   6 +-
 2 files changed, 309 insertions(+), 2 deletions(-)
 create mode 100644 meta/recipes-gnome/gtk-doc-stub/files/0001-Revert-Import-introspection-stub-machinery-too.patch

diff --git a/meta/recipes-gnome/gtk-doc-stub/files/0001-Revert-Import-introspection-stub-machinery-too.patch b/meta/recipes-gnome/gtk-doc-stub/files/0001-Revert-Import-introspection-stub-machinery-too.patch
new file mode 100644
index 0000000..80b0521
--- /dev/null
+++ b/meta/recipes-gnome/gtk-doc-stub/files/0001-Revert-Import-introspection-stub-machinery-too.patch
@@ -0,0 +1,305 @@
+From d636be29bf95396b4e27fcd17ff84cb7091cca91 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Thu, 8 Oct 2015 15:37:40 +0300
+Subject: [PATCH] Revert "Import introspection stub machinery too"
+
+This reverts commit 3dfd0a09de696ec8c544762747f8a0f77153622e.
+As we provide the full introspection support, we need to remove
+the stubs from this package that conflict with it.
+
+Upstream-Status: Pending [review on oe-core list]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ Makefile               |   4 --
+ Makefile.introspection | 163 -------------------------------------------------
+ introspection.m4       |  96 -----------------------------
+ 3 files changed, 263 deletions(-)
+ delete mode 100644 Makefile.introspection
+ delete mode 100644 introspection.m4
+
+diff --git a/Makefile b/Makefile
+index 7cb6ce5..ad4231a 100644
+--- a/Makefile
++++ b/Makefile
+@@ -23,7 +23,3 @@ install: $(bin_programs)
+ 
+ 	mkdir -p $(DESTDIR)$(datarootdir)/aclocal/
+ 	install -m 0644 $(srcdir)/gtk-doc.m4 $(DESTDIR)$(datarootdir)/aclocal/gtk-doc.m4
+-
+-	mkdir -p $(DESTDIR)$(datarootdir)/gobject-introspection-1.0
+-	install -m 0644 $(srcdir)/Makefile.introspection $(DESTDIR)$(datarootdir)/gobject-introspection-1.0/Makefile.introspection
+-	install -m 0644 $(srcdir)/introspection.m4 $(DESTDIR)$(datarootdir)/aclocal/introspection.m4
+diff --git a/Makefile.introspection b/Makefile.introspection
+deleted file mode 100644
+index 755dd15..0000000
+--- a/Makefile.introspection
++++ /dev/null
+@@ -1,163 +0,0 @@
+-# -*- Mode: make -*-
+-# Copyright 2009-2010 Johan Dahlin
+-#
+-# This file is free software; the author(s) gives unlimited
+-# permission to copy and/or distribute it, with or without
+-# modifications, as long as this notice is preserved.
+-#
+-# * Input variables:
+-#
+-#   INTROSPECTION_GIRS - List of GIRS that should be generated
+-#   INTROSPECTION_SCANNER - Command to invoke scanner, normally set by
+-#      GOBJECT_INTROSPECTION_REQUIRE/CHECK() in introspection.m4
+-#   INTROSPECTION_SCANNER_ARGS - Additional args to pass in to the scanner
+-#   INTROSPECTION_SCANNER_ENV - Environment variables to set before running
+-#      the scanner
+-#   INTROSPECTION_COMPILER - Command to invoke compiler, normally set by
+-#      GOBJECT_INTROSPECTION_REQUIRE/CHECK() in introspection.m4
+-#   INTROSPECTION_COMPILER_ARGS - Additional args to pass in to the compiler
+-#
+-# * Simple tutorial
+-#
+-# Add this to configure.ac:
+-#   -Wno-portability to AM_INIT_AUTOMAKE
+-#   GOBJECT_INTROSPECTION_CHECK([0.6.7])
+-#
+-# Add this to Makefile.am where your library/program is built:
+-#   include $(INTROSPECTION_MAKEFILE)
+-#   INTROSPECTION_GIRS = YourLib-1.0.gir
+-#   YourLib_1_0_gir_NAMESPACE = YourLib
+-#   YourLib_1_0_gir_VERSION = 1.0
+-#   YourLib_1_0_gir_LIBS = libyourlib.la
+-#   YourLib_1_0_gir_FILES = $(libyourlib_1_0_SOURCES)
+-#   girdir = $(datadir)/gir-1.0
+-#   dist_gir_DATA = YourLib-1.0.gir
+-#   typelibdir = $(libdir)/girepository-1.0
+-#   typelib_DATA = YourLib-1.0.typelib
+-#   CLEANFILES = $(dist_gir_DATA) $(typelib_DATA)
+-#
+-
+-# Make sure the required variables are set, these should under normal
+-# circumstances come from introspection.m4
+-$(if $(INTROSPECTION_SCANNER),,$(error Need to define INTROSPECTION_SCANNER))
+-$(if $(INTROSPECTION_COMPILER),,$(error Need to define INTROSPECTION_COMPILER))
+-
+-# Private functions
+-
+-## Transform the gir filename to something which can reference through a variable
+-## without automake/make complaining, eg Gtk-2.0.gir -> Gtk_2_0_gir
+-_gir_name = $(subst /,_,$(subst -,_,$(subst .,_,$(1))))
+-
+-# Namespace and Version is either fetched from the gir filename
+-# or the _NAMESPACE/_VERSION variable combo
+-_gir_namespace = $(or $($(_gir_name)_NAMESPACE),$(firstword $(subst -, ,$(notdir $(1)))))
+-_gir_version = $(or $($(_gir_name)_VERSION),$(lastword $(subst -, ,$(1:.gir=))))
+-
+-# _PROGRAM is an optional variable which needs it's own --program argument
+-_gir_program = $(if $($(_gir_name)_PROGRAM),--program=$($(_gir_name)_PROGRAM))
+-
+-# Variables which provides a list of things
+-_gir_libraries = $(foreach lib,$($(_gir_name)_LIBS),--library=$(lib))
+-_gir_packages = $(foreach pkg,$($(_gir_name)_PACKAGES),--pkg=$(pkg))
+-_gir_includes = $(foreach include,$($(_gir_name)_INCLUDES),--include=$(include))
+-_gir_export_packages = $(foreach pkg,$($(_gir_name)_EXPORT_PACKAGES),--pkg-export=$(pkg))
+-
+-# Reuse the LIBTOOL variable from automake if it's set, but
+-# work around MSYS weirdness: When running g-ir-scanner, MSYS changes
+-# a command-line argument --libtool="/bin/sh ../../libtool" into
+-# --libtool=c:/opt/msys/1.0/bin/libtool. So just use sh.exe without path
+-# because we already "know" where the libtool configure produced is.
+-_gir_libtool = $(if $(findstring MINGW32,$(shell uname -s)),--libtool="$(top_builddir)/libtool",$(if $(LIBTOOL),--libtool="$(LIBTOOL)"))
+-
+-# Macros for AM_SILENT_RULES prettiness
+-_gir_verbosity = $(if $(AM_DEFAULT_VERBOSITY),$(AM_DEFAULT_VERBOSITY),1)
+-
+-_gir_silent_scanner_prefix = $(_gir_silent_scanner_prefix_$(V))
+-_gir_silent_scanner_prefix_ = $(_gir_silent_scanner_prefix_$(_gir_verbosity))
+-_gir_silent_scanner_prefix_0 = @echo "  GISCAN $(1)";
+-_gir_silent_scanner_opts = $(_gir_silent_scanner_opts_$(V))
+-_gir_silent_scanner_opts_ = $(_gir_silent_scanner_opts_$(_gir_verbosity))
+-_gir_silent_scanner_opts_0 = --quiet
+-
+-_gir_silent_compiler = $(_gir_silent_compiler_$(V))
+-_gir_silent_compiler_ = $(_gir_silent_compiler_$(_gir_verbosity))
+-_gir_silent_compiler_0 = @echo "  GICOMP $(1)";
+-
+-#
+-# Creates a GIR by scanning C headers/sources
+-# $(1) - Name of the gir file (output)
+-#
+-# If output is Gtk-2.0.gir then you should name the variables like
+-# Gtk_2_0_gir_NAMESPACE, Gtk_2_0_gir_VERSION etc.
+-# Required variables:
+-# FILES - C sources and headers which should be scanned
+-#
+-# One of these variables are required:
+-# LIBS - Library where the symbol represented in the gir can be found
+-# PROGRAM - Program where the symbol represented in the gir can be found
+-#
+-# Optional variables
+-# NAMESPACE - Namespace of the gir, first letter capital,
+-#   rest should be lower case, for instance: 'Gtk', 'Clutter', 'ClutterGtk'.
+-#   If not present the namespace will be fetched from the gir filename,
+-#   the part before the first dash. For 'Gtk-2.0', namespace will be 'Gtk'.
+-# VERSION - Version of the gir, if not present, will be fetched from gir
+-# filename, the part after the first dash. For 'Gtk-2.0', version will be '2.0'.
+-# LIBTOOL - Command to invoke libtool, usually set by automake
+-# SCANNERFLAGS - Flags to pass in to the scanner, see g-ir-scanner(1) for a list
+-# CFLAGS - Flags to pass in to the parser when scanning headers
+-# LDFLAGS - Linker flags used by the scanner
+-# PACKAGES - list of pkg-config names which cflags are required to parse
+-#   the headers of this gir
+-# INCLUDES - Gir files to include without the .gir suffix, for instance
+-#   GLib-2.0, Gtk-2.0. This is needed for all libraries which you depend on that
+-#   provides introspection information.
+-# EXPORT_PACKAGES - list of pkg-config names that are provided by this gir.
+-#   By default the names in the PACKAGES variable will be used.
+-#
+-
+-define introspection-scanner
+-
+-# Basic sanity check, to make sure required variables are set
+-$(if $($(_gir_name)_FILES),,$(error Need to define $(_gir_name)_FILES))
+-$(if $(or $(findstring --header-only,$($(_gir_name)_SCANNERFLAGS)),
+-          $($(_gir_name)_LIBS),
+-          $($(_gir_name)_PROGRAM)),,
+-    $(error Need to define $(_gir_name)_LIBS or $(_gir_name)_PROGRAM))
+-
+-# Only dependencies we know are actually filenames goes into _FILES, make
+-# sure these are built before running the scanner. Libraries and programs
+-# needs to be added manually.
+-$(1): $$($(_gir_name)_FILES)
+-	@ $(MKDIR_P) $(dir $(1))
+-	$(_gir_silent_scanner_prefix) $(INTROSPECTION_SCANNER_ENV) $(INTROSPECTION_SCANNER) $(_gir_silent_scanner_opts) \
+-	$(INTROSPECTION_SCANNER_ARGS) \
+-	  --namespace=$(_gir_namespace) \
+-	  --nsversion=$(_gir_version) \
+-	  $(_gir_libtool) \
+-	  $(_gir_packages) \
+-	  $(_gir_includes) \
+-	  $(_gir_export_packages) \
+-	  $(_gir_program) \
+-	  $(_gir_libraries) \
+-	  $($(_gir_name)_SCANNERFLAGS) \
+-	  $($(_gir_name)_CFLAGS) \
+-	  $($(_gir_name)_LDFLAGS) \
+-	  $$^ \
+-	  --output $(1)
+-endef
+-
+-$(foreach gir,$(INTROSPECTION_GIRS),$(eval $(call introspection-scanner,$(gir))))
+-
+-#
+-# Compiles a gir into a typelib
+-# $(1): gir filename (input)
+-# $(2): typelib filename (output)
+-#
+-define introspection-compiler
+-$(_gir_silent_compiler) $(INTROSPECTION_COMPILER) $(INTROSPECTION_COMPILER_ARGS) --includedir=. $(1) -o $(2)
+-endef
+-
+-# Simple rule to compile a typelib.
+-%.typelib: %.gir
+-	$(call introspection-compiler,$<,$@)
+diff --git a/introspection.m4 b/introspection.m4
+deleted file mode 100644
+index d89c3d9..0000000
+--- a/introspection.m4
++++ /dev/null
+@@ -1,96 +0,0 @@
+-dnl -*- mode: autoconf -*-
+-dnl Copyright 2009 Johan Dahlin
+-dnl
+-dnl This file is free software; the author(s) gives unlimited
+-dnl permission to copy and/or distribute it, with or without
+-dnl modifications, as long as this notice is preserved.
+-dnl
+-
+-# serial 1
+-
+-m4_define([_GOBJECT_INTROSPECTION_CHECK_INTERNAL],
+-[
+-    AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first
+-    AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first
+-    AC_BEFORE([LT_INIT],[$0])dnl setup libtool first
+-
+-    dnl enable/disable introspection
+-    m4_if([$2], [require],
+-    [dnl
+-        enable_introspection=yes
+-    ],[dnl
+-        AC_ARG_ENABLE(introspection,
+-                  AS_HELP_STRING([--enable-introspection[=@<:@no/auto/yes@:>@]],
+-                                 [Enable introspection for this build]),, 
+-                                 [enable_introspection=auto])
+-    ])dnl
+-
+-    AC_MSG_CHECKING([for gobject-introspection])
+-
+-    dnl presence/version checking
+-    AS_CASE([$enable_introspection],
+-    [no], [dnl
+-        found_introspection="no (disabled, use --enable-introspection to enable)"
+-    ],dnl
+-    [yes],[dnl
+-        PKG_CHECK_EXISTS([gobject-introspection-1.0],,
+-                         AC_MSG_ERROR([gobject-introspection-1.0 is not installed]))
+-        PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1],
+-                         found_introspection=yes,
+-                         AC_MSG_ERROR([You need to have gobject-introspection >= $1 installed to build AC_PACKAGE_NAME]))
+-    ],dnl
+-    [auto],[dnl
+-        PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1], found_introspection=yes, found_introspection=no)
+-	dnl Canonicalize enable_introspection
+-	enable_introspection=$found_introspection
+-    ],dnl
+-    [dnl	
+-        AC_MSG_ERROR([invalid argument passed to --enable-introspection, should be one of @<:@no/auto/yes@:>@])
+-    ])dnl
+-
+-    AC_MSG_RESULT([$found_introspection])
+-
+-    INTROSPECTION_SCANNER=
+-    INTROSPECTION_COMPILER=
+-    INTROSPECTION_GENERATE=
+-    INTROSPECTION_GIRDIR=
+-    INTROSPECTION_TYPELIBDIR=
+-    if test "x$found_introspection" = "xyes"; then
+-       INTROSPECTION_SCANNER=`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0`
+-       INTROSPECTION_COMPILER=`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0`
+-       INTROSPECTION_GENERATE=`$PKG_CONFIG --variable=g_ir_generate gobject-introspection-1.0`
+-       INTROSPECTION_GIRDIR=`$PKG_CONFIG --variable=girdir gobject-introspection-1.0`
+-       INTROSPECTION_TYPELIBDIR="$($PKG_CONFIG --variable=typelibdir gobject-introspection-1.0)"
+-       INTROSPECTION_CFLAGS=`$PKG_CONFIG --cflags gobject-introspection-1.0`
+-       INTROSPECTION_LIBS=`$PKG_CONFIG --libs gobject-introspection-1.0`
+-       INTROSPECTION_MAKEFILE=`$PKG_CONFIG --variable=datadir gobject-introspection-1.0`/gobject-introspection-1.0/Makefile.introspection
+-    fi
+-    AC_SUBST(INTROSPECTION_SCANNER)
+-    AC_SUBST(INTROSPECTION_COMPILER)
+-    AC_SUBST(INTROSPECTION_GENERATE)
+-    AC_SUBST(INTROSPECTION_GIRDIR)
+-    AC_SUBST(INTROSPECTION_TYPELIBDIR)
+-    AC_SUBST(INTROSPECTION_CFLAGS)
+-    AC_SUBST(INTROSPECTION_LIBS)
+-    AC_SUBST(INTROSPECTION_MAKEFILE)
+-
+-    AM_CONDITIONAL(HAVE_INTROSPECTION, test "x$found_introspection" = "xyes")
+-])
+-
+-
+-dnl Usage:
+-dnl   GOBJECT_INTROSPECTION_CHECK([minimum-g-i-version])
+-
+-AC_DEFUN([GOBJECT_INTROSPECTION_CHECK],
+-[
+-  _GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1])
+-])
+-
+-dnl Usage:
+-dnl   GOBJECT_INTROSPECTION_REQUIRE([minimum-g-i-version])
+-
+-
+-AC_DEFUN([GOBJECT_INTROSPECTION_REQUIRE],
+-[
+-  _GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1], [require])
+-])
+-- 
+2.1.4
+
diff --git a/meta/recipes-gnome/gtk-doc-stub/gtk-doc-stub_git.bb b/meta/recipes-gnome/gtk-doc-stub/gtk-doc-stub_git.bb
index 41f4aee..84e49c1 100644
--- a/meta/recipes-gnome/gtk-doc-stub/gtk-doc-stub_git.bb
+++ b/meta/recipes-gnome/gtk-doc-stub/gtk-doc-stub_git.bb
@@ -4,12 +4,14 @@ SECTION = "x11/base"
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f"
 
-PROVIDES = "gtk-doc gobject-introspection-stub"
+PROVIDES = "gtk-doc"
 
 SRCREV = "1dea266593edb766d6d898c79451ef193eb17cfa"
 PV = "1.1+git${SRCPV}"
 
-SRC_URI = "git://git.gnome.org/${BPN}"
+SRC_URI = "git://git.gnome.org/${BPN} \
+	   file://0001-Revert-Import-introspection-stub-machinery-too.patch \
+	  "
 
 S = "${WORKDIR}/git"
 
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 06/24] gobject-introspection.bbclass: add a class that enables gobject introspection
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (4 preceding siblings ...)
  2016-03-09 15:01 ` [PATCH 05/24] gtk-doc-stub: remove introspection stubs Alexander Kanavin
@ 2016-03-09 15:01 ` Alexander Kanavin
  2016-03-09 23:52   ` Andreas Oberritter
  2016-03-09 15:01 ` [PATCH 07/24] vala: enable the use of vapigen by packages with vala support Alexander Kanavin
                   ` (17 subsequent siblings)
  23 siblings, 1 reply; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:01 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/classes/gobject-introspection.bbclass | 39 ++++++++++++++++++++++++++++++
 1 file changed, 39 insertions(+)
 create mode 100644 meta/classes/gobject-introspection.bbclass

diff --git a/meta/classes/gobject-introspection.bbclass b/meta/classes/gobject-introspection.bbclass
new file mode 100644
index 0000000..ef51629
--- /dev/null
+++ b/meta/classes/gobject-introspection.bbclass
@@ -0,0 +1,39 @@
+# Inherit this class in recipes to enable building their introspection files
+
+# This allows disabling introspection support in recipes
+# (and therefore avoiding the use of qemu)
+# if gobject-introspection-data is omitted from DISTRO_FEATURES and MACHINE_FEATURES.
+EXTRA_OECONF_prepend = "${@bb.utils.contains('COMBINED_FEATURES', 'gobject-introspection-data', '--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
+# failes if these are not set
+export BUILD_SYS
+export HOST_SYS
+export STAGING_LIBDIR
+export STAGING_INCDIR
+
+# 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"
+
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 07/24] vala: enable the use of vapigen by packages with vala support
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (5 preceding siblings ...)
  2016-03-09 15:01 ` [PATCH 06/24] gobject-introspection.bbclass: add a class that enables gobject introspection Alexander Kanavin
@ 2016-03-09 15:01 ` Alexander Kanavin
  2016-03-09 15:01 ` [PATCH 08/24] vala.bbclass: remove pre-packaged vapigen.m4 from tarballs Alexander Kanavin
                   ` (16 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:01 UTC (permalink / raw)
  To: openembedded-core

Now that gobject-introspection is supported, generation of .vapi
files for develeloping Vala code against gobject-based libraries
should be supported as well.

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/recipes-devtools/vala/vala.inc                | 34 +++++++++++++++++++
 ...001-vapigen.m4-use-PKG_CONFIG_SYSROOT_DIR.patch | 38 ++++++++++++++++++++++
 meta/recipes-devtools/vala/vala_0.30.1.bb          |  4 ++-
 3 files changed, 75 insertions(+), 1 deletion(-)
 create mode 100644 meta/recipes-devtools/vala/vala/0001-vapigen.m4-use-PKG_CONFIG_SYSROOT_DIR.patch

diff --git a/meta/recipes-devtools/vala/vala.inc b/meta/recipes-devtools/vala/vala.inc
index 43f9bb3..2a8875f 100644
--- a/meta/recipes-devtools/vala/vala.inc
+++ b/meta/recipes-devtools/vala/vala.inc
@@ -3,6 +3,9 @@ DESCRIPTION = "Vala is a C#-like language dedicated to ease GObject programming.
 Vala compiles to plain C and has no runtime environment nor penalities whatsoever."
 SECTION = "devel"
 DEPENDS = "bison-native flex-native libxslt-native glib-2.0"
+
+# vala-native contains a native version of vapigen, which we use instead of the target one
+DEPENDS_append_class-target = " vala-native"
 BBCLASSEXTEND = "native"
 HOMEPAGE = "http://vala-project.org"
 LICENSE = "LGPLv2.1"
@@ -15,3 +18,34 @@ inherit autotools pkgconfig upstream-version-is-even
 
 FILES_${PN} += "${datadir}/${BPN}-${SHRT_VER}/vapi ${libdir}/${BPN}-${SHRT_VER}/"
 FILES_${PN}-doc += "${datadir}/devhelp"
+
+do_configure_prepend_class-target() {
+        # Write out a vapigen wrapper that will be provided by pkg-config file installed in target sysroot
+        # The wrapper will call a native vapigen
+        cat > ${B}/vapigen-wrapper << EOF
+#!/bin/sh
+vapigen-${SHRT_VER} "\$@"
+EOF
+        chmod +x ${B}/vapigen-wrapper
+}
+
+# Vapigen wrapper needs to be available system-wide, because it will be used
+# to build vapi files from all other packages with vala support
+do_install_append_class-target() {
+        install -d ${D}${bindir}/
+        install ${B}/vapigen-wrapper ${D}${bindir}/
+}
+
+
+SYSROOT_PREPROCESS_FUNCS_append_class-target += "vapigen_sysroot_preprocess"
+
+vapigen_sysroot_preprocess() {
+        # Put vapigen wrapper into target sysroot so that it can be used when building vapi files.
+        sysroot_stage_dir ${D}${bindir} ${SYSROOT_DESTDIR}${bindir}
+
+        # Also, tweak the vapigen name in vapigen pkgconfig file, so that it picks up our
+        # wrapper.
+        sed -i \
+           -e "s|vapigen=.*|vapigen=${bindir}/vapigen-wrapper|" \
+           ${SYSROOT_DESTDIR}${datadir}/pkgconfig/vapigen-${SHRT_VER}.pc
+}
diff --git a/meta/recipes-devtools/vala/vala/0001-vapigen.m4-use-PKG_CONFIG_SYSROOT_DIR.patch b/meta/recipes-devtools/vala/vala/0001-vapigen.m4-use-PKG_CONFIG_SYSROOT_DIR.patch
new file mode 100644
index 0000000..ecab0fc
--- /dev/null
+++ b/meta/recipes-devtools/vala/vala/0001-vapigen.m4-use-PKG_CONFIG_SYSROOT_DIR.patch
@@ -0,0 +1,38 @@
+From dbb1c58e86f2af4613f3ac9571d9b163d4bca675 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Fri, 23 Oct 2015 16:13:54 +0300
+Subject: [PATCH] vapigen.m4: use $PKG_CONFIG_SYSROOT_DIR
+
+This is necessary in cross-compiling environments, where directories
+returned by pkg-config should be prefixed with sysroot location.
+
+Upstream-Status: Pending [review in oe-core list]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ vapigen/vapigen.m4 | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/vapigen/vapigen.m4 b/vapigen/vapigen.m4
+index 2c435e7..6228991 100644
+--- a/vapigen/vapigen.m4
++++ b/vapigen/vapigen.m4
+@@ -82,12 +82,12 @@ AC_DEFUN([VAPIGEN_CHECK],
+ 
+   AS_CASE([$enable_vala],
+     [yes], [
+-      VAPIGEN=`$PKG_CONFIG --variable=vapigen $vapigen_pkg_name`
+-      VAPIGEN_MAKEFILE=`$PKG_CONFIG --variable=datadir $vapigen_pkg_name`/vala/Makefile.vapigen
++      VAPIGEN=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=vapigen $vapigen_pkg_name`
++      VAPIGEN_MAKEFILE=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=datadir $vapigen_pkg_name`/vala/Makefile.vapigen
+       AS_IF([test "x$2" = "x"], [
+-          VAPIGEN_VAPIDIR=`$PKG_CONFIG --variable=vapidir $vapigen_pkg_name`
++          VAPIGEN_VAPIDIR=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=vapidir $vapigen_pkg_name`
+         ], [
+-          VAPIGEN_VAPIDIR=`$PKG_CONFIG --variable=vapidir_versioned $vapigen_pkg_name`
++          VAPIGEN_VAPIDIR=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=vapidir_versioned $vapigen_pkg_name`
+         ])
+     ])
+ 
+-- 
+2.1.4
+
diff --git a/meta/recipes-devtools/vala/vala_0.30.1.bb b/meta/recipes-devtools/vala/vala_0.30.1.bb
index 4452298..6394afc 100644
--- a/meta/recipes-devtools/vala/vala_0.30.1.bb
+++ b/meta/recipes-devtools/vala/vala_0.30.1.bb
@@ -1,6 +1,8 @@
 require ${BPN}.inc
 
-SRC_URI += " file://0001-git-version-gen-don-t-append-dirty-if-we-re-not-in-g.patch"
+SRC_URI += " file://0001-git-version-gen-don-t-append-dirty-if-we-re-not-in-g.patch \
+             file://0001-vapigen.m4-use-PKG_CONFIG_SYSROOT_DIR.patch \
+"
 
 SRC_URI[md5sum] = "cc2eb2384fc10038b643753d734a5a51"
 SRC_URI[sha256sum] = "23add78e5c6a5e6df019d4a885c9c79814c9e0b957519ec8a4f4d826c4e5df2c"
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 08/24] vala.bbclass: remove pre-packaged vapigen.m4 from tarballs
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (6 preceding siblings ...)
  2016-03-09 15:01 ` [PATCH 07/24] vala: enable the use of vapigen by packages with vala support Alexander Kanavin
@ 2016-03-09 15:01 ` Alexander Kanavin
  2016-03-09 15:01 ` [PATCH 09/24] avahi-ui: remove the dependency on python-pygtk by disabling avahi-discover Alexander Kanavin
                   ` (15 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:01 UTC (permalink / raw)
  To: openembedded-core

We need to make sure that our fixed vapigen.m4 is used instead.

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/classes/vala.bbclass | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/meta/classes/vala.bbclass b/meta/classes/vala.bbclass
index 9ff664a..615eb37 100644
--- a/meta/classes/vala.bbclass
+++ b/meta/classes/vala.bbclass
@@ -16,3 +16,9 @@ FILES_${PN}-dev += "\
     ${datadir}/vala/vapi/*.deps \
     ${datadir}/gir-1.0 \
 "
+
+# Remove vapigen.m4 that is bundled with tarballs
+# because it does not yet have our cross-compile fixes
+do_configure_prepend() {
+        rm -f ${S}/m4/vapigen.m4
+}
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 09/24] avahi-ui: remove the dependency on python-pygtk by disabling avahi-discover
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (7 preceding siblings ...)
  2016-03-09 15:01 ` [PATCH 08/24] vala.bbclass: remove pre-packaged vapigen.m4 from tarballs Alexander Kanavin
@ 2016-03-09 15:01 ` Alexander Kanavin
  2016-03-09 15:01 ` [PATCH 10/24] python-pygtk: remove the recipe Alexander Kanavin
                   ` (14 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:01 UTC (permalink / raw)
  To: openembedded-core

python-pygtk is removed in a separate commit; the reasons for
that are explained in that commit's message.

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/recipes-connectivity/avahi/avahi-ui_0.6.32.bb | 14 ++++++--------
 1 file changed, 6 insertions(+), 8 deletions(-)

diff --git a/meta/recipes-connectivity/avahi/avahi-ui_0.6.32.bb b/meta/recipes-connectivity/avahi/avahi-ui_0.6.32.bb
index aafb52e..eb8a35e 100644
--- a/meta/recipes-connectivity/avahi/avahi-ui_0.6.32.bb
+++ b/meta/recipes-connectivity/avahi/avahi-ui_0.6.32.bb
@@ -17,11 +17,11 @@ SRC_URI[sha256sum] = "d54991185d514a0aba54ebeb408d7575b60f5818a772e28fa0e18b98bc
 
 DEPENDS += "avahi gtk+ libglade"
 
-AVAHI_GTK = "--enable-gtk --disable-gtk3"
+AVAHI_GTK = "--enable-gtk --disable-gtk3 --disable-pygtk"
 
 S = "${WORKDIR}/avahi-${PV}"
 
-PACKAGES = "${PN} ${PN}-utils ${PN}-dbg ${PN}-dev ${PN}-staticdev ${PN}-doc python-avahi avahi-discover avahi-discover-standalone"
+PACKAGES = "${PN} ${PN}-utils ${PN}-dbg ${PN}-dev ${PN}-staticdev ${PN}-doc python-avahi avahi-discover"
 
 FILES_${PN} = "${libdir}/libavahi-ui*.so.*"
 FILES_${PN}-dev += "${libdir}/libavahi-ui${SOLIBSDEV}"
@@ -30,13 +30,11 @@ FILES_${PN}-staticdev += "${libdir}/libavahi-ui.a"
 FILES_${PN}-utils = "${bindir}/b* ${datadir}/applications/b*"
 
 FILES_python-avahi = "${PYTHON_SITEPACKAGES_DIR}/avahi ${PYTHON_SITEPACKAGES_DIR}/avahi_discover"
-FILES_avahi-discover = "${bindir}/avahi-discover \
-                        ${datadir}/applications/avahi-discover.desktop \
-                        ${datadir}/avahi/interfaces/avahi-discover*"
-FILES_avahi-discover-standalone = "${bindir}/avahi-discover-standalone \
-                                   ${datadir}/avahi/interfaces/avahi-discover.glade"
+FILES_avahi-discover = "${datadir}/applications/avahi-discover.desktop \
+                        ${datadir}/avahi/interfaces/avahi-discover* \
+                        ${bindir}/avahi-discover-standalone \
+                        ${datadir}/avahi/interfaces/avahi-discover.glade"
 
-RDEPENDS_avahi-discover = "python-avahi python-pygtk"
 RDEPENDS_python-avahi = "python-core python-dbus"
 
 
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 10/24] python-pygtk: remove the recipe
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (8 preceding siblings ...)
  2016-03-09 15:01 ` [PATCH 09/24] avahi-ui: remove the dependency on python-pygtk by disabling avahi-discover Alexander Kanavin
@ 2016-03-09 15:01 ` Alexander Kanavin
  2016-03-09 15:01 ` [PATCH 11/24] avahi: enable gobject-introspection Alexander Kanavin
                   ` (13 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:01 UTC (permalink / raw)
  To: openembedded-core

python-pygtk hasn't been updated in several years, is incompatible
with the current version of pygobject, and is generally obsolete as
all modern python gtk apps use introspection directly.

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/conf/distro/include/distro_alias.inc          |  1 -
 .../packagegroups/packagegroup-self-hosted.bb      |  1 -
 .../python/python-pygtk/acinclude.m4               | 90 ----------------------
 .../add-gtk-types.defs-into-gdk.c-dependence.patch | 32 --------
 .../python/python-pygtk/fix-gtkunixprint.patch     | 20 -----
 .../python/python-pygtk/fix-pygtk-2.0.pc.patch     | 13 ----
 .../python/python-pygtk/nodocs.patch               | 15 ----
 .../prevent_to_get_display_during_import.patch     | 16 ----
 .../python/python-pygtk/python-pygtk2/acinclude.m4 | 90 ----------------------
 .../update-dependences-of-defs.c.patch             | 38 ---------
 .../recipes-devtools/python/python-pygtk_2.24.0.bb | 55 -------------
 11 files changed, 371 deletions(-)
 delete mode 100644 meta/recipes-devtools/python/python-pygtk/acinclude.m4
 delete mode 100644 meta/recipes-devtools/python/python-pygtk/add-gtk-types.defs-into-gdk.c-dependence.patch
 delete mode 100644 meta/recipes-devtools/python/python-pygtk/fix-gtkunixprint.patch
 delete mode 100644 meta/recipes-devtools/python/python-pygtk/fix-pygtk-2.0.pc.patch
 delete mode 100644 meta/recipes-devtools/python/python-pygtk/nodocs.patch
 delete mode 100644 meta/recipes-devtools/python/python-pygtk/prevent_to_get_display_during_import.patch
 delete mode 100644 meta/recipes-devtools/python/python-pygtk/python-pygtk2/acinclude.m4
 delete mode 100644 meta/recipes-devtools/python/python-pygtk/update-dependences-of-defs.c.patch
 delete mode 100644 meta/recipes-devtools/python/python-pygtk_2.24.0.bb

diff --git a/meta/conf/distro/include/distro_alias.inc b/meta/conf/distro/include/distro_alias.inc
index d37aefb..c8f9395 100644
--- a/meta/conf/distro/include/distro_alias.inc
+++ b/meta/conf/distro/include/distro_alias.inc
@@ -343,7 +343,6 @@ DISTRO_PN_ALIAS_pn-python-mako = "Fedora=python-mako Opensuse=python-Mako"
 DISTRO_PN_ALIAS_pn-python-pycairo = "Meego=pycairo Fedora=pycairo Ubuntu=pycairo Debian=pycairo"
 DISTRO_PN_ALIAS_pn-python-pycurl = "Debian=python-pycurl Ubuntu=python-pycurl"
 DISTRO_PN_ALIAS_pn-python-pygobject = "Meego=pygobject2 Fedora=pygobject2 Ubuntu=pygobject Debian=pygobject"
-DISTRO_PN_ALIAS_pn-python-pygtk = "Debian=python-gtk2 Fedora=pygtk2 OpenSuSE=python-gtk"
 DISTRO_PN_ALIAS_pn-python-pyrex = "Mandriva=python-pyrex Ubuntu=python-pyrex"
 DISTRO_PN_ALIAS_pn-python-scons = "Fedora=scons OpenSuSE=scons Ubuntu=scons Mandriva=scons Debian=scons"
 DISTRO_PN_ALIAS_pn-python-setuptools = "Mandriva=python-setup OpenSuSE=python-setup-git"
diff --git a/meta/recipes-core/packagegroups/packagegroup-self-hosted.bb b/meta/recipes-core/packagegroups/packagegroup-self-hosted.bb
index 15024cf..68949b7 100644
--- a/meta/recipes-core/packagegroups/packagegroup-self-hosted.bb
+++ b/meta/recipes-core/packagegroups/packagegroup-self-hosted.bb
@@ -189,7 +189,6 @@ RDEPENDS_packagegroup-self-hosted-graphics = "\
     libsdl \
     libsdl-dev \
     libx11-dev \
-    python-pygtk \
     gtk-theme-clearlooks \
     xdg-utils \
     epiphany \
diff --git a/meta/recipes-devtools/python/python-pygtk/acinclude.m4 b/meta/recipes-devtools/python/python-pygtk/acinclude.m4
deleted file mode 100644
index 53518fb..0000000
--- a/meta/recipes-devtools/python/python-pygtk/acinclude.m4
+++ /dev/null
@@ -1,90 +0,0 @@
-## this one is commonly used with AM_PATH_PYTHONDIR ...
-dnl AM_CHECK_PYMOD(MODNAME [,SYMBOL [,ACTION-IF-FOUND [,ACTION-IF-NOT-FOUND]]])
-dnl Check if a module containing a given symbol is visible to python.
-AC_DEFUN(AM_CHECK_PYMOD,
-[AC_REQUIRE([AM_PATH_PYTHON])
-py_mod_var=`echo $1['_']$2 | sed 'y%./+-%__p_%'`
-AC_MSG_CHECKING(for ifelse([$2],[],,[$2 in ])python module $1)
-AC_CACHE_VAL(py_cv_mod_$py_mod_var, [
-ifelse([$2],[], [prog="
-import sys
-try:
-        import $1
-except ImportError:
-        sys.exit(1)
-except:
-        sys.exit(0)
-sys.exit(0)"], [prog="
-import $1
-$1.$2"])
-if $PYTHON -c "$prog" 1>&AC_FD_CC 2>&AC_FD_CC
-  then
-    eval "py_cv_mod_$py_mod_var=yes"
-  else
-    eval "py_cv_mod_$py_mod_var=no"
-  fi
-])
-py_val=`eval "echo \`echo '$py_cv_mod_'$py_mod_var\`"`
-if test "x$py_val" != xno; then
-  AC_MSG_RESULT(yes)
-  ifelse([$3], [],, [$3
-])dnl
-else
-  AC_MSG_RESULT(no)
-  ifelse([$4], [],, [$4
-])dnl
-fi
-])
-
-dnl a macro to check for ability to create python extensions
-dnl  AM_CHECK_PYTHON_HEADERS([ACTION-IF-POSSIBLE], [ACTION-IF-NOT-POSSIBLE])
-dnl function also defines PYTHON_INCLUDES
-AC_DEFUN([AM_CHECK_PYTHON_HEADERS],
-[AC_REQUIRE([AM_PATH_PYTHON])
-AC_MSG_CHECKING(for headers required to compile python extensions)
-dnl deduce PYTHON_INCLUDES
-AC_ARG_WITH(python-includes,
-	[  --with-python-includes=DIR  path to Python includes], py_exec_prefix=$withval)
-if test x$py_exec_prefix != x; then
-PYTHON_INCLUDES="-I${py_exec_prefix}/include/python${PYTHON_VERSION}"
-else
-py_prefix=`$PYTHON -c "import sys; print sys.prefix"`
-py_exec_prefix=`$PYTHON -c "import sys; print sys.exec_prefix"`
-PYTHON_INCLUDES="-I${py_prefix}/include/python${PYTHON_VERSION}"
-if test "$py_prefix" != "$py_exec_prefix"; then
-  PYTHON_INCLUDES="$PYTHON_INCLUDES -I${py_exec_prefix}/include/python${PYTHON_VERSION}"
-fi
-fi
-AC_SUBST(PYTHON_INCLUDES)
-dnl check if the headers exist:
-save_CPPFLAGS="$CPPFLAGS"
-CPPFLAGS="$CPPFLAGS $PYTHON_INCLUDES"
-AC_TRY_CPP([#include <Python.h>],dnl
-[AC_MSG_RESULT(found)
-$1],dnl
-[AC_MSG_RESULT(not found)
-$2])
-CPPFLAGS="$save_CPPFLAGS"
-])
-
-dnl
-dnl JH_ADD_CFLAG(FLAG)
-dnl checks whether the C compiler supports the given flag, and if so, adds
-dnl it to $CFLAGS.  If the flag is already present in the list, then the
-dnl check is not performed.
-AC_DEFUN([JH_ADD_CFLAG],
-[
-case " $CFLAGS " in
-*@<:@\	\ @:>@$1@<:@\	\ @:>@*)
-  ;;
-*)
-  save_CFLAGS="$CFLAGS"
-  CFLAGS="$CFLAGS $1"
-  AC_MSG_CHECKING([whether [$]CC understands $1])
-  AC_TRY_COMPILE([], [], [jh_has_option=yes], [jh_has_option=no])
-  AC_MSG_RESULT($jh_has_option)
-  if test $jh_has_option = no; then
-    CFLAGS="$save_CFLAGS"
-  fi
-  ;;
-esac])
diff --git a/meta/recipes-devtools/python/python-pygtk/add-gtk-types.defs-into-gdk.c-dependence.patch b/meta/recipes-devtools/python/python-pygtk/add-gtk-types.defs-into-gdk.c-dependence.patch
deleted file mode 100644
index df0f9cd..0000000
--- a/meta/recipes-devtools/python/python-pygtk/add-gtk-types.defs-into-gdk.c-dependence.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-Upstream-Status: Submitted
-
-add gtk-types.defs into gdk.c dependence
-
-gdk.c depends on gtk-types.defs but
-gdk/Makefile.am miss this. This will cause
-build error sometimes when built
-with multi-jobbing, so add gtk-types.defs into
-gdk.c dependence.
-
-Signed-off-by: Song.Li <Song.Li@windriver.com>
-Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
----
- gtk/Makefile.am |    2 +-
- 1 files changed, 1 insertions(+), 1 deletions(-)
-
-diff --git a/gtk/Makefile.am b/gtk/Makefile.am
-index 7bb5d0c..4a88351 100644
---- a/gtk/Makefile.am
-+++ b/gtk/Makefile.am
-@@ -214,7 +214,7 @@ gtkunixprint.defs: $(GTKUNIXPRINT_DEFS) Makefile
- gtkunixprint-types.defs: $(GTKUNIXPRINT_TYPES_DEFS) Makefile
- 	$(CREATEDEFS) $@ $(GTKUNIXPRINT_TYPES_DEFS)
- 
--gdk.c: gdk-types.defs gdk.defs $(GDK_OVERRIDES)
-+gdk.c: gdk-types.defs gtk-types.defs gdk.defs $(GDK_OVERRIDES)
- gtk.c: gdk-types.defs gtk-types.defs gtk.defs gdk-types.defs $(GTK_OVERRIDES)
- _gtk_la_CFLAGS = $(PYCAIRO_CFLAGS) $(GTK_CFLAGS)
- _gtk_la_LDFLAGS = $(common_ldflags) -export-symbols-regex init_gtk
--- 
-1.7.4
-
diff --git a/meta/recipes-devtools/python/python-pygtk/fix-gtkunixprint.patch b/meta/recipes-devtools/python/python-pygtk/fix-gtkunixprint.patch
deleted file mode 100644
index 16c0e8e..0000000
--- a/meta/recipes-devtools/python/python-pygtk/fix-gtkunixprint.patch
+++ /dev/null
@@ -1,20 +0,0 @@
-Upstream-Status: Inappropriate [configuration]
-
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
-
-Index: pygtk-2.24.0/gtk/gtkunixprint.override
-===================================================================
---- pygtk-2.24.0.orig/gtk/gtkunixprint.override
-+++ pygtk-2.24.0/gtk/gtkunixprint.override
-@@ -102,11 +102,6 @@ _wrap_gtk_print_job_get_surface(PyGObjec
-     if (pyg_error_check(&error))
-         return NULL;
- 
--#if PYCAIRO_VERSION_HEX >= 0x1010600
--    return PycairoSurface_FromSurface(cairo_surface_reference(surface), NULL);
--#else
--    return PycairoSurface_FromSurface(cairo_surface_reference(surface), NULL, NULL);
--#endif
- }
- %%
- override gtk_print_job_send kwargs
diff --git a/meta/recipes-devtools/python/python-pygtk/fix-pygtk-2.0.pc.patch b/meta/recipes-devtools/python/python-pygtk/fix-pygtk-2.0.pc.patch
deleted file mode 100644
index b6156540..0000000
--- a/meta/recipes-devtools/python/python-pygtk/fix-pygtk-2.0.pc.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-Upstream-Status: Inappropriate [configuration]
-
-Index: pygtk-2.24.0/pygtk-2.0.pc.in
-===================================================================
---- pygtk-2.24.0.orig/pygtk-2.0.pc.in
-+++ pygtk-2.24.0/pygtk-2.0.pc.in
-@@ -1,5 +1,6 @@
- prefix=@prefix@
- exec_prefix=@exec_prefix@
-+libdir=@libdir@
- includedir=@includedir@
- datarootdir=@datarootdir@
- datadir=@datadir@
diff --git a/meta/recipes-devtools/python/python-pygtk/nodocs.patch b/meta/recipes-devtools/python/python-pygtk/nodocs.patch
deleted file mode 100644
index f07309a..0000000
--- a/meta/recipes-devtools/python/python-pygtk/nodocs.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-Upstream-Status: Inappropriate [configuration]
-
-Index: pygtk-2.17.0/Makefile.am
-===================================================================
---- pygtk-2.17.0.orig/Makefile.am
-+++ pygtk-2.17.0/Makefile.am
-@@ -4,7 +4,7 @@ if BUILD_GTK
-   GTK_SUBDIR = gtk
- endif
- 
--SUBDIRS = . $(GTK_SUBDIR) examples tests docs
-+SUBDIRS = . $(GTK_SUBDIR) examples tests
- 
- PLATFORM_VERSION = 2.0
- 
diff --git a/meta/recipes-devtools/python/python-pygtk/prevent_to_get_display_during_import.patch b/meta/recipes-devtools/python/python-pygtk/prevent_to_get_display_during_import.patch
deleted file mode 100644
index 833038e..0000000
--- a/meta/recipes-devtools/python/python-pygtk/prevent_to_get_display_during_import.patch
+++ /dev/null
@@ -1,16 +0,0 @@
-Upstream-Status: Pending
-
-Index: pygtk-2.10.4/gtk/__init__.py
-===================================================================
---- pygtk-2.10.4.orig/gtk/__init__.py	2007-11-27 19:27:05.000000000 -0300
-+++ pygtk-2.10.4/gtk/__init__.py	2007-11-27 19:28:22.000000000 -0300
-@@ -78,7 +78,8 @@
- 
- keysyms = LazyModule('keysyms', locals())
- 
--_init()
-+if not hasattr(sys.modules['__main__'], 'python_launcher_enabled'):
-+    _init()
- 
- # CAPI
- _PyGtk_API = _gtk._PyGtk_API
diff --git a/meta/recipes-devtools/python/python-pygtk/python-pygtk2/acinclude.m4 b/meta/recipes-devtools/python/python-pygtk/python-pygtk2/acinclude.m4
deleted file mode 100644
index 53518fb..0000000
--- a/meta/recipes-devtools/python/python-pygtk/python-pygtk2/acinclude.m4
+++ /dev/null
@@ -1,90 +0,0 @@
-## this one is commonly used with AM_PATH_PYTHONDIR ...
-dnl AM_CHECK_PYMOD(MODNAME [,SYMBOL [,ACTION-IF-FOUND [,ACTION-IF-NOT-FOUND]]])
-dnl Check if a module containing a given symbol is visible to python.
-AC_DEFUN(AM_CHECK_PYMOD,
-[AC_REQUIRE([AM_PATH_PYTHON])
-py_mod_var=`echo $1['_']$2 | sed 'y%./+-%__p_%'`
-AC_MSG_CHECKING(for ifelse([$2],[],,[$2 in ])python module $1)
-AC_CACHE_VAL(py_cv_mod_$py_mod_var, [
-ifelse([$2],[], [prog="
-import sys
-try:
-        import $1
-except ImportError:
-        sys.exit(1)
-except:
-        sys.exit(0)
-sys.exit(0)"], [prog="
-import $1
-$1.$2"])
-if $PYTHON -c "$prog" 1>&AC_FD_CC 2>&AC_FD_CC
-  then
-    eval "py_cv_mod_$py_mod_var=yes"
-  else
-    eval "py_cv_mod_$py_mod_var=no"
-  fi
-])
-py_val=`eval "echo \`echo '$py_cv_mod_'$py_mod_var\`"`
-if test "x$py_val" != xno; then
-  AC_MSG_RESULT(yes)
-  ifelse([$3], [],, [$3
-])dnl
-else
-  AC_MSG_RESULT(no)
-  ifelse([$4], [],, [$4
-])dnl
-fi
-])
-
-dnl a macro to check for ability to create python extensions
-dnl  AM_CHECK_PYTHON_HEADERS([ACTION-IF-POSSIBLE], [ACTION-IF-NOT-POSSIBLE])
-dnl function also defines PYTHON_INCLUDES
-AC_DEFUN([AM_CHECK_PYTHON_HEADERS],
-[AC_REQUIRE([AM_PATH_PYTHON])
-AC_MSG_CHECKING(for headers required to compile python extensions)
-dnl deduce PYTHON_INCLUDES
-AC_ARG_WITH(python-includes,
-	[  --with-python-includes=DIR  path to Python includes], py_exec_prefix=$withval)
-if test x$py_exec_prefix != x; then
-PYTHON_INCLUDES="-I${py_exec_prefix}/include/python${PYTHON_VERSION}"
-else
-py_prefix=`$PYTHON -c "import sys; print sys.prefix"`
-py_exec_prefix=`$PYTHON -c "import sys; print sys.exec_prefix"`
-PYTHON_INCLUDES="-I${py_prefix}/include/python${PYTHON_VERSION}"
-if test "$py_prefix" != "$py_exec_prefix"; then
-  PYTHON_INCLUDES="$PYTHON_INCLUDES -I${py_exec_prefix}/include/python${PYTHON_VERSION}"
-fi
-fi
-AC_SUBST(PYTHON_INCLUDES)
-dnl check if the headers exist:
-save_CPPFLAGS="$CPPFLAGS"
-CPPFLAGS="$CPPFLAGS $PYTHON_INCLUDES"
-AC_TRY_CPP([#include <Python.h>],dnl
-[AC_MSG_RESULT(found)
-$1],dnl
-[AC_MSG_RESULT(not found)
-$2])
-CPPFLAGS="$save_CPPFLAGS"
-])
-
-dnl
-dnl JH_ADD_CFLAG(FLAG)
-dnl checks whether the C compiler supports the given flag, and if so, adds
-dnl it to $CFLAGS.  If the flag is already present in the list, then the
-dnl check is not performed.
-AC_DEFUN([JH_ADD_CFLAG],
-[
-case " $CFLAGS " in
-*@<:@\	\ @:>@$1@<:@\	\ @:>@*)
-  ;;
-*)
-  save_CFLAGS="$CFLAGS"
-  CFLAGS="$CFLAGS $1"
-  AC_MSG_CHECKING([whether [$]CC understands $1])
-  AC_TRY_COMPILE([], [], [jh_has_option=yes], [jh_has_option=no])
-  AC_MSG_RESULT($jh_has_option)
-  if test $jh_has_option = no; then
-    CFLAGS="$save_CFLAGS"
-  fi
-  ;;
-esac])
diff --git a/meta/recipes-devtools/python/python-pygtk/update-dependences-of-defs.c.patch b/meta/recipes-devtools/python/python-pygtk/update-dependences-of-defs.c.patch
deleted file mode 100644
index 3ed954e..0000000
--- a/meta/recipes-devtools/python/python-pygtk/update-dependences-of-defs.c.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-From dc024e9079bbffbb44436ba3e70a758ebad5520f Mon Sep 17 00:00:00 2001
-From: "Song.Li" <Song.Li@windriver.com>
-Date: Sat, 5 Jan 2013 14:55:59 +0800
-Subject: [PATCH] update dependences of defs.c in Makefile.am
-
-In gtk/Makefile.am, defs.c should dependes on gdk-types.defs and
-gtk-types.defs, otherwise it fails occasionally when parallel compile.
-The error message:
-"IOError: [Errno 2] No such file or directory: 'gtk-types.defs'"
-
-Add them to dependences of defs.c to fix this issue.
-
-Upstream-Status: Submitted
-https://bugzilla.gnome.org/show_bug.cgi?id=702706
-
-Signed-off-by: Song.Li <Song.Li@windriver.com>
-Signed-off-by: Kai Kang <kai.kang@windriver.com>
-
----
- gtk/Makefile.am |    2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/gtk/Makefile.am b/gtk/Makefile.am
-index 7bb5d0c..91826cb 100644
---- a/gtk/Makefile.am
-+++ b/gtk/Makefile.am
-@@ -289,7 +289,7 @@ if HAVE_GIO_TYPES_DEFS
- extra_codegen_args += --register $(PYGOBJECT_DEFSDIR)/gio-types.defs
- endif
- 
--.defs.c: 
-+.defs.c: gdk-types.defs gtk-types.defs
- 	($(PYTHON) $(CODEGENDIR)/codegen.py \
- 	   $(PYGTK_CODEGEN_DEFINES) \
- 	    -I $(srcdir) \
--- 
-1.7.9.5
-
diff --git a/meta/recipes-devtools/python/python-pygtk_2.24.0.bb b/meta/recipes-devtools/python/python-pygtk_2.24.0.bb
deleted file mode 100644
index 79b3110..0000000
--- a/meta/recipes-devtools/python/python-pygtk_2.24.0.bb
+++ /dev/null
@@ -1,55 +0,0 @@
-SUMMARY = "Python bindings for the GTK+ UI toolkit"
-SECTION = "devel/python"
-# needs gtk+ 2.17.x
-DEPENDS = "gtk+ libglade python-pycairo python-pygobject"
-RDEPENDS_${PN} = "python-shell python-pycairo python-pygobject"
-PROVIDES = "python-pygtk2"
-SRCNAME = "pygtk"
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://COPYING;md5=a916467b91076e631dd8edb7424769c7"
-
-PR = "r1"
-
-SRC_URI = "ftp://ftp.gnome.org/pub/gnome/sources/pygtk/2.24/${SRCNAME}-${PV}.tar.bz2 \
-           file://add-gtk-types.defs-into-gdk.c-dependence.patch \
-           file://fix-gtkunixprint.patch \
-           file://prevent_to_get_display_during_import.patch \
-           file://nodocs.patch \
-	   file://fix-pygtk-2.0.pc.patch \
-           file://acinclude.m4 \
-           file://update-dependences-of-defs.c.patch"
-
-SRC_URI[md5sum] = "a1051d5794fd7696d3c1af6422d17a49"
-SRC_URI[sha256sum] = "cd1c1ea265bd63ff669e92a2d3c2a88eb26bcd9e5363e0f82c896e649f206912"
-
-S = "${WORKDIR}/${SRCNAME}-${PV}"
-
-EXTRA_OECONF = "--disable-docs --with-python-includes=${STAGING_INCDIR}/../"
-
-inherit autotools pkgconfig distutils-base distro_features_check
-
-ANY_OF_DISTRO_FEATURES = "${GTK2DISTROFEATURES}"
-
-do_configure_prepend() {
-	install -m 0644 ${WORKDIR}/acinclude.m4 ${S}/
-	sed -i \
-		-e s:'`$PKG_CONFIG --variable defsdir pygobject-2.0`':\"${STAGING_DATADIR}/pygobject/2.0/defs\":g \
-		-e s:'`$PKG_CONFIG --variable=pygtkincludedir pygobject-2.0`':\"${STAGING_INCDIR}/pygtk-2.0\":g \
-		-e s:'`$PKG_CONFIG --variable=datadir pygobject-2.0`':\"${STAGING_DATADIR}\":g \
-		-e s:'`$PKG_CONFIG --variable codegendir pygobject-2.0`':\"${STAGING_DATADIR}/pygobject/2.0/codegen\":g \
-		-e s:'`$PKG_CONFIG --variable=fixxref pygobject-2.0`':\"${STAGING_DATADIR}/pygobject/xsl/fixxref.py\":g \
-		${S}/configure.ac
-}
-
-# dirty fix #2: fix build system paths leaking in
-do_install_append() {
-	sed -i -e '1s|^#!.*python|#!/usr/bin/env python|' ${D}${bindir}/pygtk-demo
-}
-
-PACKAGES =+ "${PN}-demo"
-FILES_${PN}-demo = " ${bindir}/pygtk-demo ${libdir}/pygtk "
-RDEPENDS_${PN}-demo = "python-pygtk python-stringold python-lang"
-
-# todo: revamp packaging, package demo seperatly
-FILES_${PN}-dev += " ${libdir}/pygtk/2.0 ${bindir}/pygtk-* ${datadir}/pygtk/2.0"
-
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 11/24] avahi: enable gobject-introspection
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (9 preceding siblings ...)
  2016-03-09 15:01 ` [PATCH 10/24] python-pygtk: remove the recipe Alexander Kanavin
@ 2016-03-09 15:01 ` Alexander Kanavin
  2016-03-09 15:01 ` [PATCH 12/24] gtk+: enable gobject introspection Alexander Kanavin
                   ` (12 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:01 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/recipes-connectivity/avahi/avahi-ui_0.6.32.bb |  2 ++
 meta/recipes-connectivity/avahi/avahi.inc          | 15 ++++++++++-----
 2 files changed, 12 insertions(+), 5 deletions(-)

diff --git a/meta/recipes-connectivity/avahi/avahi-ui_0.6.32.bb b/meta/recipes-connectivity/avahi/avahi-ui_0.6.32.bb
index eb8a35e..7f5dfb3 100644
--- a/meta/recipes-connectivity/avahi/avahi-ui_0.6.32.bb
+++ b/meta/recipes-connectivity/avahi/avahi-ui_0.6.32.bb
@@ -64,5 +64,7 @@ do_install_append () {
 	rm ${D}${mandir}/man1/a*
 	rm ${D}${mandir}/man5 -rf
 	rm ${D}${mandir}/man8 -rf
+        rm ${D}${libdir}/girepository-1.0/ -rf
+        rm ${D}${datadir}/gir-1.0/ -rf
 }
 
diff --git a/meta/recipes-connectivity/avahi/avahi.inc b/meta/recipes-connectivity/avahi/avahi.inc
index faa8ee8..cd5c804 100644
--- a/meta/recipes-connectivity/avahi/avahi.inc
+++ b/meta/recipes-connectivity/avahi/avahi.inc
@@ -34,10 +34,9 @@ USERADD_PARAM_avahi-autoipd = "--system --home /var/run/avahi-autoipd \
                               -c \"Avahi autoip daemon\" \
                               avahi-autoipd"
 
-inherit autotools pkgconfig update-rc.d gettext useradd
+inherit autotools pkgconfig update-rc.d gettext useradd gobject-introspection
 
-EXTRA_OECONF = "--disable-introspection \
-             --with-avahi-priv-access-group=adm \
+EXTRA_OECONF = "--with-avahi-priv-access-group=adm \
              --disable-stack-protector \
              --disable-gdbm \
              --disable-mono \
@@ -63,8 +62,14 @@ LDFLAGS_append_uclinux-uclibc = " -lintl"
 
 do_configure_prepend() {
     sed 's:AM_CHECK_PYMOD:echo "no pymod" #AM_CHECK_PYMOD:g' -i ${S}/configure.ac
+
+    # This m4 file will get in the way of our introspection.m4 with special cross-compilation fixes
+    rm "${S}/common/introspection.m4" || true
 }
 
+do_compile_prepend() {
+    export GIR_EXTRA_LIBS_PATH="${B}/avahi-common/.libs:${B}/avahi-client/.libs:${B}/avahi-glib/.libs"
+}
 
 PACKAGES =+ "avahi-daemon libavahi-common libavahi-core libavahi-client avahi-dnsconfd libavahi-glib libavahi-ui avahi-autoipd avahi-utils"
 
@@ -77,7 +82,7 @@ FILES_avahi-autoipd = "${sbindir}/avahi-autoipd \
                        ${sysconfdir}/udhcpc.d/00avahi-autoipd \
                        ${sysconfdir}/udhcpc.d/99avahi-autoipd"
 FILES_libavahi-common = "${libdir}/libavahi-common.so.*"
-FILES_libavahi-core = "${libdir}/libavahi-core.so.*"
+FILES_libavahi-core = "${libdir}/libavahi-core.so.* ${libdir}/girepository-1.0/AvahiCore*.typelib"
 FILES_avahi-daemon = "${sbindir}/avahi-daemon \
                       ${sysconfdir}/avahi/avahi-daemon.conf \
                       ${sysconfdir}/avahi/hosts \
@@ -94,7 +99,7 @@ FILES_avahi-dnsconfd = "${sbindir}/avahi-dnsconfd \
                         ${sysconfdir}/avahi/avahi-dnsconfd.action \
                         ${sysconfdir}/init.d/avahi-dnsconfd"
 FILES_libavahi-glib = "${libdir}/libavahi-glib.so.*"
-FILES_libavahi-gobject = "${libdir}/libavahi-gobject.so.*"
+FILES_libavahi-gobject = "${libdir}/libavahi-gobject.so.*  ${libdir}/girepository-1.0/Avahi*.typelib"
 FILES_avahi-utils = "${bindir}/avahi-*"
 
 RDEPENDS_${PN}-dev = "avahi-daemon (= ${EXTENDPKGV}) libavahi-core (= ${EXTENDPKGV}) libavahi-client (= ${EXTENDPKGV})"
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 12/24] gtk+: enable gobject introspection
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (10 preceding siblings ...)
  2016-03-09 15:01 ` [PATCH 11/24] avahi: enable gobject-introspection Alexander Kanavin
@ 2016-03-09 15:01 ` Alexander Kanavin
  2016-03-09 15:01 ` [PATCH 13/24] gtk+3: enable gobject-introspection Alexander Kanavin
                   ` (11 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:01 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/recipes-gnome/gtk+/gtk+.inc | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/meta/recipes-gnome/gtk+/gtk+.inc b/meta/recipes-gnome/gtk+/gtk+.inc
index 936870b..5bbfe6b 100644
--- a/meta/recipes-gnome/gtk+/gtk+.inc
+++ b/meta/recipes-gnome/gtk+/gtk+.inc
@@ -29,13 +29,12 @@ PACKAGECONFIG[x11] = "--with-x=yes --with-gdktarget=x11,--with-x=no,${X11DEPENDS
 # without --with-gdktarget=directfb it will check for cairo-xlib which isn't available without X11 DISTRO_FEATURE
 PACKAGECONFIG[directfb] = "--with-gdktarget=directfb,,directfb"
 
-inherit autotools gtk-doc pkgconfig update-alternatives gtk-immodules-cache
+inherit autotools gtk-doc pkgconfig update-alternatives gtk-immodules-cache gobject-introspection
 
 PACKAGES += "libgail gtk-demo"
 
-FILES_${PN} = "${bindir}/gtk-update-icon-cache-2.0 \
+FILES_${PN} += "${bindir}/gtk-update-icon-cache-2.0 \
 	${bindir}/gtk-query-immodules-2.0 \
-	${libdir}/lib*${SOLIBS} \
 	${datadir}/themes ${sysconfdir} \
 	${libdir}/gtk-2.0/${LIBV}/engines/libpixmap.so"
 
@@ -68,6 +67,10 @@ RRECOMMENDS_${PN}_libc-glibc = "${GTKGLIBC_RRECOMMENDS}"
 ALTERNATIVE_${PN} = "gtk-update-icon-cache"
 ALTERNATIVE_TARGET[gtk-update-icon-cache] = "${bindir}/gtk-update-icon-cache-2.0"
 
+do_compile_prepend() {
+        export GIR_EXTRA_LIBS_PATH="${B}/gdk/.libs"
+}
+
 do_install () {
 	autotools_do_install
 
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 13/24] gtk+3: enable gobject-introspection
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (11 preceding siblings ...)
  2016-03-09 15:01 ` [PATCH 12/24] gtk+: enable gobject introspection Alexander Kanavin
@ 2016-03-09 15:01 ` Alexander Kanavin
  2016-03-09 15:02 ` [PATCH 14/24] clutter: enable gobject introspection Alexander Kanavin
                   ` (10 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:01 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/recipes-gnome/gtk+/gtk+3.inc | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/meta/recipes-gnome/gtk+/gtk+3.inc b/meta/recipes-gnome/gtk+/gtk+3.inc
index 50a336c..bd29300 100644
--- a/meta/recipes-gnome/gtk+/gtk+3.inc
+++ b/meta/recipes-gnome/gtk+/gtk+3.inc
@@ -10,7 +10,7 @@ DEPENDS = "glib-2.0 cairo pango atk jpeg libpng gdk-pixbuf \
 
 LICENSE = "LGPLv2 & LGPLv2+ & LGPLv2.1+"
 
-inherit autotools pkgconfig gtk-doc update-alternatives gtk-immodules-cache gsettings distro_features_check upstream-version-is-even
+inherit autotools pkgconfig gtk-doc update-alternatives gtk-immodules-cache gsettings distro_features_check upstream-version-is-even gobject-introspection
 ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}"
 
 # This should be in autotools.bbclass, but until something elses uses it putting
@@ -28,10 +28,13 @@ EXTRA_OECONF += " \
                  --disable-xinerama \
                  --enable-modules \
                  --disable-cups \
-                 --disable-introspection \
                  --disable-colord \
 "
 
+do_compile_prepend() {
+        export GIR_EXTRA_LIBS_PATH="${B}/gdk/.libs"
+}
+
 PACKAGECONFIG ??= "${@bb.utils.contains("DISTRO_FEATURES", "x11", "x11", "", d)} \
                    ${@bb.utils.contains("DISTRO_FEATURES", "opengl x11", "glx", "", d)} \
                    ${@bb.utils.contains("DISTRO_FEATURES", "wayland", "wayland", "", d)}"
@@ -62,10 +65,9 @@ FILES_${PN}-demo = "${bindir}/gtk3-demo \
 # dependencies are present.
 RDEPENDS_${PN}-demo += "gdk-pixbuf-loader-png shared-mime-info"
 
-FILES_${PN} = "${bindir}/gtk-update-icon-cache-3.0 \
+FILES_${PN}_append = " ${bindir}/gtk-update-icon-cache-3.0 \
                ${bindir}/gtk-query-immodules-3.0 \
                ${bindir}/gtk-launch \
-               ${libdir}/lib*${SOLIBS} \
                ${datadir}/themes ${sysconfdir} ${datadir}/glib-2.0/schemas/ \
                ${libdir}/gtk-3.0/${LIBV}/engines/libpixmap.so \
                ${libdir}/gtk-3.0/modules/*.so"
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 14/24] clutter: enable gobject introspection
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (12 preceding siblings ...)
  2016-03-09 15:01 ` [PATCH 13/24] gtk+3: enable gobject-introspection Alexander Kanavin
@ 2016-03-09 15:02 ` Alexander Kanavin
  2016-03-09 15:02 ` [PATCH 15/24] libsoup-2.4: " Alexander Kanavin
                   ` (9 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:02 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/recipes-graphics/clutter/clutter-1.0.inc     | 5 ++---
 meta/recipes-graphics/clutter/clutter-gst-3.0.inc | 4 +---
 meta/recipes-graphics/clutter/clutter-gtk-1.0.inc | 3 +--
 meta/recipes-graphics/cogl/cogl-1.0.inc           | 8 +++++---
 meta/recipes-graphics/mx/mx.inc                   | 5 ++---
 5 files changed, 11 insertions(+), 14 deletions(-)

diff --git a/meta/recipes-graphics/clutter/clutter-1.0.inc b/meta/recipes-graphics/clutter/clutter-1.0.inc
index 0ace1ce..c6ecd08 100644
--- a/meta/recipes-graphics/clutter/clutter-1.0.inc
+++ b/meta/recipes-graphics/clutter/clutter-1.0.inc
@@ -2,7 +2,7 @@ SUMMARY = "Graphics library for creating hardware-accelerated user interfaces"
 HOMEPAGE = "http://www.clutter-project.org/"
 LICENSE = "LGPLv2.1+"
 
-inherit clutter ptest-gnome distro_features_check upstream-version-is-even
+inherit clutter ptest-gnome distro_features_check upstream-version-is-even gobject-introspection
 # depends on cogl-1.0 which needs opengl
 REQUIRED_DISTRO_FEATURES ?= "opengl"
 
@@ -19,8 +19,7 @@ EDEPENDS_EVDEV = "libxkbcommon"
 ERDEPENDS_EVDEV = "xkeyboard-config"
 
 # Disable pretty much everything, override in platform specific set up
-EXTRA_OECONF += "--disable-introspection	\
-	     	 --disable-quartz-backend	\
+EXTRA_OECONF += "--disable-quartz-backend	\
 	     	 --disable-win32-backend	\
 	     	 --disable-gdk-backend		\
 	     	 --disable-cex100-backend	\
diff --git a/meta/recipes-graphics/clutter/clutter-gst-3.0.inc b/meta/recipes-graphics/clutter/clutter-gst-3.0.inc
index 4f7b4a3..4c87798 100644
--- a/meta/recipes-graphics/clutter/clutter-gst-3.0.inc
+++ b/meta/recipes-graphics/clutter/clutter-gst-3.0.inc
@@ -2,7 +2,7 @@ SUMMARY = "GStreamer integration library for Clutter"
 HOMEPAGE = "http://www.clutter-project.org/"
 LICENSE = "LGPLv2+"
 
-inherit clutter distro_features_check upstream-version-is-even
+inherit clutter distro_features_check upstream-version-is-even gobject-introspection
 # depends on clutter-1.0 which depends on cogl-1.0
 REQUIRED_DISTRO_FEATURES ?= "opengl"
 
@@ -12,8 +12,6 @@ DEPENDS = "gstreamer1.0-plugins-base gstreamer1.0-plugins-bad clutter-1.0 libgud
 RDEPENDS_${PN} += "gstreamer1.0-meta-base"
 PACKAGES  =+ "${PN}-examples"
 
-EXTRA_OECONF += "--disable-introspection"
-
 FILES_${PN}          += "${libdir}/gstreamer-1.0/lib*.so"
 FILES_${PN}-dev      += "${libdir}/gstreamer-1.0/*.la"
 FILES_${PN}-examples  = "${bindir}/video-player ${bindir}/video-sink"
diff --git a/meta/recipes-graphics/clutter/clutter-gtk-1.0.inc b/meta/recipes-graphics/clutter/clutter-gtk-1.0.inc
index b07d3b9..05c4e5f 100644
--- a/meta/recipes-graphics/clutter/clutter-gtk-1.0.inc
+++ b/meta/recipes-graphics/clutter/clutter-gtk-1.0.inc
@@ -2,7 +2,7 @@ SUMMARY = "Library for embedding a Clutter canvas in a GTK+ application"
 HOMEPAGE = "http://www.clutter-project.org/"
 LICENSE = "LGPLv2+"
 
-inherit clutter distro_features_check upstream-version-is-even
+inherit clutter distro_features_check upstream-version-is-even gobject-introspection
 # depends on clutter-1.0 which depends on cogl-1.0
 REQUIRED_DISTRO_FEATURES ?= "opengl"
 # depends on gtk+3
@@ -12,5 +12,4 @@ DEPENDS = "clutter-1.0 gtk+3"
 PACKAGES  =+ "${PN}-examples"
 AUTOTOOLS_AUXDIR = "${S}/build"
 
-EXTRA_OECONF += "--disable-introspection"
 
diff --git a/meta/recipes-graphics/cogl/cogl-1.0.inc b/meta/recipes-graphics/cogl/cogl-1.0.inc
index b56bfec..fc7cffe 100644
--- a/meta/recipes-graphics/cogl/cogl-1.0.inc
+++ b/meta/recipes-graphics/cogl/cogl-1.0.inc
@@ -2,7 +2,7 @@ SUMMARY = "Modern 3D graphics API with associated utility APIs"
 HOMEPAGE = "http://wiki.clutter-project.org/wiki/Cogl"
 LICENSE = "MIT"
 
-inherit clutter distro_features_check upstream-version-is-even
+inherit clutter distro_features_check upstream-version-is-even gobject-introspection
 # cogl-1.0 needs opengl to build
 REQUIRED_DISTRO_FEATURES ?= "opengl"
 
@@ -26,8 +26,7 @@ ERDEPENDS_GL    = "libgl"
 ERDEPENDS_GLES2 = "libgles2"
 
 # GLESv1 is rarely tested, so disable it
-EXTRA_OECONF += "--disable-introspection	\
-	       	 --enable-examples-install	\
+EXTRA_OECONF += "--enable-examples-install	\
 	       	 --enable-debug		 	\
 	       	 --disable-gles1		\
 	         --disable-cairo                \
@@ -58,6 +57,9 @@ PACKAGECONFIG ??= "cogl-pango gles2 \
                    ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'glx egl-x11', '', d)} \
                    "
 
+do_compile_prepend() {
+        export GIR_EXTRA_LIBS_PATH="${B}/cogl/.libs"
+}
 
 FILES_${PN}-examples = "${bindir}/* ${datadir}/cogl/examples-data/*"
 FILES_libcogl = "${libdir}/libcogl${SOLIBS}"
diff --git a/meta/recipes-graphics/mx/mx.inc b/meta/recipes-graphics/mx/mx.inc
index aa4915d..4f10957 100644
--- a/meta/recipes-graphics/mx/mx.inc
+++ b/meta/recipes-graphics/mx/mx.inc
@@ -1,7 +1,7 @@
 SUMMARY = "Clutter based UI widget library"
 LICENSE = "LGPLv2.1"
 
-inherit clutter autotools-brokensep distro_features_check
+inherit clutter autotools-brokensep distro_features_check gobject-introspection
 # depends on clutter-1.0 which depends on cogl-1.0
 REQUIRED_DISTRO_FEATURES = "opengl"
 
@@ -9,8 +9,7 @@ DEPENDS = "clutter-1.0 dbus-glib gdk-pixbuf"
 
 SRC_URI = "http://source.clutter-project.org/sources/mx/${@get_verdir("${PV}")}/mx-${PV}.tar.xz"
 
-EXTRA_OECONF = "--disable-introspection		\
-	        --disable-gtk-doc		\
+EXTRA_OECONF = "--disable-gtk-doc		\
 	        --disable-gtk-widgets		\
 		--with-dbus			\
 		--with-winsys=none		\
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 15/24] libsoup-2.4: enable gobject introspection
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (13 preceding siblings ...)
  2016-03-09 15:02 ` [PATCH 14/24] clutter: enable gobject introspection Alexander Kanavin
@ 2016-03-09 15:02 ` Alexander Kanavin
  2016-03-09 15:02 ` [PATCH 16/24] gstreamer: " Alexander Kanavin
                   ` (8 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:02 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/recipes-support/libsoup/libsoup-2.4_2.52.2.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/recipes-support/libsoup/libsoup-2.4_2.52.2.bb b/meta/recipes-support/libsoup/libsoup-2.4_2.52.2.bb
index 13ff685..f6e3db2 100644
--- a/meta/recipes-support/libsoup/libsoup-2.4_2.52.2.bb
+++ b/meta/recipes-support/libsoup/libsoup-2.4_2.52.2.bb
@@ -16,7 +16,7 @@ SRC_URI[sha256sum] = "db55628b5c7d952945bb71b236469057c8dfb8dea0c271513579c6273c
 
 S = "${WORKDIR}/libsoup-${PV}"
 
-inherit autotools gettext pkgconfig upstream-version-is-even
+inherit autotools gettext pkgconfig upstream-version-is-even gobject-introspection
 
 # libsoup-gnome is entirely deprecated and just stubs in 2.42 onwards. Disable by default.
 PACKAGECONFIG ??= ""
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 16/24] gstreamer: enable gobject introspection
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (14 preceding siblings ...)
  2016-03-09 15:02 ` [PATCH 15/24] libsoup-2.4: " Alexander Kanavin
@ 2016-03-09 15:02 ` Alexander Kanavin
  2016-03-09 15:02 ` [PATCH 17/24] gnomebase.bbclass: do not disable " Alexander Kanavin
                   ` (7 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:02 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 ...on.m4-prefix-pkgconfig-paths-with-PKG_CON.patch |  42 +++
 .../recipes-multimedia/gstreamer/gst-player_git.bb |   2 +-
 .../gstreamer/gst-plugins-package.inc              |   1 +
 ...-don-t-hardcode-libtool-name-when-running.patch |  57 ++++
 .../gstreamer/gstreamer1.0-plugins-bad_1.6.3.bb    |   1 +
 .../gstreamer/gstreamer1.0-plugins-base.inc        |   4 +
 ...-don-t-hardcode-libtool-name-when-running.patch | 168 ++++++++++++
 ...-prefix-calls-to-pkg-config-with-PKG_CONF.patch | 298 +++++++++++++++++++++
 ...ssing-include-directories-when-calling-in.patch |  28 ++
 ...ncorrect-reference-to-gstreamer-sdp-in-Ma.patch |  27 ++
 .../gstreamer/gstreamer1.0-plugins-base_1.6.3.bb   |   4 +
 .../gstreamer/gstreamer1.0-plugins.inc             |  11 +-
 .../gstreamer/gstreamer1.0-rtsp-server.inc         |  14 +-
 ...ode-libtool-name-when-using-introspection.patch |  27 ++
 meta/recipes-multimedia/gstreamer/gstreamer1.0.inc |  13 +-
 .../gstreamer/gstreamer1.0_1.6.3.bb                |   1 +
 16 files changed, 693 insertions(+), 5 deletions(-)
 create mode 100644 meta/recipes-multimedia/gstreamer/files/0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch
 create mode 100644 meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch
 create mode 100644 meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch
 create mode 100644 meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0002-Makefile.am-prefix-calls-to-pkg-config-with-PKG_CONF.patch
 create mode 100644 meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0003-riff-add-missing-include-directories-when-calling-in.patch
 create mode 100644 meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0004-rtsp-drop-incorrect-reference-to-gstreamer-sdp-in-Ma.patch
 create mode 100644 meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server/0001-Don-t-hardcode-libtool-name-when-using-introspection.patch

diff --git a/meta/recipes-multimedia/gstreamer/files/0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch b/meta/recipes-multimedia/gstreamer/files/0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch
new file mode 100644
index 0000000..2cab87f
--- /dev/null
+++ b/meta/recipes-multimedia/gstreamer/files/0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch
@@ -0,0 +1,42 @@
+From 90916f96262fa7b27a0a99788c69f9fd6df11000 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Tue, 24 Nov 2015 16:46:27 +0200
+Subject: [PATCH] introspection.m4: prefix pkgconfig paths with
+ PKG_CONFIG_SYSROOT_DIR
+
+We can't use our tweaked introspection.m4 from gobject-introspection tarball
+because gstreamer also defines INTROSPECTION_INIT in its introspection.m4, which
+is later supplied to g-ir-scanner.
+
+Upstream-Status: Pending [review on oe-core list]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ common/m4/introspection.m4 | 12 ++++++------
+ 1 file changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/common/m4/introspection.m4 b/common/m4/introspection.m4
+index 162be57..217a6ae 100644
+--- a/common/m4/introspection.m4
++++ b/common/m4/introspection.m4
+@@ -54,14 +54,14 @@ m4_define([_GOBJECT_INTROSPECTION_CHECK_INTERNAL],
+     INTROSPECTION_GIRDIR=
+     INTROSPECTION_TYPELIBDIR=
+     if test "x$found_introspection" = "xyes"; then
+-       INTROSPECTION_SCANNER=`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0`
+-       INTROSPECTION_COMPILER=`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0`
+-       INTROSPECTION_GENERATE=`$PKG_CONFIG --variable=g_ir_generate gobject-introspection-1.0`
++       INTROSPECTION_SCANNER=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0`
++       INTROSPECTION_COMPILER=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0`
++       INTROSPECTION_GENERATE=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=g_ir_generate gobject-introspection-1.0`
+        INTROSPECTION_GIRDIR=`$PKG_CONFIG --variable=girdir gobject-introspection-1.0`
+        INTROSPECTION_TYPELIBDIR="$($PKG_CONFIG --variable=typelibdir gobject-introspection-1.0)"
+        INTROSPECTION_CFLAGS=`$PKG_CONFIG --cflags gobject-introspection-1.0`
+        INTROSPECTION_LIBS=`$PKG_CONFIG --libs gobject-introspection-1.0`
+-       INTROSPECTION_MAKEFILE=`$PKG_CONFIG --variable=datadir gobject-introspection-1.0`/gobject-introspection-1.0/Makefile.introspection
++       INTROSPECTION_MAKEFILE=$PKG_CONFIG_SYSROOT_DIR`$PKG_CONFIG --variable=datadir gobject-introspection-1.0`/gobject-introspection-1.0/Makefile.introspection
+        INTROSPECTION_INIT="extern void gst_init(gint*,gchar**); gst_init(NULL,NULL);"
+     fi
+     AC_SUBST(INTROSPECTION_SCANNER)
+-- 
+2.6.2
+
diff --git a/meta/recipes-multimedia/gstreamer/gst-player_git.bb b/meta/recipes-multimedia/gstreamer/gst-player_git.bb
index c6c8f36..8129169 100644
--- a/meta/recipes-multimedia/gstreamer/gst-player_git.bb
+++ b/meta/recipes-multimedia/gstreamer/gst-player_git.bb
@@ -15,7 +15,7 @@ SRCREV = "5386c5b984d40ef5434673ed62204e69aaf52645"
 
 S = "${WORKDIR}/git"
 
-inherit autotools gtk-doc lib_package pkgconfig distro_features_check
+inherit autotools gtk-doc lib_package pkgconfig distro_features_check gobject-introspection
 
 ANY_OF_DISTRO_FEATURES = "${GTK2DISTROFEATURES}"
 
diff --git a/meta/recipes-multimedia/gstreamer/gst-plugins-package.inc b/meta/recipes-multimedia/gstreamer/gst-plugins-package.inc
index 9ffbe7c..3cef1d3 100644
--- a/meta/recipes-multimedia/gstreamer/gst-plugins-package.inc
+++ b/meta/recipes-multimedia/gstreamer/gst-plugins-package.inc
@@ -8,6 +8,7 @@ python split_gstreamer10_packages () {
 
     do_split_packages(d, glibdir, '^lib(.*)\.so\.*', 'lib%s', 'gstreamer %s library', extra_depends='', allow_links=True)
     do_split_packages(d, gst_libdir, 'libgst(.*)\.so$', d.expand('${PN}-%s'), 'GStreamer plugin for %s', postinst=postinst, extra_depends='')
+    do_split_packages(d, glibdir+'/girepository-1.0', 'Gst(.*)-1.0\.typelib$', d.expand('${PN}-%s-typelib'), 'GStreamer typelib file for %s', postinst=postinst, extra_depends='')
     do_split_packages(d, gst_libdir, 'libgst(.*)\.la$', d.expand('${PN}-%s-dev'), 'GStreamer plugin for %s (development files)', extra_depends=d.expand('${PN}-dev'))
     do_split_packages(d, gst_libdir, 'libgst(.*)\.a$', d.expand('${PN}-%s-staticdev'), 'GStreamer plugin for %s (static development files)', extra_depends=d.expand('${PN}-staticdev'))
 }
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch
new file mode 100644
index 0000000..154d340
--- /dev/null
+++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch
@@ -0,0 +1,57 @@
+From cff6fbf555a072408c21da1e818209c9d3814dd3 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Tue, 27 Oct 2015 14:36:58 +0200
+Subject: [PATCH] Makefile.am: don't hardcode libtool name when running
+ introspection tools
+
+Upstream-Status: Pending [review on oe-core list]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+---
+ gst-libs/gst/gl/Makefile.am        | 2 +-
+ gst-libs/gst/insertbin/Makefile.am | 2 +-
+ gst-libs/gst/mpegts/Makefile.am    | 2 +-
+ 3 files changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/gst-libs/gst/gl/Makefile.am b/gst-libs/gst/gl/Makefile.am
+index f968357..7cc2c7a 100644
+--- a/gst-libs/gst/gl/Makefile.am
++++ b/gst-libs/gst/gl/Makefile.am
+@@ -149,7 +149,7 @@ GstGL-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstgl-@GST_API_VERSION@
+ 		--library=libgstgl-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--include=GstBase-@GST_API_VERSION@ \
+-		--libtool="$(top_builddir)/libtool" \
++		--libtool="$(LIBTOOL)" \
+ 		--pkg gstreamer-@GST_API_VERSION@ \
+ 		--pkg gstreamer-base-@GST_API_VERSION@ \
+ 		--pkg gstreamer-video-@GST_API_VERSION@ \
+diff --git a/gst-libs/gst/insertbin/Makefile.am b/gst-libs/gst/insertbin/Makefile.am
+index 09eb97c..b746885 100644
+--- a/gst-libs/gst/insertbin/Makefile.am
++++ b/gst-libs/gst/insertbin/Makefile.am
+@@ -43,7 +43,7 @@ GstInsertBin-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstinsertbin-@GS
+ 		--library=libgstinsertbin-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--include=GstBase-@GST_API_VERSION@ \
+-		--libtool="$(top_builddir)/libtool" \
++		--libtool="$(LIBTOOL)" \
+ 		--pkg gstreamer-@GST_API_VERSION@ \
+ 		--pkg gstreamer-base-@GST_API_VERSION@ \
+ 		--pkg-export gstreamer-insertbin-@GST_API_VERSION@ \
+diff --git a/gst-libs/gst/mpegts/Makefile.am b/gst-libs/gst/mpegts/Makefile.am
+index 2511d49..c1cbce6 100644
+--- a/gst-libs/gst/mpegts/Makefile.am
++++ b/gst-libs/gst/mpegts/Makefile.am
+@@ -78,7 +78,7 @@ GstMpegts-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstmpegts-@GST_API_
+ 		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-video-@GST_API_VERSION@` \
+ 		--library=libgstmpegts-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+-		--libtool="$(top_builddir)/libtool" \
++		--libtool="$(LIBTOOL)" \
+ 		--pkg gstreamer-@GST_API_VERSION@ \
+ 		--pkg gstreamer-video-@GST_API_VERSION@ \
+ 		--pkg-export gstreamer-mpegts-@GST_API_VERSION@ \
+-- 
+2.6.2
+
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_1.6.3.bb b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_1.6.3.bb
index 8eb47c2..323177b 100644
--- a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_1.6.3.bb
+++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_1.6.3.bb
@@ -20,6 +20,7 @@ SRC_URI = " \
     file://configure-allow-to-disable-libssh2.patch \
     file://0001-glimagesink-Downrank-to-marginal.patch \
     file://0002-glplugin-glwindow-fix-memory-leak-of-navigation-thre.patch \
+    file://0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch \
 "
 
 SRC_URI[md5sum] = "4857adcafe41e4b9b8805cf88303bd55"
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base.inc b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base.inc
index f75efea..240ee5f 100644
--- a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base.inc
+++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base.inc
@@ -35,3 +35,7 @@ EXTRA_OECONF += " \
 CACHED_CONFIGUREVARS_append_x86 = " ac_cv_header_emmintrin_h=no ac_cv_header_xmmintrin_h=no"
 
 FILES_${MLPREFIX}libgsttag-1.0 += "${datadir}/gst-plugins-base/1.0/license-translations.dict"
+
+do_compile_prepend() {
+        export GIR_EXTRA_LIBS_PATH="${B}/gst-libs/gst/tag/.libs:${B}/gst-libs/gst/video/.libs:${B}/gst-libs/gst/audio/.libs"
+}
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch
new file mode 100644
index 0000000..781e4d8
--- /dev/null
+++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch
@@ -0,0 +1,168 @@
+From f1d9652351e7754c63003104eceb526af424c7e0 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Fri, 20 Nov 2015 16:53:04 +0200
+Subject: [PATCH 1/4] Makefile.am: don't hardcode libtool name when running
+ introspection tools
+
+Upstream-Status: Pending [review on oe-core maillist]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ gst-libs/gst/allocators/Makefile.am | 2 +-
+ gst-libs/gst/app/Makefile.am        | 2 +-
+ gst-libs/gst/audio/Makefile.am      | 2 +-
+ gst-libs/gst/fft/Makefile.am        | 2 +-
+ gst-libs/gst/pbutils/Makefile.am    | 2 +-
+ gst-libs/gst/riff/Makefile.am       | 2 +-
+ gst-libs/gst/rtp/Makefile.am        | 2 +-
+ gst-libs/gst/rtsp/Makefile.am       | 2 +-
+ gst-libs/gst/sdp/Makefile.am        | 2 +-
+ gst-libs/gst/tag/Makefile.am        | 2 +-
+ gst-libs/gst/video/Makefile.am      | 2 +-
+ 11 files changed, 11 insertions(+), 11 deletions(-)
+
+diff --git a/gst-libs/gst/allocators/Makefile.am b/gst-libs/gst/allocators/Makefile.am
+index 9361bf9..bc7f53a 100644
+--- a/gst-libs/gst/allocators/Makefile.am
++++ b/gst-libs/gst/allocators/Makefile.am
+@@ -37,7 +37,7 @@ GstAllocators-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstallocators-@
+ 		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+ 		--library=libgstallocators-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+-		--libtool="$(top_builddir)/libtool" \
++		--libtool="$(LIBTOOL)" \
+ 		--pkg gstreamer-@GST_API_VERSION@ \
+ 		--pkg-export gstreamer-allocators-@GST_API_VERSION@ \
+ 		--output $@ \
+diff --git a/gst-libs/gst/app/Makefile.am b/gst-libs/gst/app/Makefile.am
+index 6d6de8d..dcc2fe0 100644
+--- a/gst-libs/gst/app/Makefile.am
++++ b/gst-libs/gst/app/Makefile.am
+@@ -52,7 +52,7 @@ GstApp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstapp-@GST_API_VERSIO
+ 		--library=libgstapp-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--include=GstBase-@GST_API_VERSION@ \
+-		--libtool="$(top_builddir)/libtool" \
++		--libtool="$(LIBTOOL)" \
+ 		--pkg gstreamer-@GST_API_VERSION@ \
+ 		--pkg gstreamer-base-@GST_API_VERSION@ \
+ 		--pkg-export gstreamer-app-@GST_API_VERSION@ \
+diff --git a/gst-libs/gst/audio/Makefile.am b/gst-libs/gst/audio/Makefile.am
+index 275d222..2374196 100644
+--- a/gst-libs/gst/audio/Makefile.am
++++ b/gst-libs/gst/audio/Makefile.am
+@@ -106,7 +106,7 @@ GstAudio-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstaudio-@GST_API_VE
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--include=GstBase-@GST_API_VERSION@ \
+ 		--include=GstTag-@GST_API_VERSION@ \
+-		--libtool="$(top_builddir)/libtool" \
++		--libtool="$(LIBTOOL)" \
+ 		--pkg gstreamer-@GST_API_VERSION@ \
+ 		--pkg gstreamer-base-@GST_API_VERSION@ \
+ 		--pkg-export gstreamer-audio-@GST_API_VERSION@ \
+diff --git a/gst-libs/gst/fft/Makefile.am b/gst-libs/gst/fft/Makefile.am
+index 09b3d68..f545354 100644
+--- a/gst-libs/gst/fft/Makefile.am
++++ b/gst-libs/gst/fft/Makefile.am
+@@ -64,7 +64,7 @@ GstFft-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstfft-@GST_API_VERSIO
+ 		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+ 		--library=libgstfft-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+-		--libtool="$(top_builddir)/libtool" \
++		--libtool="$(LIBTOOL)" \
+ 		--pkg gstreamer-@GST_API_VERSION@ \
+ 		--pkg-export gstreamer-fft-@GST_API_VERSION@ \
+ 		--output $@ \
+diff --git a/gst-libs/gst/pbutils/Makefile.am b/gst-libs/gst/pbutils/Makefile.am
+index 64d5eb0..91dc214 100644
+--- a/gst-libs/gst/pbutils/Makefile.am
++++ b/gst-libs/gst/pbutils/Makefile.am
+@@ -94,7 +94,7 @@ GstPbutils-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstpbutils-@GST_AP
+ 		--include=GstTag-@GST_API_VERSION@ \
+ 		--include=GstVideo-@GST_API_VERSION@ \
+ 		--include=GstAudio-@GST_API_VERSION@ \
+-		--libtool="$(top_builddir)/libtool" \
++		--libtool="$(LIBTOOL)" \
+ 		--pkg gstreamer-@GST_API_VERSION@ \
+ 		--pkg gstreamer-tag-@GST_API_VERSION@ \
+ 		--pkg gstreamer-video-@GST_API_VERSION@ \
+diff --git a/gst-libs/gst/riff/Makefile.am b/gst-libs/gst/riff/Makefile.am
+index 83d83cb..3bd8fc0 100644
+--- a/gst-libs/gst/riff/Makefile.am
++++ b/gst-libs/gst/riff/Makefile.am
+@@ -47,7 +47,7 @@ libgstriff_@GST_API_VERSION@_la_LDFLAGS = $(GST_LIB_LDFLAGS) $(GST_ALL_LDFLAGS)
+ #		--include=GstAudio-@GST_API_VERSION@ \
+ #		--include=GstTag-@GST_API_VERSION@ \
+ #		--include=Gst-@GST_API_VERSION@ \
+-#		--libtool="$(top_builddir)/libtool" \
++#		--libtool="$(LIBTOOL)" \
+ #		--pkg gstreamer-@GST_API_VERSION@ \
+ #		--pkg gstreamer-tag-@GST_API_VERSION@ \
+ #		--pkg gstreamer-audio-@GST_API_VERSION@ \
+diff --git a/gst-libs/gst/rtp/Makefile.am b/gst-libs/gst/rtp/Makefile.am
+index fdd01c1..f5445c1 100644
+--- a/gst-libs/gst/rtp/Makefile.am
++++ b/gst-libs/gst/rtp/Makefile.am
+@@ -64,7 +64,7 @@ GstRtp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstrtp-@GST_API_VERSIO
+ 		--library=libgstrtp-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--include=GstBase-@GST_API_VERSION@ \
+-		--libtool="$(top_builddir)/libtool" \
++		--libtool="$(LIBTOOL)" \
+ 		--pkg gstreamer-@GST_API_VERSION@ \
+ 		--pkg gstreamer-base-@GST_API_VERSION@ \
+ 		--pkg-export gstreamer-rtp-@GST_API_VERSION@ \
+diff --git a/gst-libs/gst/rtsp/Makefile.am b/gst-libs/gst/rtsp/Makefile.am
+index ede5706..9b0b258 100644
+--- a/gst-libs/gst/rtsp/Makefile.am
++++ b/gst-libs/gst/rtsp/Makefile.am
+@@ -71,7 +71,7 @@ GstRtsp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstrtsp-@GST_API_VERS
+ 		--include=Gio-2.0 \
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--include=GstSdp-@GST_API_VERSION@ \
+-		--libtool="$(top_builddir)/libtool" \
++		--libtool="$(LIBTOOL)" \
+ 		--pkg gio-2.0 \
+ 		--pkg gstreamer-@GST_API_VERSION@ \
+ 		--pkg gstreamer-sdp-@GST_API_VERSION@ \
+diff --git a/gst-libs/gst/sdp/Makefile.am b/gst-libs/gst/sdp/Makefile.am
+index a90f30b..0e149b8 100644
+--- a/gst-libs/gst/sdp/Makefile.am
++++ b/gst-libs/gst/sdp/Makefile.am
+@@ -31,7 +31,7 @@ GstSdp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstsdp-@GST_API_VERSIO
+ 		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+ 		--library=libgstsdp-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+-		--libtool="$(top_builddir)/libtool" \
++		--libtool="$(LIBTOOL)" \
+ 		--pkg gstreamer-@GST_API_VERSION@ \
+ 		--pkg-export gstreamer-sdp-@GST_API_VERSION@ \
+ 		--output $@ \
+diff --git a/gst-libs/gst/tag/Makefile.am b/gst-libs/gst/tag/Makefile.am
+index c534a4d..cafafd3 100644
+--- a/gst-libs/gst/tag/Makefile.am
++++ b/gst-libs/gst/tag/Makefile.am
+@@ -44,7 +44,7 @@ GstTag-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgsttag-@GST_API_VERSIO
+ 		--library=libgsttag-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--include=GstBase-@GST_API_VERSION@ \
+-		--libtool="$(top_builddir)/libtool" \
++		--libtool="$(LIBTOOL)" \
+ 		--pkg gstreamer-@GST_API_VERSION@ \
+ 		--pkg gstreamer-base-@GST_API_VERSION@ \
+ 		--pkg-export gstreamer-tag-@GST_API_VERSION@ \
+diff --git a/gst-libs/gst/video/Makefile.am b/gst-libs/gst/video/Makefile.am
+index 5d31fa1..ac64eb3 100644
+--- a/gst-libs/gst/video/Makefile.am
++++ b/gst-libs/gst/video/Makefile.am
+@@ -113,7 +113,7 @@ GstVideo-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstvideo-@GST_API_VE
+ 		--library=libgstvideo-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--include=GstBase-@GST_API_VERSION@ \
+-		--libtool="$(top_builddir)/libtool" \
++		--libtool="$(LIBTOOL)" \
+ 		--pkg gstreamer-@GST_API_VERSION@ \
+ 		--pkg gstreamer-base-@GST_API_VERSION@ \
+ 		--pkg-export gstreamer-video-@GST_API_VERSION@ \
+-- 
+2.6.2
+
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0002-Makefile.am-prefix-calls-to-pkg-config-with-PKG_CONF.patch b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0002-Makefile.am-prefix-calls-to-pkg-config-with-PKG_CONF.patch
new file mode 100644
index 0000000..85fcacb
--- /dev/null
+++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0002-Makefile.am-prefix-calls-to-pkg-config-with-PKG_CONF.patch
@@ -0,0 +1,298 @@
+From 990b653c7b6de1937ec759019982d6c5f15770f7 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Mon, 26 Oct 2015 16:38:18 +0200
+Subject: [PATCH 2/4] Makefile.am: prefix calls to pkg-config with
+ PKG_CONFIG_SYSROOT_DIR
+
+Upstream-Status: Pending [review on oe-core maillist]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ gst-libs/gst/allocators/Makefile.am |  4 ++--
+ gst-libs/gst/app/Makefile.am        |  4 ++--
+ gst-libs/gst/audio/Makefile.am      | 12 ++++++------
+ gst-libs/gst/fft/Makefile.am        |  4 ++--
+ gst-libs/gst/pbutils/Makefile.am    | 12 ++++++------
+ gst-libs/gst/riff/Makefile.am       |  8 ++++----
+ gst-libs/gst/rtp/Makefile.am        |  8 ++++----
+ gst-libs/gst/rtsp/Makefile.am       |  4 ++--
+ gst-libs/gst/sdp/Makefile.am        |  4 ++--
+ gst-libs/gst/tag/Makefile.am        |  8 ++++----
+ gst-libs/gst/video/Makefile.am      |  8 ++++----
+ 11 files changed, 38 insertions(+), 38 deletions(-)
+
+diff --git a/gst-libs/gst/allocators/Makefile.am b/gst-libs/gst/allocators/Makefile.am
+index bc7f53a..0ef5f86 100644
+--- a/gst-libs/gst/allocators/Makefile.am
++++ b/gst-libs/gst/allocators/Makefile.am
+@@ -34,7 +34,7 @@ GstAllocators-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstallocators-@
+ 		--c-include "gst/allocators/allocators.h" \
+ 		-I$(top_srcdir)/gst-libs \
+ 		-I$(top_builddir)/gst-libs \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+ 		--library=libgstallocators-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--libtool="$(LIBTOOL)" \
+@@ -58,7 +58,7 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
+ 		$(INTROSPECTION_COMPILER) \
+ 		--includedir=$(srcdir) \
+ 		--includedir=$(builddir) \
+-		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+ 		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
+ 
+ CLEANFILES = $(BUILT_GIRSOURCES) $(typelibs_DATA)
+diff --git a/gst-libs/gst/app/Makefile.am b/gst-libs/gst/app/Makefile.am
+index dcc2fe0..dc076cb 100644
+--- a/gst-libs/gst/app/Makefile.am
++++ b/gst-libs/gst/app/Makefile.am
+@@ -47,8 +47,8 @@ GstApp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstapp-@GST_API_VERSIO
+ 		--c-include "gst/app/app.h" \
+ 		-I$(top_srcdir)/gst-libs \
+ 		-I$(top_builddir)/gst-libs \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
+ 		--library=libgstapp-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--include=GstBase-@GST_API_VERSION@ \
+diff --git a/gst-libs/gst/audio/Makefile.am b/gst-libs/gst/audio/Makefile.am
+index 2374196..295eb42 100644
+--- a/gst-libs/gst/audio/Makefile.am
++++ b/gst-libs/gst/audio/Makefile.am
+@@ -96,12 +96,12 @@ GstAudio-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstaudio-@GST_API_VE
+ 		-I$(top_srcdir)/gst-libs \
+ 		-I$(top_builddir)/gst-libs \
+ 		--c-include "gst/audio/audio.h" \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
+ 		--add-include-path="$(top_builddir)/gst-libs/gst/tag/" \
+ 		--library=libgstaudio-@GST_API_VERSION@.la \
+-		--library-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=libdir gstreamer-@GST_API_VERSION@` \
+-		--library-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=libdir gstreamer-base-@GST_API_VERSION@` \
++		--library-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=libdir gstreamer-@GST_API_VERSION@` \
++		--library-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=libdir gstreamer-base-@GST_API_VERSION@` \
+ 		--library-path="$(top_builddir)/gst-libs/gst/tag/" \
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--include=GstBase-@GST_API_VERSION@ \
+@@ -130,8 +130,8 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
+ 		--includedir=$(srcdir) \
+ 		--includedir=$(builddir) \
+ 		--includedir="$(top_builddir)/gst-libs/gst/tag/" \
+-		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
+-		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
++		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+ 		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
+ 
+ CLEANFILES += $(BUILT_GIRSOURCES) $(typelibs_DATA)
+diff --git a/gst-libs/gst/fft/Makefile.am b/gst-libs/gst/fft/Makefile.am
+index f545354..1bb6243 100644
+--- a/gst-libs/gst/fft/Makefile.am
++++ b/gst-libs/gst/fft/Makefile.am
+@@ -61,7 +61,7 @@ GstFft-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstfft-@GST_API_VERSIO
+ 		--c-include "gst/fft/fft.h" \
+ 		-I$(top_srcdir)/gst-libs \
+ 		-I$(top_builddir)/gst-libs \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+ 		--library=libgstfft-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--libtool="$(LIBTOOL)" \
+@@ -85,7 +85,7 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
+ 		$(INTROSPECTION_COMPILER) \
+ 		--includedir=$(srcdir) \
+ 		--includedir=$(builddir) \
+-		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+ 		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
+ 
+ CLEANFILES = $(BUILT_GIRSOURCES) $(typelibs_DATA)
+diff --git a/gst-libs/gst/pbutils/Makefile.am b/gst-libs/gst/pbutils/Makefile.am
+index 91dc214..dc8e1d3 100644
+--- a/gst-libs/gst/pbutils/Makefile.am
++++ b/gst-libs/gst/pbutils/Makefile.am
+@@ -79,14 +79,14 @@ GstPbutils-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstpbutils-@GST_AP
+ 		--c-include "gst/pbutils/pbutils.h" \
+ 		-I$(top_srcdir)/gst-libs \
+ 		-I$(top_builddir)/gst-libs \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
+ 		--add-include-path="$(top_builddir)/gst-libs/gst/tag/" \
+ 		--add-include-path="$(top_builddir)/gst-libs/gst/video/" \
+ 		--add-include-path="$(top_builddir)/gst-libs/gst/audio/" \
+ 		--library=libgstpbutils-@GST_API_VERSION@.la \
+-		--library-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=libdir gstreamer-@GST_API_VERSION@` \
+-		--library-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=libdir gstreamer-base-@GST_API_VERSION@` \
++		--library-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=libdir gstreamer-@GST_API_VERSION@` \
++		--library-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=libdir gstreamer-base-@GST_API_VERSION@` \
+ 		--library-path="$(top_builddir)/gst-libs/gst/tag/" \
+ 		--library-path="$(top_builddir)/gst-libs/gst/video/" \
+ 		--library-path="$(top_builddir)/gst-libs/gst/audio/" \
+@@ -119,8 +119,8 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
+ 		$(INTROSPECTION_COMPILER) \
+ 		--includedir=$(srcdir) \
+ 		--includedir=$(builddir) \
+-		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+-		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
++		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
+ 		--includedir="$(top_builddir)/gst-libs/gst/tag/" \
+ 		--includedir="$(top_builddir)/gst-libs/gst/video/" \
+ 		--includedir="$(top_builddir)/gst-libs/gst/audio/" \
+diff --git a/gst-libs/gst/riff/Makefile.am b/gst-libs/gst/riff/Makefile.am
+index 3bd8fc0..0a115cc 100644
+--- a/gst-libs/gst/riff/Makefile.am
++++ b/gst-libs/gst/riff/Makefile.am
+@@ -41,8 +41,8 @@ libgstriff_@GST_API_VERSION@_la_LDFLAGS = $(GST_LIB_LDFLAGS) $(GST_ALL_LDFLAGS)
+ #		--c-include "gst/riff/riff.h" \
+ #		--add-include-path=$(builddir)/../tag \
+ #		--add-include-path=$(builddir)/../audio \
+-#		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+-#		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
++#		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++#		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
+ #		--library=libgstriff-@GST_API_VERSION@.la \
+ #		--include=GstAudio-@GST_API_VERSION@ \
+ #		--include=GstTag-@GST_API_VERSION@ \
+@@ -73,8 +73,8 @@ libgstriff_@GST_API_VERSION@_la_LDFLAGS = $(GST_LIB_LDFLAGS) $(GST_ALL_LDFLAGS)
+ #		--includedir=$(builddir) \
+ #		--includedir=$(builddir)/../tag \
+ #		--includedir=$(builddir)/../audio \
+-#		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+-#		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
++#		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++#		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
+ #		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
+ #
+ #CLEANFILES = $(BUILT_GIRSOURCES) $(typelibs_DATA)
+diff --git a/gst-libs/gst/rtp/Makefile.am b/gst-libs/gst/rtp/Makefile.am
+index f5445c1..527c0b4 100644
+--- a/gst-libs/gst/rtp/Makefile.am
++++ b/gst-libs/gst/rtp/Makefile.am
+@@ -59,8 +59,8 @@ GstRtp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstrtp-@GST_API_VERSIO
+ 		--c-include "gst/rtp/rtp.h" \
+ 		-I$(top_builddir)/gst-libs \
+ 		-I$(top_srcdir)/gst-libs \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
+ 		--library=libgstrtp-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--include=GstBase-@GST_API_VERSION@ \
+@@ -87,8 +87,8 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
+ 		$(INTROSPECTION_COMPILER) \
+ 		--includedir=$(srcdir) \
+ 		--includedir=$(builddir) \
+-		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+-		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
++		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
+ 		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
+ 
+ CLEANFILES += $(BUILT_GIRSOURCES) $(typelibs_DATA)
+diff --git a/gst-libs/gst/rtsp/Makefile.am b/gst-libs/gst/rtsp/Makefile.am
+index 9b0b258..4f6d9f8 100644
+--- a/gst-libs/gst/rtsp/Makefile.am
++++ b/gst-libs/gst/rtsp/Makefile.am
+@@ -66,7 +66,7 @@ GstRtsp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstrtsp-@GST_API_VERS
+ 		-I$(top_builddir)/gst-libs \
+ 		-I$(top_srcdir)/gst-libs \
+ 		--add-include-path=$(builddir)/../sdp \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+ 		--library=libgstrtsp-@GST_API_VERSION@.la \
+ 		--include=Gio-2.0 \
+ 		--include=Gst-@GST_API_VERSION@ \
+@@ -96,7 +96,7 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
+ 		--includedir=$(srcdir) \
+ 		--includedir=$(builddir) \
+ 		--includedir=$(builddir)/../sdp \
+-		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+ 		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
+ 
+ CLEANFILES += $(BUILT_GIRSOURCES) $(typelibs_DATA)
+diff --git a/gst-libs/gst/sdp/Makefile.am b/gst-libs/gst/sdp/Makefile.am
+index 0e149b8..9aa0512 100644
+--- a/gst-libs/gst/sdp/Makefile.am
++++ b/gst-libs/gst/sdp/Makefile.am
+@@ -28,7 +28,7 @@ GstSdp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstsdp-@GST_API_VERSIO
+ 		--warn-all \
+ 		--c-include "gst/sdp/sdp.h" \
+ 		-I$(top_srcdir)/gst-libs \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+ 		--library=libgstsdp-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--libtool="$(LIBTOOL)" \
+@@ -52,7 +52,7 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
+ 		$(INTROSPECTION_COMPILER) \
+ 		--includedir=$(srcdir) \
+ 		--includedir=$(builddir) \
+-		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+ 		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
+ 
+ CLEANFILES = $(BUILT_GIRSOURCES) $(typelibs_DATA)
+diff --git a/gst-libs/gst/tag/Makefile.am b/gst-libs/gst/tag/Makefile.am
+index cafafd3..ba99279 100644
+--- a/gst-libs/gst/tag/Makefile.am
++++ b/gst-libs/gst/tag/Makefile.am
+@@ -39,8 +39,8 @@ GstTag-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgsttag-@GST_API_VERSIO
+ 		--c-include "gst/tag/tag.h" \
+ 		-I$(top_srcdir)/gst-libs \
+ 		-I$(top_builddir)/gst-libs \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
+ 		--library=libgsttag-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--include=GstBase-@GST_API_VERSION@ \
+@@ -67,8 +67,8 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
+ 		$(INTROSPECTION_COMPILER) \
+ 		--includedir=$(srcdir) \
+ 		--includedir=$(builddir) \
+-		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+-		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
++		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
+ 		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
+ 
+ CLEANFILES = $(BUILT_GIRSOURCES) $(typelibs_DATA)
+diff --git a/gst-libs/gst/video/Makefile.am b/gst-libs/gst/video/Makefile.am
+index ac64eb3..342c8c6 100644
+--- a/gst-libs/gst/video/Makefile.am
++++ b/gst-libs/gst/video/Makefile.am
+@@ -108,8 +108,8 @@ GstVideo-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstvideo-@GST_API_VE
+ 		--c-include "gst/video/video.h" \
+ 		-I$(top_srcdir)/gst-libs \
+ 		-I$(top_builddir)/gst-libs \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+-		--add-include-path=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
+ 		--library=libgstvideo-@GST_API_VERSION@.la \
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--include=GstBase-@GST_API_VERSION@ \
+@@ -136,8 +136,8 @@ typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
+ 		$(INTROSPECTION_COMPILER) \
+ 		--includedir=$(srcdir) \
+ 		--includedir=$(builddir) \
+-		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+-		--includedir=`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
++		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
++		--includedir=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-base-@GST_API_VERSION@` \
+ 		$(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
+ 
+ CLEANFILES += $(BUILT_GIRSOURCES) $(typelibs_DATA)
+-- 
+2.6.2
+
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0003-riff-add-missing-include-directories-when-calling-in.patch b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0003-riff-add-missing-include-directories-when-calling-in.patch
new file mode 100644
index 0000000..9b66f7f
--- /dev/null
+++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0003-riff-add-missing-include-directories-when-calling-in.patch
@@ -0,0 +1,28 @@
+From 3c2c2d5dd08aa30ed0e8acd8566ec99412bb8209 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Mon, 26 Oct 2015 17:29:37 +0200
+Subject: [PATCH 3/4] riff: add missing include directories when calling
+ introspection scanner
+
+Upstream-Status: Pending [review on oe-core maillist]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ gst-libs/gst/riff/Makefile.am | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/gst-libs/gst/riff/Makefile.am b/gst-libs/gst/riff/Makefile.am
+index 0a115cc..5057a58 100644
+--- a/gst-libs/gst/riff/Makefile.am
++++ b/gst-libs/gst/riff/Makefile.am
+@@ -39,6 +39,8 @@ libgstriff_@GST_API_VERSION@_la_LDFLAGS = $(GST_LIB_LDFLAGS) $(GST_ALL_LDFLAGS)
+ #		--strip-prefix=Gst \
+ #		--warn-all \
+ #		--c-include "gst/riff/riff.h" \
++#               -I$(top_srcdir)/gst-libs \
++#               -I$(top_builddir)/gst-libs \
+ #		--add-include-path=$(builddir)/../tag \
+ #		--add-include-path=$(builddir)/../audio \
+ #		--add-include-path=$(PKG_CONFIG_SYSROOT_DIR)`PKG_CONFIG_PATH="$(GST_PKG_CONFIG_PATH)" $(PKG_CONFIG) --variable=girdir gstreamer-@GST_API_VERSION@` \
+-- 
+2.6.2
+
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0004-rtsp-drop-incorrect-reference-to-gstreamer-sdp-in-Ma.patch b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0004-rtsp-drop-incorrect-reference-to-gstreamer-sdp-in-Ma.patch
new file mode 100644
index 0000000..42d99c1
--- /dev/null
+++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base/0004-rtsp-drop-incorrect-reference-to-gstreamer-sdp-in-Ma.patch
@@ -0,0 +1,27 @@
+From 4330915d88dc4dd46eb4c28d756482b767c2747f Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Mon, 26 Oct 2015 17:30:14 +0200
+Subject: [PATCH 4/4] rtsp: drop incorrect reference to gstreamer-sdp in
+ Makefile.am
+
+Upstream-Status: Pending [review on oe-core maillist]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ gst-libs/gst/rtsp/Makefile.am | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/gst-libs/gst/rtsp/Makefile.am b/gst-libs/gst/rtsp/Makefile.am
+index 4f6d9f8..0afa370 100644
+--- a/gst-libs/gst/rtsp/Makefile.am
++++ b/gst-libs/gst/rtsp/Makefile.am
+@@ -74,7 +74,6 @@ GstRtsp-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstrtsp-@GST_API_VERS
+ 		--libtool="$(LIBTOOL)" \
+ 		--pkg gio-2.0 \
+ 		--pkg gstreamer-@GST_API_VERSION@ \
+-		--pkg gstreamer-sdp-@GST_API_VERSION@ \
+ 		--pkg-export gstreamer-rtsp-@GST_API_VERSION@ \
+ 		--add-init-section="$(INTROSPECTION_INIT)" \
+ 		--output $@ \
+-- 
+2.6.2
+
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.6.3.bb b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.6.3.bb
index 429dc93..287d287 100644
--- a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.6.3.bb
+++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.6.3.bb
@@ -17,6 +17,10 @@ SRC_URI = " \
     file://0004-subparse-set-need_segment-after-sink-pad-received-GS.patch \
     file://encodebin-Need-more-buffers-in-output-queue-for-bett.patch \
     file://0005-convertframe-Support-video-crop-when-convert-frame.patch \
+    file://0001-Makefile.am-don-t-hardcode-libtool-name-when-running.patch \
+    file://0002-Makefile.am-prefix-calls-to-pkg-config-with-PKG_CONF.patch \
+    file://0003-riff-add-missing-include-directories-when-calling-in.patch \
+    file://0004-rtsp-drop-incorrect-reference-to-gstreamer-sdp-in-Ma.patch \
 "
 
 SRC_URI[md5sum] = "3ddde0ad598ef69f58d6a2e87f8b460f"
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins.inc b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins.inc
index 18ed6cf..128a1fe 100644
--- a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins.inc
+++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins.inc
@@ -5,7 +5,7 @@ SECTION = "multimedia"
 
 DEPENDS = "gstreamer1.0 glib-2.0-native"
 
-inherit autotools pkgconfig gettext upstream-version-is-even
+inherit autotools pkgconfig gettext upstream-version-is-even gobject-introspection
 
 acpaths = "-I ${S}/common/m4 -I ${S}/m4"
 
@@ -28,4 +28,13 @@ EXTRA_OECONF = " \
     --disable-examples \
 "
 
+SRC_URI_append = " file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch"
+
+delete_pkg_m4_file() {
+	# This m4 file is out of date and is missing PKG_CONFIG_SYSROOT_PATH tweaks which we need for introspection
+	rm "${S}/common/m4/pkg.m4" || true
+}
+
+do_configure[prefuncs] += " delete_pkg_m4_file"
+
 PACKAGES_DYNAMIC = "^${PN}-.*"
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server.inc b/meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server.inc
index 608842a..ae6d364 100644
--- a/meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server.inc
+++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server.inc
@@ -7,8 +7,18 @@ DEPENDS = "gstreamer1.0 libcgroup gstreamer1.0-plugins-base"
 
 PNREAL = "gst-rtsp-server"
 
-SRC_URI = "http://gstreamer.freedesktop.org/src/${PNREAL}/${PNREAL}-${PV}.tar.xz"
+SRC_URI = "http://gstreamer.freedesktop.org/src/${PNREAL}/${PNREAL}-${PV}.tar.xz \
+           file://0001-Don-t-hardcode-libtool-name-when-using-introspection.patch \
+           file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch"
 
 S = "${WORKDIR}/${PNREAL}-${PV}"
 
-inherit autotools pkgconfig upstream-version-is-even
+inherit autotools pkgconfig upstream-version-is-even gobject-introspection
+
+delete_pkg_m4_file() {
+        # This m4 file is out of date and is missing PKG_CONFIG_SYSROOT_PATH tweaks which we need for introspection
+        rm "${S}/common/m4/pkg.m4" || true
+}
+
+do_configure[prefuncs] += " delete_pkg_m4_file"
+
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server/0001-Don-t-hardcode-libtool-name-when-using-introspection.patch b/meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server/0001-Don-t-hardcode-libtool-name-when-using-introspection.patch
new file mode 100644
index 0000000..89d6384
--- /dev/null
+++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0-rtsp-server/0001-Don-t-hardcode-libtool-name-when-using-introspection.patch
@@ -0,0 +1,27 @@
+From 4a12569e5ae5be63cd92a9b178860026a99746b1 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Tue, 27 Oct 2015 16:55:45 +0200
+Subject: [PATCH] Don't hardcode libtool name when using introspection
+
+Upstream-Status: Pending [review on oe-core maillist]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ gst/rtsp-server/Makefile.am | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/gst/rtsp-server/Makefile.am b/gst/rtsp-server/Makefile.am
+index 4fcd366..c67f5ab 100644
+--- a/gst/rtsp-server/Makefile.am
++++ b/gst/rtsp-server/Makefile.am
+@@ -87,7 +87,7 @@ GstRtspServer-@GST_API_VERSION@.gir: $(INTROSPECTION_SCANNER) libgstrtspserver-@
+ 		--include=Gst-@GST_API_VERSION@ \
+ 		--include=GstRtsp-@GST_API_VERSION@ \
+ 		--include=GstNet-@GST_API_VERSION@ \
+-		--libtool="$(top_builddir)/libtool" \
++		--libtool="$(LIBTOOL)" \
+ 		--pkg gstreamer-@GST_API_VERSION@ \
+ 		--pkg gstreamer-rtsp-@GST_API_VERSION@ \
+ 		--pkg gstreamer-net-@GST_API_VERSION@ \
+-- 
+2.1.4
+
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0.inc b/meta/recipes-multimedia/gstreamer/gstreamer1.0.inc
index 5c212e6..e8f29ca 100644
--- a/meta/recipes-multimedia/gstreamer/gstreamer1.0.inc
+++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0.inc
@@ -8,7 +8,7 @@ LICENSE = "LGPLv2+"
 
 DEPENDS = "glib-2.0 glib-2.0-native libcap libxml2 bison-native flex-native"
 
-inherit autotools pkgconfig gettext upstream-version-is-even
+inherit autotools pkgconfig gettext upstream-version-is-even gobject-introspection
 
 PACKAGECONFIG ??= ""
 
@@ -37,3 +37,14 @@ FILES_${PN}-bash-completion += "${datadir}/bash-completion/completions/ ${datadi
 
 RRECOMMENDS_${PN}_qemux86 += "kernel-module-snd-ens1370 kernel-module-snd-rawmidi"
 RRECOMMENDS_${PN}_qemux86-64 += "kernel-module-snd-ens1370 kernel-module-snd-rawmidi"
+
+delete_pkg_m4_file() {
+        # This m4 file is out of date and is missing PKG_CONFIG_SYSROOT_PATH tweaks which we need for introspection
+        rm "${S}/common/m4/pkg.m4" || true
+}
+
+do_configure[prefuncs] += " delete_pkg_m4_file"
+
+do_compile_prepend() {
+        export GIR_EXTRA_LIBS_PATH="${B}/gst/.libs:${B}/libs/gst/base/.libs"
+}
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0_1.6.3.bb b/meta/recipes-multimedia/gstreamer/gstreamer1.0_1.6.3.bb
index ba1b83b..a79f449 100644
--- a/meta/recipes-multimedia/gstreamer/gstreamer1.0_1.6.3.bb
+++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0_1.6.3.bb
@@ -6,6 +6,7 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=6762ed442b3822387a51c92d928ead0d \
 SRC_URI = " \
     http://gstreamer.freedesktop.org/src/gstreamer/gstreamer-${PV}.tar.xz \
     file://0001-Fix-crash-with-gst-inspect.patch \
+    file://0001-introspection.m4-prefix-pkgconfig-paths-with-PKG_CON.patch \
 "
 
 SRC_URI[md5sum] = "b4cdeb2b9cb20dd6ac022a4f417eae0d"
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 17/24] gnomebase.bbclass: do not disable gobject introspection
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (15 preceding siblings ...)
  2016-03-09 15:02 ` [PATCH 16/24] gstreamer: " Alexander Kanavin
@ 2016-03-09 15:02 ` Alexander Kanavin
  2016-03-09 15:02 ` [PATCH 18/24] python-pygobject: update to 3.18.2 Alexander Kanavin
                   ` (6 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:02 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/classes/gnomebase.bbclass | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/meta/classes/gnomebase.bbclass b/meta/classes/gnomebase.bbclass
index d22ba5a..e5c6776 100644
--- a/meta/classes/gnomebase.bbclass
+++ b/meta/classes/gnomebase.bbclass
@@ -28,6 +28,3 @@ do_install_append() {
 	rm -f ${D}${datadir}/applications/*.cache
 }
 
-EXTRA_OECONF += "--disable-introspection"
-
-UNKNOWN_CONFIGURE_WHITELIST += "--disable-introspection"
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 18/24] python-pygobject: update to 3.18.2
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (16 preceding siblings ...)
  2016-03-09 15:02 ` [PATCH 17/24] gnomebase.bbclass: do not disable " Alexander Kanavin
@ 2016-03-09 15:02 ` Alexander Kanavin
  2016-03-09 15:02 ` [PATCH 19/24] recipes-gnome: fix introspection support Alexander Kanavin
                   ` (5 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:02 UTC (permalink / raw)
  To: openembedded-core

The new version of pygobject relies in gobject introspection;
this has prevented the update previously.

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 ...c-add-sysroot-path-to-GI_DATADIR-don-t-se.patch | 41 +++++++++++++++++
 .../obsolete_automake_macros.patch                 | 23 ----------
 .../python/python-pygobject_2.28.3.bb              | 53 ----------------------
 .../python/python-pygobject_3.18.2.bb              | 25 ++++++++++
 4 files changed, 66 insertions(+), 76 deletions(-)
 create mode 100644 meta/recipes-devtools/python/python-pygobject/0001-configure.ac-add-sysroot-path-to-GI_DATADIR-don-t-se.patch
 delete mode 100644 meta/recipes-devtools/python/python-pygobject/obsolete_automake_macros.patch
 delete mode 100644 meta/recipes-devtools/python/python-pygobject_2.28.3.bb
 create mode 100644 meta/recipes-devtools/python/python-pygobject_3.18.2.bb

diff --git a/meta/recipes-devtools/python/python-pygobject/0001-configure.ac-add-sysroot-path-to-GI_DATADIR-don-t-se.patch b/meta/recipes-devtools/python/python-pygobject/0001-configure.ac-add-sysroot-path-to-GI_DATADIR-don-t-se.patch
new file mode 100644
index 0000000..a391f7e
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pygobject/0001-configure.ac-add-sysroot-path-to-GI_DATADIR-don-t-se.patch
@@ -0,0 +1,41 @@
+From 5e5350d730f85957a42c6d846d347d080e7dd996 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Fri, 23 Oct 2015 12:40:34 +0300
+Subject: [PATCH] configure.ac: add sysroot path to GI_DATADIR; don't set
+ introspection scanner and compiler paths
+
+Upstream-Status: Pending [review on oe-core maillist]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ configure.ac | 8 +-------
+ 1 file changed, 1 insertion(+), 7 deletions(-)
+
+diff --git a/configure.ac b/configure.ac
+index 2c0cfbd..cfcb3bf 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -194,7 +194,7 @@ PKG_CHECK_MODULES(GI,
+     gobject-introspection-1.0 >= introspection_required_version
+ )
+ 
+-GI_DATADIR=$($PKG_CONFIG --variable=gidatadir gobject-introspection-1.0)
++GI_DATADIR=$PKG_CONFIG_SYSROOT_DIR$($PKG_CONFIG --variable=gidatadir gobject-introspection-1.0)
+ AC_SUBST(GI_DATADIR)
+ 
+ if test "$enable_cairo" != no; then
+@@ -219,12 +219,6 @@ AC_ARG_WITH(common,
+     with_common=yes)
+ AM_CONDITIONAL(WITH_COMMON, test "$with_common" = "yes")
+ 
+-INTROSPECTION_SCANNER=`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0`
+-INTROSPECTION_COMPILER=`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0`
+-
+-AC_SUBST(INTROSPECTION_SCANNER)
+-AC_SUBST(INTROSPECTION_COMPILER)
+-
+ # compiler warnings, errors, required cflags, and code coverage support
+ GNOME_COMPILE_WARNINGS([maximum])
+ AC_MSG_CHECKING(for Gnome code coverage support)
+-- 
+2.1.4
+
diff --git a/meta/recipes-devtools/python/python-pygobject/obsolete_automake_macros.patch b/meta/recipes-devtools/python/python-pygobject/obsolete_automake_macros.patch
deleted file mode 100644
index c259112..0000000
--- a/meta/recipes-devtools/python/python-pygobject/obsolete_automake_macros.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-Upstream-Status: Accepted [https://bugzilla.gnome.org/show_bug.cgi?id=691101]
-
-Signed-off-by: Marko Lindqvist <cazfi74@gmail.com>
-diff -Nurd pygobject-2.27.91/configure.ac pygobject-2.27.91/configure.ac
---- pygobject-2.27.91/configure.ac	2011-02-23 22:14:37.000000000 +0200
-+++ pygobject-2.27.91/configure.ac	2013-01-03 05:13:44.034949954 +0200
-@@ -35,7 +35,7 @@
- AC_DEFINE(PYGOBJECT_MICRO_VERSION, pygobject_micro_version, [pygobject micro version])
- AC_SUBST(PYGOBJECT_MICRO_VERSION, pygobject_micro_version)
-
--AM_CONFIG_HEADER(config.h)
-+AC_CONFIG_HEADERS(config.h)
- m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES(yes)])
- AM_INIT_AUTOMAKE(foreign)
- AM_MAINTAINER_MODE
-@@ -82,7 +82,6 @@
- m4_ifdef([LT_OUTPUT], [LT_OUTPUT])
- AC_ISC_POSIX
- AC_PROG_CC
--AM_PROG_CC_STDC
- AM_PROG_CC_C_O
-
- # check that we have the minimum version of python necisary to build
diff --git a/meta/recipes-devtools/python/python-pygobject_2.28.3.bb b/meta/recipes-devtools/python/python-pygobject_2.28.3.bb
deleted file mode 100644
index 81d37b4..0000000
--- a/meta/recipes-devtools/python/python-pygobject_2.28.3.bb
+++ /dev/null
@@ -1,53 +0,0 @@
-SUMMARY = "Python GObject bindings"
-SECTION = "devel/python"
-LICENSE = "LGPLv2.1"
-
-RECIPE_NO_UPDATE_REASON = "Newer versions of python-pygobject depend on gobject-introspection which doesn't cross-compile"
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=a916467b91076e631dd8edb7424769c7"
-DEPENDS = "python python-pygobject-native libffi glib-2.0"
-DEPENDS_class-native = "python-native libffi-native glib-2.0-native"
-RDEPENDS_class-native = ""
-
-MAJ_VER = "${@d.getVar('PV',1).split('.')[0]}.${@d.getVar('PV',1).split('.')[1]}"
-
-SRC_URI = "${GNOME_MIRROR}/pygobject/${MAJ_VER}/pygobject-${PV}.tar.bz2 \
-           file://obsolete_automake_macros.patch \
-"
-
-# libtool-native doesn't have fixinstall.patch applied which means
-# that libs get relinked at installation time. This triggers a 
-# relinking along the lines of:
-# gcc -L/tmp/foo/media/build1/poky/build/tmp/sysroots/x86_64-linux/usr/lib -lpyglib-2.0-python -o .libs/_glib.so
-# where /tmp/foo is DESTDIR and pyglib-2.0-python may be installed/reinstalled
-# at the same time as the gcc command runs.
-# If this happens between the handoff between gcc and ld, you can see:
-# /bin/ld: cannot find -lpyglib-2.0-python
-# Adding a dependency rule like  install-pyglibLTLIBRARIES: install-libLTLIBRARIES
-# would be ideal but automake can't cope with that without manually 
-# defining the whole function. Give up and disable parallel make in native builds.
-PARALLEL_MAKEINST_class-native = ""
-
-SRC_URI[md5sum] = "aa64900b274c4661a5c32e52922977f9"
-SRC_URI[sha256sum] = "7da88c169a56efccc516cebd9237da3fe518a343095a664607b368fe21df95b6"
-S = "${WORKDIR}/pygobject-${PV}"
-
-EXTRA_OECONF += "--disable-introspection"
-
-inherit autotools distutils-base pkgconfig
-
-# necessary to let the call for python-config succeed
-export BUILD_SYS
-export HOST_SYS
-export STAGING_INCDIR
-export STAGING_LIBDIR
-
-PACKAGES += "${PN}-lib"
-
-RDEPENDS_${PN} += "python-textutils"
-
-FILES_${PN} = "${libdir}/python*"
-FILES_${PN}-lib = "${libdir}/lib*.so.*"
-FILES_${PN}-dev += "${bindir} ${datadir}"
-
-BBCLASSEXTEND = "native"
diff --git a/meta/recipes-devtools/python/python-pygobject_3.18.2.bb b/meta/recipes-devtools/python/python-pygobject_3.18.2.bb
new file mode 100644
index 0000000..e61d75c
--- /dev/null
+++ b/meta/recipes-devtools/python/python-pygobject_3.18.2.bb
@@ -0,0 +1,25 @@
+SUMMARY = "Python GObject bindings"
+SECTION = "devel/python"
+LICENSE = "LGPLv2.1"
+LIC_FILES_CHKSUM = "file://COPYING;md5=a916467b91076e631dd8edb7424769c7"
+
+inherit autotools pkgconfig gnomebase distutils3-base gobject-introspection
+
+DEPENDS += "python3 glib-2.0 gnome-common"
+
+SRCNAME="pygobject"
+SRC_URI = " \
+    http://ftp.gnome.org/pub/GNOME/sources/${SRCNAME}/${@gnome_verdir("${PV}")}/${SRCNAME}-${PV}.tar.xz \
+    file://0001-configure.ac-add-sysroot-path-to-GI_DATADIR-don-t-se.patch \
+"
+
+SRC_URI[md5sum] = "0a956f3e785e23b0f136832f2e57a862"
+SRC_URI[sha256sum] = "2a3cad1517916b74e131e6002c3824361aee0671ffb0d55ded119477fc1c2c5f"
+
+S = "${WORKDIR}/${SRCNAME}-${PV}"
+
+BBCLASSEXTEND = "native"
+
+EXTRA_OECONF = "--disable-cairo"
+
+RDEPENDS_${PN} += "python3-setuptools"
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 19/24] recipes-gnome: fix introspection support
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (17 preceding siblings ...)
  2016-03-09 15:02 ` [PATCH 18/24] python-pygobject: update to 3.18.2 Alexander Kanavin
@ 2016-03-09 15:02 ` Alexander Kanavin
  2016-03-09 15:02 ` [PATCH 20/24] webkitgtk: enable gobject introspection Alexander Kanavin
                   ` (4 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:02 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/recipes-gnome/gcr/gcr_3.18.0.bb               |  22 +++-
 meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.32.3.bb |   7 +-
 .../gnome-desktop/gnome-desktop3_3.18.2.bb         |   2 +-
 meta/recipes-gnome/gnome/gconf_3.2.6.bb            |   6 +-
 .../gsettings-desktop-schemas_3.19.3.bb            |   4 +-
 meta/recipes-gnome/json-glib/json-glib_1.0.4.bb    |   2 +-
 meta/recipes-gnome/libgudev/libgudev_230.bb        |   2 +-
 meta/recipes-gnome/libnotify/libnotify_0.7.6.bb    |   2 +-
 meta/recipes-gnome/librsvg/librsvg_2.40.13.bb      |   5 +-
 meta/recipes-gnome/libsecret/libsecret_0.18.4.bb   |  14 ++-
 meta/recipes-gnome/libwnck/libwnck3_3.14.1.bb      |   4 +-
 ...op-introspection-macros-from-acinclude.m4.patch | 121 +++++++++++++++++++++
 meta/recipes-graphics/pango/pango_1.38.1.bb        |  10 +-
 meta/recipes-support/atk/at-spi2-core_2.18.3.bb    |   4 +-
 meta/recipes-support/atk/atk_2.18.0.bb             |   4 +-
 meta/recipes-support/vte/vte.inc                   |   6 +-
 meta/recipes-support/vte/vte_0.28.2.bb             |   3 +-
 17 files changed, 182 insertions(+), 36 deletions(-)
 create mode 100644 meta/recipes-graphics/pango/pango/0001-Drop-introspection-macros-from-acinclude.m4.patch

diff --git a/meta/recipes-gnome/gcr/gcr_3.18.0.bb b/meta/recipes-gnome/gcr/gcr_3.18.0.bb
index ed6e8c4..32523a6 100644
--- a/meta/recipes-gnome/gcr/gcr_3.18.0.bb
+++ b/meta/recipes-gnome/gcr/gcr_3.18.0.bb
@@ -5,9 +5,9 @@ BUGTRACKER = "https://bugzilla.gnome.org/"
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://COPYING;md5=55ca817ccb7d5b5b66355690e9abc605"
 
-DEPENDS = "gtk+3 p11-kit glib-2.0 libgcrypt vala"
+DEPENDS = "gtk+3 p11-kit glib-2.0 libgcrypt"
 
-inherit autotools gnomebase gtk-icon-cache gtk-doc distro_features_check upstream-version-is-even
+inherit autotools gnomebase gtk-icon-cache gtk-doc distro_features_check upstream-version-is-even vala gobject-introspection
 # depends on gtk+3, but also x11 through gtk+-x11
 REQUIRED_DISTRO_FEATURES = "x11"
 
@@ -21,3 +21,21 @@ FILES_${PN} += " \
 
 # http://errors.yoctoproject.org/Errors/Details/20229/
 ARM_INSTRUCTION_SET = "arm"
+
+# on x86-64 the introspection binary goes into 
+# an infinite loop under qemu during compilation, 
+# printing the following:
+# 
+# gcrypt-Message: select() error: Bad address
+#
+# gcrypt-Message: select() error: Bad address
+#
+# gcrypt-Message: select() error: Bad address
+#
+# This will be investigated later.
+EXTRA_OECONF_append_x86-64 = " --disable-introspection"
+
+# Gcr-3.broken: poky/build-mips64/tmp/work/mips64-poky-linux/libgpg-error/1.19-r0/libgpg-error-1.19/src/posix-lock.c:119: get_lock_object: Assertion `!"sizeof lock obj"' failed.
+# qemu: uncaught target signal 6 (Aborted) - core dumped
+EXTRA_OECONF_append_mips64 = " --disable-introspection"
+
diff --git a/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.32.3.bb b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.32.3.bb
index ed9c232..ba94eec 100644
--- a/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.32.3.bb
+++ b/meta/recipes-gnome/gdk-pixbuf/gdk-pixbuf_2.32.3.bb
@@ -22,7 +22,7 @@ SRC_URI = "${GNOME_MIRROR}/${BPN}/${MAJ_VER}/${BPN}-${PV}.tar.xz \
 SRC_URI[md5sum] = "9275076639baa24a342f3e02c402920e"
 SRC_URI[sha256sum] = "2b6771f1ac72f687a8971e59810b8dc658e65e7d3086bd2e676e618fd541d031"
 
-inherit autotools pkgconfig gettext pixbufcache ptest-gnome upstream-version-is-even
+inherit autotools pkgconfig gettext pixbufcache ptest-gnome upstream-version-is-even gobject-introspection
 
 LIBV = "2.10.0"
 
@@ -41,15 +41,12 @@ PACKAGECONFIG[jpeg2000] = "--with-libjasper,--without-libjasper,jasper"
 PACKAGECONFIG[gio-sniff] = "--enable-gio-sniffing,--disable-gio-sniffing,,shared-mime-info"
 PACKAGECONFIG[x11] = "--with-x11,--without-x11,virtual/libx11"
 
-EXTRA_OECONF = "--disable-introspection"
-
 PACKAGES =+ "${PN}-xlib"
 
 FILES_${PN}-xlib = "${libdir}/*pixbuf_xlib*${SOLIBS}"
 ALLOW_EMPTY_${PN}-xlib = "1"
 
-FILES_${PN} = "${libdir}/gdk-pixbuf-2.0/gdk-pixbuf-query-loaders \
-	${libdir}/lib*.so.*"
+FILES_${PN} += "${libdir}/gdk-pixbuf-2.0/gdk-pixbuf-query-loaders"
 
 FILES_${PN}-dev += " \
 	${bindir}/gdk-pixbuf-csource \
diff --git a/meta/recipes-gnome/gnome-desktop/gnome-desktop3_3.18.2.bb b/meta/recipes-gnome/gnome-desktop/gnome-desktop3_3.18.2.bb
index 09850d6..ee460d9 100644
--- a/meta/recipes-gnome/gnome-desktop/gnome-desktop3_3.18.2.bb
+++ b/meta/recipes-gnome/gnome-desktop/gnome-desktop3_3.18.2.bb
@@ -6,7 +6,7 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
 
 BPN = "gnome-desktop"
 
-inherit gnome pkgconfig upstream-version-is-even
+inherit gnome pkgconfig upstream-version-is-even gobject-introspection
 SRC_URI[archive.md5sum] = "9a5875247abdb99bad93f1c4230d1d6d"
 SRC_URI[archive.sha256sum] = "ddd46d022de137543a71f50c7392b32f9b98d5d3f2b53040b35f5802de2e7b56"
 
diff --git a/meta/recipes-gnome/gnome/gconf_3.2.6.bb b/meta/recipes-gnome/gnome/gconf_3.2.6.bb
index e50d077..feaf080 100644
--- a/meta/recipes-gnome/gnome/gconf_3.2.6.bb
+++ b/meta/recipes-gnome/gnome/gconf_3.2.6.bb
@@ -3,9 +3,9 @@ SECTION = "x11/gnome"
 LICENSE = "LGPLv2+"
 LIC_FILES_CHKSUM = "file://COPYING;md5=55ca817ccb7d5b5b66355690e9abc605"
 
-DEPENDS = "glib-2.0 dbus dbus-glib libxml2 intltool-native gobject-introspection-stub"
+DEPENDS = "glib-2.0 dbus dbus-glib libxml2 intltool-native"
 
-inherit gnomebase gtk-doc gettext
+inherit gnomebase gtk-doc gettext gobject-introspection
 
 SRC_URI = "${GNOME_MIRROR}/GConf/${@gnome_verdir("${PV}")}/GConf-${PV}.tar.xz;name=archive \
            file://remove_plus_from_invalid_characters_list.patch \
@@ -18,7 +18,7 @@ SRC_URI[archive.sha256sum] = "1912b91803ab09a5eed34d364bf09fe3a2a9c96751fde03a4e
 S = "${WORKDIR}/GConf-${PV}"
 
 EXTRA_OECONF = "--enable-shared --disable-static --enable-debug=yes \
-                --disable-introspection --disable-orbit --with-openldap=no --disable-gtk"
+                --disable-orbit --with-openldap=no --disable-gtk"
 
 # Disable PolicyKit by default
 PACKAGECONFIG ??= ""
diff --git a/meta/recipes-gnome/gsettings-desktop-schemas/gsettings-desktop-schemas_3.19.3.bb b/meta/recipes-gnome/gsettings-desktop-schemas/gsettings-desktop-schemas_3.19.3.bb
index 4c1fbfc..25fdaba 100644
--- a/meta/recipes-gnome/gsettings-desktop-schemas/gsettings-desktop-schemas_3.19.3.bb
+++ b/meta/recipes-gnome/gsettings-desktop-schemas/gsettings-desktop-schemas_3.19.3.bb
@@ -5,9 +5,9 @@ BUGTRACKER = "https://bugzilla.gnome.org/"
 LICENSE = "LGPLv2.1"
 LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
 
-DEPENDS = "glib-2.0 intltool-native gobject-introspection-stub-native"
+DEPENDS = "glib-2.0 intltool-native"
 
-inherit gnomebase gsettings gettext
+inherit gnomebase gsettings gettext gobject-introspection
 
 SRC_URI[archive.md5sum] = "fdc92abcffe46821be423193b275cf8b"
 SRC_URI[archive.sha256sum] = "9084989b75ca9b3fc5984c8a0d297a93d3d124f51cadd2bdaaaa75a783c80635"
diff --git a/meta/recipes-gnome/json-glib/json-glib_1.0.4.bb b/meta/recipes-gnome/json-glib/json-glib_1.0.4.bb
index 4908ac0..3ce38ce 100644
--- a/meta/recipes-gnome/json-glib/json-glib_1.0.4.bb
+++ b/meta/recipes-gnome/json-glib/json-glib_1.0.4.bb
@@ -13,6 +13,6 @@ DEPENDS = "glib-2.0"
 SRC_URI[archive.md5sum] = "3131b0417ecde3da1ae72acceaa375cf"
 SRC_URI[archive.sha256sum] = "80f3593cb6bd13f1465828e46a9f740e2e9bd3cd2257889442b3e62bd6de05cd"
 
-inherit gnomebase gettext lib_package
+inherit gnomebase gettext lib_package gobject-introspection
 
 BBCLASSEXTEND = "native"
diff --git a/meta/recipes-gnome/libgudev/libgudev_230.bb b/meta/recipes-gnome/libgudev/libgudev_230.bb
index c61316b..6a10502 100644
--- a/meta/recipes-gnome/libgudev/libgudev_230.bb
+++ b/meta/recipes-gnome/libgudev/libgudev_230.bb
@@ -10,5 +10,5 @@ RCONFLICTS_${PN} = "systemd (<= 220)"
 LICENSE = "LGPLv2.1"
 LIC_FILES_CHKSUM = "file://COPYING;md5=4fbd65380cdd255951079008b364516c"
 
-inherit gnomebase
+inherit gnomebase gobject-introspection
 
diff --git a/meta/recipes-gnome/libnotify/libnotify_0.7.6.bb b/meta/recipes-gnome/libnotify/libnotify_0.7.6.bb
index 1a24c10..ce8e5ae 100644
--- a/meta/recipes-gnome/libnotify/libnotify_0.7.6.bb
+++ b/meta/recipes-gnome/libnotify/libnotify_0.7.6.bb
@@ -5,7 +5,7 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=7fbc338309ac38fefcd64b04bb903e34"
 
 DEPENDS = "dbus gtk+3 dbus-glib"
 
-inherit gnomebase gtk-doc distro_features_check
+inherit gnomebase gtk-doc distro_features_check gobject-introspection
 # depends on gtk+3
 ANY_OF_DISTRO_FEATURES = "${GTK3DISTROFEATURES}"
 
diff --git a/meta/recipes-gnome/librsvg/librsvg_2.40.13.bb b/meta/recipes-gnome/librsvg/librsvg_2.40.13.bb
index ed71243..2ac52f7 100644
--- a/meta/recipes-gnome/librsvg/librsvg_2.40.13.bb
+++ b/meta/recipes-gnome/librsvg/librsvg_2.40.13.bb
@@ -10,7 +10,7 @@ SECTION = "x11/utils"
 DEPENDS = "cairo gdk-pixbuf glib-2.0 libcroco libxml2 pango"
 BBCLASSEXTEND = "native"
 
-inherit autotools pkgconfig gnomebase gtk-doc pixbufcache upstream-version-is-even
+inherit autotools pkgconfig gnomebase gtk-doc pixbufcache upstream-version-is-even gobject-introspection
 
 SRC_URI += "file://gtk-option.patch"
 
@@ -19,8 +19,6 @@ SRC_URI[archive.sha256sum] = "4d6ea93ec05f5dabe7262d711d246a0a99b2311e215360dd3d
 
 CACHED_CONFIGUREVARS = "ac_cv_path_GDK_PIXBUF_QUERYLOADERS=${STAGING_LIBDIR_NATIVE}/gdk-pixbuf-2.0/gdk-pixbuf-query-loaders"
 
-EXTRA_OECONF = "--disable-introspection --disable-vala"
-
 # The older ld (2.22) on the host (Centos 6.5) doesn't have the
 # -Bsymbolic-functions option, we can disable it for native.
 EXTRA_OECONF_append_class-native = " --enable-Bsymbolic=auto"
@@ -37,7 +35,6 @@ do_install_append() {
 }
 
 PACKAGES =+ "librsvg-gtk rsvg"
-FILES_${PN} = "${libdir}/*.so.*"
 FILES_rsvg = "${bindir}/rsvg* \
 	      ${datadir}/pixmaps/svg-viewer.svg \
 	      ${datadir}/themes"
diff --git a/meta/recipes-gnome/libsecret/libsecret_0.18.4.bb b/meta/recipes-gnome/libsecret/libsecret_0.18.4.bb
index 534caad..beaaba0 100644
--- a/meta/recipes-gnome/libsecret/libsecret_0.18.4.bb
+++ b/meta/recipes-gnome/libsecret/libsecret_0.18.4.bb
@@ -2,9 +2,9 @@ SUMMARY = "libsecret is a library for storing and retrieving passwords and other
 LICENSE = "LGPLv2.1"
 LIC_FILES_CHKSUM = "file://COPYING;md5=23c2a5e0106b99d75238986559bb5fc6"
 
-inherit gnomebase gtk-doc
+inherit gnomebase gtk-doc vala gobject-introspection
 
-DEPENDS = "glib-2.0 libgcrypt gettext-native intltool-native"
+DEPENDS += "glib-2.0 libgcrypt gettext-native intltool-native"
 
 EXTRA_OECONF += "--disable-manpages"
 
@@ -13,3 +13,13 @@ SRC_URI[archive.sha256sum] = "0f29b51698198e6999c91f4adce3119c8c457f546b133a85ba
 
 # http://errors.yoctoproject.org/Errors/Details/20228/
 ARM_INSTRUCTION_SET = "arm"
+
+# vapigen.m4 bundled with the tarball does not yet have our cross-compilation fixes
+do_configure_prepend() {
+    rm -f ${S}/build/m4/vapigen.m4
+}
+
+# Secret-1: poky/build-mips64/tmp/work/mips64-poky-linux/libgpg-error/1.19-r0/libgpg-error-1.19/src/posix-lock.c:119: get_lock_object: Assertion `!"sizeof lock obj"' failed.
+# qemu: uncaught target signal 6 (Aborted) - core dumped
+EXTRA_OECONF_append_mips64 = " --disable-introspection"
+
diff --git a/meta/recipes-gnome/libwnck/libwnck3_3.14.1.bb b/meta/recipes-gnome/libwnck/libwnck3_3.14.1.bb
index 97d6b88..495894b 100644
--- a/meta/recipes-gnome/libwnck/libwnck3_3.14.1.bb
+++ b/meta/recipes-gnome/libwnck/libwnck3_3.14.1.bb
@@ -5,12 +5,12 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=5f30f0716dfdd0d91eb439ebec522ec2"
 BPN = "libwnck"
 
 SECTION = "x11/libs"
-DEPENDS = "gobject-introspection-stub gtk+3 gdk-pixbuf-native libxres"
+DEPENDS = "gtk+3 gdk-pixbuf-native libxres"
 
 PACKAGECONFIG ??= "startup-notification"
 PACKAGECONFIG[startup-notification] = "--enable-startup-notification,--disable-startup-notification,startup-notification"
 
-inherit gnomebase
+inherit gnomebase gobject-introspection
 SRC_URI[archive.md5sum] = "d96c0b74c4dc5fdae758964098603c90"
 SRC_URI[archive.sha256sum] = "bb643c9c423c8aa79c59973ce27ce91d3b180d1e9907902278fb79391f52befa"
 
diff --git a/meta/recipes-graphics/pango/pango/0001-Drop-introspection-macros-from-acinclude.m4.patch b/meta/recipes-graphics/pango/pango/0001-Drop-introspection-macros-from-acinclude.m4.patch
new file mode 100644
index 0000000..812da21
--- /dev/null
+++ b/meta/recipes-graphics/pango/pango/0001-Drop-introspection-macros-from-acinclude.m4.patch
@@ -0,0 +1,121 @@
+From 867a512eddbeb1899d3e7096df3da1dd0ce3e7b7 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Fri, 23 Oct 2015 14:06:17 +0300
+Subject: [PATCH] Drop introspection macros from acinclude.m4
+
+They take precendence over our customized macros, and so
+introspection doesn't work correctly.
+
+Upstream-Status: Pending [review on oe-core list]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ acinclude.m4 | 96 ------------------------------------------------------------
+ 1 file changed, 96 deletions(-)
+
+diff --git a/acinclude.m4 b/acinclude.m4
+index 8899c7c..48fd5d8 100644
+--- a/acinclude.m4
++++ b/acinclude.m4
+@@ -55,99 +55,3 @@ AC_DEFUN([JH_CHECK_XML_CATALOG],
+ ])
+ 
+ 
+-dnl REMOVE THIS WHEN introspection.m4 is widely available
+-dnl
+-dnl -*- mode: autoconf -*-
+-dnl Copyright 2009 Johan Dahlin
+-dnl
+-dnl This file is free software; the author(s) gives unlimited
+-dnl permission to copy and/or distribute it, with or without
+-dnl modifications, as long as this notice is preserved.
+-dnl
+-
+-# serial 1
+-
+-m4_define([_GOBJECT_INTROSPECTION_CHECK_INTERNAL],
+-[
+-    AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first
+-    AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first
+-    AC_BEFORE([LT_INIT],[$0])dnl setup libtool first
+-
+-    dnl enable/disable introspection
+-    m4_if([$2], [require],
+-    [dnl
+-        enable_introspection=yes
+-    ],[dnl
+-        AC_ARG_ENABLE(introspection,
+-                  AS_HELP_STRING([--enable-introspection[=@<:@no/auto/yes@:>@]],
+-                                 [Enable introspection for this build]),, 
+-                                 [enable_introspection=auto])
+-    ])dnl
+-
+-    AC_MSG_CHECKING([for gobject-introspection])
+-
+-    dnl presence/version checking
+-    AS_CASE([$enable_introspection],
+-    [no], [dnl
+-        found_introspection="no (disabled, use --enable-introspection to enable)"
+-    ],dnl
+-    [yes],[dnl
+-        PKG_CHECK_EXISTS([gobject-introspection-1.0],,
+-                         AC_MSG_ERROR([gobject-introspection-1.0 is not installed]))
+-        PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1],
+-                         found_introspection=yes,
+-                         AC_MSG_ERROR([You need to have gobject-introspection >= $1 installed to build AC_PACKAGE_NAME]))
+-    ],dnl
+-    [auto],[dnl
+-        PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1], found_introspection=yes, found_introspection=no)
+-    ],dnl
+-    [dnl	
+-        AC_MSG_ERROR([invalid argument passed to --enable-introspection, should be one of @<:@no/auto/yes@:>@])
+-    ])dnl
+-
+-    AC_MSG_RESULT([$found_introspection])
+-
+-    INTROSPECTION_SCANNER=
+-    INTROSPECTION_COMPILER=
+-    INTROSPECTION_GENERATE=
+-    INTROSPECTION_GIRDIR=
+-    INTROSPECTION_TYPELIBDIR=
+-    if test "x$found_introspection" = "xyes"; then
+-       INTROSPECTION_SCANNER=`$PKG_CONFIG --variable=g_ir_scanner gobject-introspection-1.0`
+-       INTROSPECTION_COMPILER=`$PKG_CONFIG --variable=g_ir_compiler gobject-introspection-1.0`
+-       INTROSPECTION_GENERATE=`$PKG_CONFIG --variable=g_ir_generate gobject-introspection-1.0`
+-       INTROSPECTION_GIRDIR=`$PKG_CONFIG --variable=girdir gobject-introspection-1.0`
+-       INTROSPECTION_TYPELIBDIR="$($PKG_CONFIG --variable=typelibdir gobject-introspection-1.0)"
+-       INTROSPECTION_CFLAGS=`$PKG_CONFIG --cflags gobject-introspection-1.0`
+-       INTROSPECTION_LIBS=`$PKG_CONFIG --libs gobject-introspection-1.0`
+-       INTROSPECTION_MAKEFILE=`$PKG_CONFIG --variable=datadir gobject-introspection-1.0`/gobject-introspection-1.0/Makefile.introspection
+-    fi
+-    AC_SUBST(INTROSPECTION_SCANNER)
+-    AC_SUBST(INTROSPECTION_COMPILER)
+-    AC_SUBST(INTROSPECTION_GENERATE)
+-    AC_SUBST(INTROSPECTION_GIRDIR)
+-    AC_SUBST(INTROSPECTION_TYPELIBDIR)
+-    AC_SUBST(INTROSPECTION_CFLAGS)
+-    AC_SUBST(INTROSPECTION_LIBS)
+-    AC_SUBST(INTROSPECTION_MAKEFILE)
+-
+-    AM_CONDITIONAL(HAVE_INTROSPECTION, test "x$found_introspection" = "xyes")
+-])
+-
+-
+-dnl Usage:
+-dnl   GOBJECT_INTROSPECTION_CHECK([minimum-g-i-version])
+-
+-AC_DEFUN([GOBJECT_INTROSPECTION_CHECK],
+-[
+-  _GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1])
+-])
+-
+-dnl Usage:
+-dnl   GOBJECT_INTROSPECTION_REQUIRE([minimum-g-i-version])
+-
+-
+-AC_DEFUN([GOBJECT_INTROSPECTION_REQUIRE],
+-[
+-  _GOBJECT_INTROSPECTION_CHECK_INTERNAL([$1], [require])
+-])
+-- 
+2.1.4
+
diff --git a/meta/recipes-graphics/pango/pango_1.38.1.bb b/meta/recipes-graphics/pango/pango_1.38.1.bb
index a9a7500..7fc65fd 100644
--- a/meta/recipes-graphics/pango/pango_1.38.1.bb
+++ b/meta/recipes-graphics/pango/pango_1.38.1.bb
@@ -11,7 +11,11 @@ LICENSE = "LGPLv2.0+"
 
 LIC_FILES_CHKSUM = "file://COPYING;md5=3bf50002aefd002f49e7bb854063f7e7"
 
-SRC_URI += "file://run-ptest"
+inherit gnomebase gtk-doc ptest-gnome upstream-version-is-even gobject-introspection
+
+SRC_URI += "file://run-ptest \
+            file://0001-Drop-introspection-macros-from-acinclude.m4.patch \
+"
 
 SRC_URI[archive.md5sum] = "7fde35d4a127b55ce8bbcefe109bc80d"
 SRC_URI[archive.sha256sum] = "1320569f6c6d75d6b66172b2d28e59c56ee864ee9df202b76799c4506a214eb7"
@@ -21,11 +25,9 @@ DEPENDS = "glib-2.0 glib-2.0-native fontconfig freetype virtual/libiconv cairo h
 PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', '', d)}"
 PACKAGECONFIG[x11] = "--with-xft,--without-xft,virtual/libx11 libxft"
 
-inherit gnomebase gtk-doc ptest-gnome upstream-version-is-even
-
 EXTRA_AUTORECONF = ""
 
-EXTRA_OECONF = "--disable-introspection \
+EXTRA_OECONF = " \
 	        --disable-debug \
 	        "
 
diff --git a/meta/recipes-support/atk/at-spi2-core_2.18.3.bb b/meta/recipes-support/atk/at-spi2-core_2.18.3.bb
index f22bb83..eced597 100644
--- a/meta/recipes-support/atk/at-spi2-core_2.18.3.bb
+++ b/meta/recipes-support/atk/at-spi2-core_2.18.3.bb
@@ -13,11 +13,11 @@ SRC_URI[sha256sum] = "ada26add94155f97d0f601a20cb7a0e3fd3ba1588c3520b72883164940
 
 DEPENDS = "dbus glib-2.0 virtual/libx11 libxi libxtst intltool-native gettext-native"
 
-inherit autotools gtk-doc pkgconfig distro_features_check upstream-version-is-even
+inherit autotools gtk-doc pkgconfig distro_features_check upstream-version-is-even gobject-introspection
 # depends on virtual/libx11
 REQUIRED_DISTRO_FEATURES = "x11"
 
-EXTRA_OECONF = "--disable-introspection --disable-xevie --with-dbus-daemondir=${bindir}"
+EXTRA_OECONF = "--disable-xevie --with-dbus-daemondir=${bindir}"
 
 FILES_${PN} += "${datadir}/dbus-1/services/*.service \
                 ${datadir}/dbus-1/accessibility-services/*.service"
diff --git a/meta/recipes-support/atk/atk_2.18.0.bb b/meta/recipes-support/atk/atk_2.18.0.bb
index 97e2d22..3c0e82d 100644
--- a/meta/recipes-support/atk/atk_2.18.0.bb
+++ b/meta/recipes-support/atk/atk_2.18.0.bb
@@ -10,7 +10,7 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=3bf50002aefd002f49e7bb854063f7e7 \
 
 DEPENDS = "glib-2.0"
 
-inherit gnomebase gtk-doc upstream-version-is-even
+inherit gnomebase gtk-doc upstream-version-is-even gobject-introspection
 
 SRC_URI[archive.md5sum] = "fd3678f35004b4c92e3da39356996054"
 SRC_URI[archive.sha256sum] = "ce6c48d77bf951083029d5a396dd552d836fff3c1715d3a7022e917e46d0c92b"
@@ -18,4 +18,4 @@ SRC_URI[archive.sha256sum] = "ce6c48d77bf951083029d5a396dd552d836fff3c1715d3a702
 BBCLASSEXTEND = "native"
 
 EXTRA_OECONF = "--disable-glibtest \
-                --disable-introspection"
+               "
diff --git a/meta/recipes-support/vte/vte.inc b/meta/recipes-support/vte/vte.inc
index 68499d6..8565cc2 100644
--- a/meta/recipes-support/vte/vte.inc
+++ b/meta/recipes-support/vte/vte.inc
@@ -1,13 +1,13 @@
 SUMMARY = "Virtual terminal emulator GTK+ widget library"
 BUGTRACKER = "https://bugzilla.gnome.org/buglist.cgi?product=vte"
 LICENSE = "LGPLv2.0"
-DEPENDS = " glib-2.0 gtk+ intltool-native ncurses gobject-introspection-stub"
+DEPENDS = " glib-2.0 gtk+ intltool-native ncurses"
 RDEPENDS_libvte = "vte-termcap"
 
-inherit gnome gtk-doc distro_features_check upstream-version-is-even
+inherit gnome gtk-doc distro_features_check upstream-version-is-even gobject-introspection
 ANY_OF_DISTRO_FEATURES = "${GTK2DISTROFEATURES}"
 
-EXTRA_OECONF = "--disable-python --disable-introspection"
+EXTRA_OECONF = "--disable-python"
 
 PACKAGES =+ "libvte vte-termcap"
 FILES_libvte = "${libdir}/*.so.* ${libexecdir}/gnome-pty-helper"
diff --git a/meta/recipes-support/vte/vte_0.28.2.bb b/meta/recipes-support/vte/vte_0.28.2.bb
index 8b4e7f7..74087ca 100644
--- a/meta/recipes-support/vte/vte_0.28.2.bb
+++ b/meta/recipes-support/vte/vte_0.28.2.bb
@@ -5,7 +5,8 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=3bf50002aefd002f49e7bb854063f7e7"
 PR = "r6"
 
 SRC_URI += "file://obsolete_automake_macros.patch \
-            file://cve-2012-2738.patch"
+            file://cve-2012-2738.patch \
+           "
 
 CFLAGS += "-D_GNU_SOURCE"
 
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 20/24] webkitgtk: enable gobject introspection
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (18 preceding siblings ...)
  2016-03-09 15:02 ` [PATCH 19/24] recipes-gnome: fix introspection support Alexander Kanavin
@ 2016-03-09 15:02 ` Alexander Kanavin
  2016-03-09 15:02 ` [PATCH 21/24] packagegroup-core-x11-sato: add python-pygobject and gtk+3 Alexander Kanavin
                   ` (3 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:02 UTC (permalink / raw)
  To: openembedded-core

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 ...Introspection.cmake-prefix-variables-obta.patch | 27 +++++++++++++++
 ...cmake-drop-the-hardcoded-introspection-gt.patch | 35 +++++++++++++++++++
 ...ng-introspection-files-add-CMAKE_C_FLAGS-.patch | 40 ++++++++++++++++++++++
 meta/recipes-sato/webkit/webkitgtk_2.10.7.bb       | 14 ++++++--
 4 files changed, 114 insertions(+), 2 deletions(-)
 create mode 100644 meta/recipes-sato/webkit/files/0001-FindGObjectIntrospection.cmake-prefix-variables-obta.patch
 create mode 100644 meta/recipes-sato/webkit/files/0001-OptionsGTK.cmake-drop-the-hardcoded-introspection-gt.patch
 create mode 100644 meta/recipes-sato/webkit/files/0001-When-building-introspection-files-add-CMAKE_C_FLAGS-.patch

diff --git a/meta/recipes-sato/webkit/files/0001-FindGObjectIntrospection.cmake-prefix-variables-obta.patch b/meta/recipes-sato/webkit/files/0001-FindGObjectIntrospection.cmake-prefix-variables-obta.patch
new file mode 100644
index 0000000..fae3b0b
--- /dev/null
+++ b/meta/recipes-sato/webkit/files/0001-FindGObjectIntrospection.cmake-prefix-variables-obta.patch
@@ -0,0 +1,27 @@
+From 317a5ac120c44987219bc03486cd2f2d1842c9b9 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Tue, 27 Oct 2015 16:02:19 +0200
+Subject: [PATCH] FindGObjectIntrospection.cmake: prefix variables obtained
+ from pkg-config with PKG_CONFIG_SYSROOT_DIR
+
+Upstream-Status: Pending [review on oe-core list]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ Source/cmake/FindGObjectIntrospection.cmake | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/Source/cmake/FindGObjectIntrospection.cmake b/Source/cmake/FindGObjectIntrospection.cmake
+index e1f49b4..03a4446 100644
+--- a/Source/cmake/FindGObjectIntrospection.cmake
++++ b/Source/cmake/FindGObjectIntrospection.cmake
+@@ -26,6 +26,7 @@ macro(_GIR_GET_PKGCONFIG_VAR _outvar _varname _extra_args)
+     else ()
+         string(REGEX REPLACE "[\r\n]" " " _result "${_result}")
+         string(REGEX REPLACE " +$" ""  _result "${_result}")
++        string(CONCAT _result $ENV{PKG_CONFIG_SYSROOT_DIR} "${_result}")
+         separate_arguments(_result)
+         set(${_outvar} ${_result} CACHE INTERNAL "")
+     endif ()
+-- 
+2.1.4
+
diff --git a/meta/recipes-sato/webkit/files/0001-OptionsGTK.cmake-drop-the-hardcoded-introspection-gt.patch b/meta/recipes-sato/webkit/files/0001-OptionsGTK.cmake-drop-the-hardcoded-introspection-gt.patch
new file mode 100644
index 0000000..3d004db
--- /dev/null
+++ b/meta/recipes-sato/webkit/files/0001-OptionsGTK.cmake-drop-the-hardcoded-introspection-gt.patch
@@ -0,0 +1,35 @@
+From 48648570e449cf7f84a26dc03c1e3f620fa69757 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Mon, 29 Feb 2016 18:13:39 +0200
+Subject: [PATCH] OptionsGTK.cmake: drop the hardcoded introspection/gtkdoc
+ disabling when cross-compiling
+
+This was not possible to override from the command line and in OpenEmbedded
+(one of the most prominent cross-compilation frameworks) introspection does work fine,
+through the use of qemu target emulation.
+
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ Source/cmake/OptionsGTK.cmake | 6 ------
+ 1 file changed, 6 deletions(-)
+
+diff --git a/Source/cmake/OptionsGTK.cmake b/Source/cmake/OptionsGTK.cmake
+index e5f1f5b..4698036 100644
+--- a/Source/cmake/OptionsGTK.cmake
++++ b/Source/cmake/OptionsGTK.cmake
+@@ -443,12 +443,6 @@ if (USE_LIBHYPHEN)
+     endif ()
+ endif ()
+ 
+-# Override the cached variables, gtk-doc and gobject-introspection do not really work when cross-building.
+-if (CMAKE_CROSSCOMPILING)
+-    set(ENABLE_GTKDOC OFF)
+-    set(ENABLE_INTROSPECTION OFF)
+-endif ()
+-
+ set(DERIVED_SOURCES_GOBJECT_DOM_BINDINGS_DIR ${DERIVED_SOURCES_DIR}/webkitdom)
+ set(DERIVED_SOURCES_WEBKITGTK_DIR ${DERIVED_SOURCES_DIR}/webkitgtk)
+ set(DERIVED_SOURCES_WEBKITGTK_API_DIR ${DERIVED_SOURCES_WEBKITGTK_DIR}/webkit)
+-- 
+2.7.0
+
diff --git a/meta/recipes-sato/webkit/files/0001-When-building-introspection-files-add-CMAKE_C_FLAGS-.patch b/meta/recipes-sato/webkit/files/0001-When-building-introspection-files-add-CMAKE_C_FLAGS-.patch
new file mode 100644
index 0000000..44b43cd
--- /dev/null
+++ b/meta/recipes-sato/webkit/files/0001-When-building-introspection-files-add-CMAKE_C_FLAGS-.patch
@@ -0,0 +1,40 @@
+From bae9f73b2c693b5aa156fed717d6481b60682786 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Wed, 28 Oct 2015 14:18:57 +0200
+Subject: [PATCH] When building introspection files, add CMAKE_C_FLAGS to the
+ compiler flags.
+
+g-ir-compiler is using a C compiler internally, so it needs to set
+the proper flags for it.
+
+Upstream-Status: Pending [review on oe-core list]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ Source/WebKit2/PlatformGTK.cmake | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/Source/WebKit2/PlatformGTK.cmake b/Source/WebKit2/PlatformGTK.cmake
+index 706f1e8..14a1c3b 100644
+--- a/Source/WebKit2/PlatformGTK.cmake
++++ b/Source/WebKit2/PlatformGTK.cmake
+@@ -884,7 +884,7 @@ add_custom_command(
+     OUTPUT ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
+     DEPENDS WebKit2
+     DEPENDS ${CMAKE_BINARY_DIR}/JavaScriptCore-${WEBKITGTK_API_VERSION}.gir
+-    COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations LDFLAGS=
++    COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations\ ${CMAKE_C_FLAGS} LDFLAGS=
+         LD_LIBRARY_PATH="${INTROSPECTION_ADDITIONAL_LIBRARY_PATH}"
+         ${INTROSPECTION_SCANNER}
+         --quiet
+@@ -930,7 +930,7 @@ add_custom_command(
+     OUTPUT ${CMAKE_BINARY_DIR}/WebKit2WebExtension-${WEBKITGTK_API_VERSION}.gir
+     DEPENDS ${CMAKE_BINARY_DIR}/JavaScriptCore-${WEBKITGTK_API_VERSION}.gir
+     DEPENDS ${CMAKE_BINARY_DIR}/WebKit2-${WEBKITGTK_API_VERSION}.gir
+-    COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations
++    COMMAND CC=${CMAKE_C_COMPILER} CFLAGS=-Wno-deprecated-declarations\ ${CMAKE_C_FLAGS}
+         LDFLAGS="${INTROSPECTION_ADDITIONAL_LDFLAGS}"
+         LD_LIBRARY_PATH="${INTROSPECTION_ADDITIONAL_LIBRARY_PATH}"
+         ${INTROSPECTION_SCANNER}
+-- 
+2.6.4
+
diff --git a/meta/recipes-sato/webkit/webkitgtk_2.10.7.bb b/meta/recipes-sato/webkit/webkitgtk_2.10.7.bb
index 8812967..849a33a 100644
--- a/meta/recipes-sato/webkit/webkitgtk_2.10.7.bb
+++ b/meta/recipes-sato/webkit/webkitgtk_2.10.7.bb
@@ -15,11 +15,14 @@ SRC_URI = "\
   file://clang.patch \
   file://0001-Enable-backtrace-on-linux-when-using-glibc.patch \
   file://0001-Fix-build-with-non-glibc-libraries-on-linux.patch \
+  file://0001-FindGObjectIntrospection.cmake-prefix-variables-obta.patch \
+  file://0001-When-building-introspection-files-add-CMAKE_C_FLAGS-.patch \
+  file://0001-OptionsGTK.cmake-drop-the-hardcoded-introspection-gt.patch \
   "
 SRC_URI[md5sum] = "84832b9d8329413b4f1d87df5f7e8efe"
 SRC_URI[sha256sum] = "990d62c82ed6dede31a6ff0a82d847f16b812842ff3e1093d17113627652864e"
 
-inherit cmake lib_package pkgconfig perlnative pythonnative distro_features_check upstream-version-is-even
+inherit cmake lib_package pkgconfig perlnative pythonnative distro_features_check upstream-version-is-even gobject-introspection
 
 # depends on libxt
 REQUIRED_DISTRO_FEATURES = "x11"
@@ -51,7 +54,7 @@ PACKAGECONFIG[libhyphen] = "-DUSE_LIBHYPHEN=ON,-DUSE_LIBHYPHEN=OFF,libhyphen"
 EXTRA_OECMAKE = " \
 		-DPORT=GTK \
 		-DCMAKE_BUILD_TYPE=Release \
-		-DENABLE_INTROSPECTION=OFF \
+		${@bb.utils.contains('COMBINED_FEATURES', 'gobject-introspection-data', '-DENABLE_INTROSPECTION=ON', '-DENABLE_INTROSPECTION=OFF', d)} \
 		-DENABLE_GTKDOC=OFF \
 		-DENABLE_MINIBROWSER=ON \
 		"
@@ -76,3 +79,10 @@ FILES_${PN} += "${libdir}/webkit2gtk-4.0/injected-bundle/libwebkit2gtkinjectedbu
 
 # http://errors.yoctoproject.org/Errors/Details/20370/
 ARM_INSTRUCTION_SET = "arm"
+
+# Invalid data memory access: 0x00000000
+# ...
+# qemu: uncaught target signal 11 (Segmentation fault) - core dumped
+# Segmentation fault
+EXTRA_OECMAKE_append_powerpc = " -DENABLE_INTROSPECTION=OFF "
+
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 21/24] packagegroup-core-x11-sato: add python-pygobject and gtk+3
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (19 preceding siblings ...)
  2016-03-09 15:02 ` [PATCH 20/24] webkitgtk: enable gobject introspection Alexander Kanavin
@ 2016-03-09 15:02 ` Alexander Kanavin
  2016-03-09 15:02 ` [PATCH 22/24] bitbake.conf: add 'gobject-introspection-data' to DISTRO/MACHINE_FEATURES_BACKFILL Alexander Kanavin
                   ` (2 subsequent siblings)
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:02 UTC (permalink / raw)
  To: openembedded-core

This allows easy testing of introspection for example using
http://python-gtk-3-tutorial.readthedocs.org/en/latest/introduction.html

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/recipes-sato/packagegroups/packagegroup-core-x11-sato.bb | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/meta/recipes-sato/packagegroups/packagegroup-core-x11-sato.bb b/meta/recipes-sato/packagegroups/packagegroup-core-x11-sato.bb
index 8ba4923..6abb426 100644
--- a/meta/recipes-sato/packagegroups/packagegroup-core-x11-sato.bb
+++ b/meta/recipes-sato/packagegroups/packagegroup-core-x11-sato.bb
@@ -39,6 +39,8 @@ RDEPENDS_${PN}-base = "\
     ${NETWORK_MANAGER} \
     udev-extraconf \
     ${@bb.utils.contains('DISTRO_FEATURES', 'pulseaudio', 'pulseaudio-server pulseaudio-client-conf-sato pulseaudio-misc', '', d)} \
+    python-pygobject \
+    gtk+3 \
     "
 
 FILEMANAGER ?= "pcmanfm"
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 22/24] bitbake.conf: add 'gobject-introspection-data' to DISTRO/MACHINE_FEATURES_BACKFILL
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (20 preceding siblings ...)
  2016-03-09 15:02 ` [PATCH 21/24] packagegroup-core-x11-sato: add python-pygobject and gtk+3 Alexander Kanavin
@ 2016-03-09 15:02 ` Alexander Kanavin
  2016-03-09 15:02 ` [PATCH 23/24] machine/include/arch-x86: Make x32 ABI not supporting gobject-introspection-data Alexander Kanavin
  2016-03-09 15:02 ` [PATCH 24/24] musl: disable building of gobject introspection data Alexander Kanavin
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:02 UTC (permalink / raw)
  To: openembedded-core

This means that introspection data will be generated using qemu by default.

If this causes trouble (qemu does not always emulate target architectures
perfectly), then add
MACHINE_FEATURES_BACKFILL_CONSIDERED = "gobject-introspection-data"
to machine configuration or
DISTRO_FEATURES_BACKFILL_CONSIDERED = "gobject-introspection-data"
to distro configuration.

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/conf/bitbake.conf | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf
index 9cec7dd..7ed5ffb 100644
--- a/meta/conf/bitbake.conf
+++ b/meta/conf/bitbake.conf
@@ -761,8 +761,8 @@ MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS ?= ""
 EXTRA_IMAGE_FEATURES ??= ""
 IMAGE_FEATURES += "${EXTRA_IMAGE_FEATURES}"
 
-DISTRO_FEATURES_BACKFILL = "pulseaudio sysvinit bluez5"
-MACHINE_FEATURES_BACKFILL = "rtc"
+DISTRO_FEATURES_BACKFILL = "pulseaudio sysvinit bluez5 gobject-introspection-data"
+MACHINE_FEATURES_BACKFILL = "rtc gobject-introspection-data"
 
 COMBINED_FEATURES = "${@oe.utils.set_intersect('DISTRO_FEATURES', 'MACHINE_FEATURES', d)}"
 COMBINED_FEATURES[vardeps] += "DISTRO_FEATURES MACHINE_FEATURES"
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 23/24] machine/include/arch-x86: Make x32 ABI not supporting gobject-introspection-data
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (21 preceding siblings ...)
  2016-03-09 15:02 ` [PATCH 22/24] bitbake.conf: add 'gobject-introspection-data' to DISTRO/MACHINE_FEATURES_BACKFILL Alexander Kanavin
@ 2016-03-09 15:02 ` Alexander Kanavin
  2016-03-09 15:02 ` [PATCH 24/24] musl: disable building of gobject introspection data Alexander Kanavin
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:02 UTC (permalink / raw)
  To: openembedded-core

From: Richard Purdie <richard.purdie@linuxfoundation.org>

x32 isn't supported by user mode qemu so we can't build
gobject-introspection-data, so disable it in this case.

(From OE-Core rev: 4ee1eb8ddd3fbe144fbaeb32e07b66e191aa7548)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/conf/machine/include/x86/arch-x86.inc | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/meta/conf/machine/include/x86/arch-x86.inc b/meta/conf/machine/include/x86/arch-x86.inc
index 400da1a..ba7be8a 100644
--- a/meta/conf/machine/include/x86/arch-x86.inc
+++ b/meta/conf/machine/include/x86/arch-x86.inc
@@ -24,6 +24,8 @@ ABIEXTENSION .= "${@bb.utils.contains('TUNE_FEATURES', 'mx32', 'x32', '' ,d)}"
 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)}"
 
 # ELF64 ABI
 TUNEVALID[m64] = "IA32e (x86_64) ELF64 standard ABI"
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* [PATCH 24/24] musl: disable building of gobject introspection data
  2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
                   ` (22 preceding siblings ...)
  2016-03-09 15:02 ` [PATCH 23/24] machine/include/arch-x86: Make x32 ABI not supporting gobject-introspection-data Alexander Kanavin
@ 2016-03-09 15:02 ` Alexander Kanavin
  23 siblings, 0 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-09 15:02 UTC (permalink / raw)
  To: openembedded-core

When musl is in use, GLib binaries crash on assertion failures under qemu

Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
---
 meta/conf/distro/include/tclibc-musl.inc | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/meta/conf/distro/include/tclibc-musl.inc b/meta/conf/distro/include/tclibc-musl.inc
index 1ddd58e..e6b10f9 100644
--- a/meta/conf/distro/include/tclibc-musl.inc
+++ b/meta/conf/distro/include/tclibc-musl.inc
@@ -25,3 +25,7 @@ LIBC_DEPENDENCIES = "\
     musl-dbg \
     musl-dev \
     "
+
+# GLib binaries trigger assertion failures and crash under qemu
+# when musl is in use
+DISTRO_FEATURES_BACKFILL_CONSIDERED += "gobject-introspection-data"
-- 
2.7.0



^ permalink raw reply related	[flat|nested] 41+ messages in thread

* Re: [PATCH 06/24] gobject-introspection.bbclass: add a class that enables gobject introspection
  2016-03-09 15:01 ` [PATCH 06/24] gobject-introspection.bbclass: add a class that enables gobject introspection Alexander Kanavin
@ 2016-03-09 23:52   ` Andreas Oberritter
  2016-03-10  0:09     ` Martin Jansa
  0 siblings, 1 reply; 41+ messages in thread
From: Andreas Oberritter @ 2016-03-09 23:52 UTC (permalink / raw)
  To: openembedded-core

Hello Alexander,

On 09.03.2016 16:01, Alexander Kanavin wrote:
> Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
> ---
>  meta/classes/gobject-introspection.bbclass | 39 ++++++++++++++++++++++++++++++
>  1 file changed, 39 insertions(+)
>  create mode 100644 meta/classes/gobject-introspection.bbclass
> 
> diff --git a/meta/classes/gobject-introspection.bbclass b/meta/classes/gobject-introspection.bbclass
> new file mode 100644
> index 0000000..ef51629
> --- /dev/null
> +++ b/meta/classes/gobject-introspection.bbclass
> @@ -0,0 +1,39 @@
> +# Inherit this class in recipes to enable building their introspection files
> +
> +# This allows disabling introspection support in recipes
> +# (and therefore avoiding the use of qemu)
> +# if gobject-introspection-data is omitted from DISTRO_FEATURES and MACHINE_FEATURES.
> +EXTRA_OECONF_prepend = "${@bb.utils.contains('COMBINED_FEATURES', 'gobject-introspection-data', '--enable-introspection', '--disable-introspection', d)} "

testing only DISTRO_FEATURES would be better. If MACHINE_FEATURES gets
tested, even though indirectly, I'd expect every recipe inheriting this
class to switch to MACHINE_ARCH implicitly.

It's not a feature that depends on any type of hardware design.

Regards,
Andreas

> +
> +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
> +# failes if these are not set
> +export BUILD_SYS
> +export HOST_SYS
> +export STAGING_LIBDIR
> +export STAGING_INCDIR
> +
> +# 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"
> +
> 



^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 06/24] gobject-introspection.bbclass: add a class that enables gobject introspection
  2016-03-09 23:52   ` Andreas Oberritter
@ 2016-03-10  0:09     ` Martin Jansa
  2016-03-10  0:15       ` Richard Purdie
  0 siblings, 1 reply; 41+ messages in thread
From: Martin Jansa @ 2016-03-10  0:09 UTC (permalink / raw)
  To: Andreas Oberritter; +Cc: openembedded-core

[-- Attachment #1: Type: text/plain, Size: 3416 bytes --]

On Thu, Mar 10, 2016 at 12:52:20AM +0100, Andreas Oberritter wrote:
> Hello Alexander,
> 
> On 09.03.2016 16:01, Alexander Kanavin wrote:
> > Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
> > ---
> >  meta/classes/gobject-introspection.bbclass | 39 ++++++++++++++++++++++++++++++
> >  1 file changed, 39 insertions(+)
> >  create mode 100644 meta/classes/gobject-introspection.bbclass
> > 
> > diff --git a/meta/classes/gobject-introspection.bbclass b/meta/classes/gobject-introspection.bbclass
> > new file mode 100644
> > index 0000000..ef51629
> > --- /dev/null
> > +++ b/meta/classes/gobject-introspection.bbclass
> > @@ -0,0 +1,39 @@
> > +# Inherit this class in recipes to enable building their introspection files
> > +
> > +# This allows disabling introspection support in recipes
> > +# (and therefore avoiding the use of qemu)
> > +# if gobject-introspection-data is omitted from DISTRO_FEATURES and MACHINE_FEATURES.
> > +EXTRA_OECONF_prepend = "${@bb.utils.contains('COMBINED_FEATURES', 'gobject-introspection-data', '--enable-introspection', '--disable-introspection', d)} "
> 
> testing only DISTRO_FEATURES would be better. If MACHINE_FEATURES gets
> tested, even though indirectly, I'd expect every recipe inheriting this
> class to switch to MACHINE_ARCH implicitly.

I think the idea was to prevent using qemu for MACHINEs without support
in qemu. But I fully agree that causing all recipes which inherit this
bbclass effectively MACHINE_ARCH is even worse.

DISTRO needs to make sure that all supported MACHINEs have support in
qemu or disable introspection for all of them.

> It's not a feature that depends on any type of hardware design.


> 
> Regards,
> Andreas
> 
> > +
> > +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
> > +# failes if these are not set
> > +export BUILD_SYS
> > +export HOST_SYS
> > +export STAGING_LIBDIR
> > +export STAGING_INCDIR
> > +
> > +# 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"
> > +
> > 
> 
> -- 
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core

-- 
Martin 'JaMa' Jansa     jabber: Martin.Jansa@gmail.com

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 188 bytes --]

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 06/24] gobject-introspection.bbclass: add a class that enables gobject introspection
  2016-03-10  0:09     ` Martin Jansa
@ 2016-03-10  0:15       ` Richard Purdie
  2016-03-10  0:26         ` Andreas Oberritter
  2016-03-10  0:30         ` Martin Jansa
  0 siblings, 2 replies; 41+ messages in thread
From: Richard Purdie @ 2016-03-10  0:15 UTC (permalink / raw)
  To: Martin Jansa, Andreas Oberritter; +Cc: openembedded-core

On Thu, 2016-03-10 at 01:09 +0100, Martin Jansa wrote:
> On Thu, Mar 10, 2016 at 12:52:20AM +0100, Andreas Oberritter wrote:
> > Hello Alexander,
> > 
> > On 09.03.2016 16:01, Alexander Kanavin wrote:
> > > Signed-off-by: Alexander Kanavin <
> > > alexander.kanavin@linux.intel.com>
> > > ---
> > >  meta/classes/gobject-introspection.bbclass | 39
> > > ++++++++++++++++++++++++++++++
> > >  1 file changed, 39 insertions(+)
> > >  create mode 100644 meta/classes/gobject-introspection.bbclass
> > > 
> > > diff --git a/meta/classes/gobject-introspection.bbclass
> > > b/meta/classes/gobject-introspection.bbclass
> > > new file mode 100644
> > > index 0000000..ef51629
> > > --- /dev/null
> > > +++ b/meta/classes/gobject-introspection.bbclass
> > > @@ -0,0 +1,39 @@
> > > +# Inherit this class in recipes to enable building their
> > > introspection files
> > > +
> > > +# This allows disabling introspection support in recipes
> > > +# (and therefore avoiding the use of qemu)
> > > +# if gobject-introspection-data is omitted from DISTRO_FEATURES
> > > and MACHINE_FEATURES.
> > > +EXTRA_OECONF_prepend = "${@bb.utils.contains('COMBINED_FEATURES'
> > > , 'gobject-introspection-data', '--enable-introspection', '-
> > > -disable-introspection', d)} "
> > 
> > testing only DISTRO_FEATURES would be better. If MACHINE_FEATURES
> > gets
> > tested, even though indirectly, I'd expect every recipe inheriting
> > this
> > class to switch to MACHINE_ARCH implicitly.
> 
> I think the idea was to prevent using qemu for MACHINEs without
> support
> in qemu. But I fully agree that causing all recipes which inherit
> this
> bbclass effectively MACHINE_ARCH is even worse.
> 
> DISTRO needs to make sure that all supported MACHINEs have support in
> qemu or disable introspection for all of them.

Remember that bitbake has special knowledge of bb.utils.contains() and
is clever enough to make the checksums depend on "gobject-introspection
-data" being present or not and not the actual complete value.

So we can get the best of both worlds here, you can disable g-i on a
per machine basis yet still enable at the distro level. Recipes don't
become machine specific.

Cheers,

Richard



^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 06/24] gobject-introspection.bbclass: add a class that enables gobject introspection
  2016-03-10  0:15       ` Richard Purdie
@ 2016-03-10  0:26         ` Andreas Oberritter
  2016-03-10  0:28           ` Richard Purdie
  2016-03-10  0:30         ` Martin Jansa
  1 sibling, 1 reply; 41+ messages in thread
From: Andreas Oberritter @ 2016-03-10  0:26 UTC (permalink / raw)
  To: Richard Purdie, Martin Jansa; +Cc: openembedded-core

On 10.03.2016 01:15, Richard Purdie wrote:
> On Thu, 2016-03-10 at 01:09 +0100, Martin Jansa wrote:
>> On Thu, Mar 10, 2016 at 12:52:20AM +0100, Andreas Oberritter wrote:
>>> Hello Alexander,
>>>
>>> On 09.03.2016 16:01, Alexander Kanavin wrote:
>>>> Signed-off-by: Alexander Kanavin <
>>>> alexander.kanavin@linux.intel.com>
>>>> ---
>>>>  meta/classes/gobject-introspection.bbclass | 39
>>>> ++++++++++++++++++++++++++++++
>>>>  1 file changed, 39 insertions(+)
>>>>  create mode 100644 meta/classes/gobject-introspection.bbclass
>>>>
>>>> diff --git a/meta/classes/gobject-introspection.bbclass
>>>> b/meta/classes/gobject-introspection.bbclass
>>>> new file mode 100644
>>>> index 0000000..ef51629
>>>> --- /dev/null
>>>> +++ b/meta/classes/gobject-introspection.bbclass
>>>> @@ -0,0 +1,39 @@
>>>> +# Inherit this class in recipes to enable building their
>>>> introspection files
>>>> +
>>>> +# This allows disabling introspection support in recipes
>>>> +# (and therefore avoiding the use of qemu)
>>>> +# if gobject-introspection-data is omitted from DISTRO_FEATURES
>>>> and MACHINE_FEATURES.
>>>> +EXTRA_OECONF_prepend = "${@bb.utils.contains('COMBINED_FEATURES'
>>>> , 'gobject-introspection-data', '--enable-introspection', '-
>>>> -disable-introspection', d)} "
>>>
>>> testing only DISTRO_FEATURES would be better. If MACHINE_FEATURES
>>> gets
>>> tested, even though indirectly, I'd expect every recipe inheriting
>>> this
>>> class to switch to MACHINE_ARCH implicitly.
>>
>> I think the idea was to prevent using qemu for MACHINEs without
>> support
>> in qemu. But I fully agree that causing all recipes which inherit
>> this
>> bbclass effectively MACHINE_ARCH is even worse.
>>
>> DISTRO needs to make sure that all supported MACHINEs have support in
>> qemu or disable introspection for all of them.
> 
> Remember that bitbake has special knowledge of bb.utils.contains() and
> is clever enough to make the checksums depend on "gobject-introspection
> -data" being present or not and not the actual complete value.
> 
> So we can get the best of both worlds here, you can disable g-i on a
> per machine basis yet still enable at the distro level. Recipes don't
> become machine specific.

How does this work out on a shared package feed, of which some machines
have the required qemu support and others don't?

Regards,
Andreas


^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 06/24] gobject-introspection.bbclass: add a class that enables gobject introspection
  2016-03-10  0:26         ` Andreas Oberritter
@ 2016-03-10  0:28           ` Richard Purdie
  2016-03-10  1:38             ` Andreas Oberritter
  0 siblings, 1 reply; 41+ messages in thread
From: Richard Purdie @ 2016-03-10  0:28 UTC (permalink / raw)
  To: Andreas Oberritter, Martin Jansa; +Cc: openembedded-core

On Thu, 2016-03-10 at 01:26 +0100, Andreas Oberritter wrote:
> How does this work out on a shared package feed, of which some
> machines
> have the required qemu support and others don't?

Generally its done by "tune" rather than machine and we're dependent on
qemu's support of that architecture/tune, not machine. A given package
feed corresponds to a tune and that will either be supported by qemu or
not so I'd have thought it would all be consistent.

Cheers,

Richard


^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 06/24] gobject-introspection.bbclass: add a class that enables gobject introspection
  2016-03-10  0:15       ` Richard Purdie
  2016-03-10  0:26         ` Andreas Oberritter
@ 2016-03-10  0:30         ` Martin Jansa
  1 sibling, 0 replies; 41+ messages in thread
From: Martin Jansa @ 2016-03-10  0:30 UTC (permalink / raw)
  To: Richard Purdie; +Cc: openembedded-core

[-- Attachment #1: Type: text/plain, Size: 3261 bytes --]

On Thu, Mar 10, 2016 at 12:15:09AM +0000, Richard Purdie wrote:
> On Thu, 2016-03-10 at 01:09 +0100, Martin Jansa wrote:
> > On Thu, Mar 10, 2016 at 12:52:20AM +0100, Andreas Oberritter wrote:
> > > Hello Alexander,
> > > 
> > > On 09.03.2016 16:01, Alexander Kanavin wrote:
> > > > Signed-off-by: Alexander Kanavin <
> > > > alexander.kanavin@linux.intel.com>
> > > > ---
> > > >  meta/classes/gobject-introspection.bbclass | 39
> > > > ++++++++++++++++++++++++++++++
> > > >  1 file changed, 39 insertions(+)
> > > >  create mode 100644 meta/classes/gobject-introspection.bbclass
> > > > 
> > > > diff --git a/meta/classes/gobject-introspection.bbclass
> > > > b/meta/classes/gobject-introspection.bbclass
> > > > new file mode 100644
> > > > index 0000000..ef51629
> > > > --- /dev/null
> > > > +++ b/meta/classes/gobject-introspection.bbclass
> > > > @@ -0,0 +1,39 @@
> > > > +# Inherit this class in recipes to enable building their
> > > > introspection files
> > > > +
> > > > +# This allows disabling introspection support in recipes
> > > > +# (and therefore avoiding the use of qemu)
> > > > +# if gobject-introspection-data is omitted from DISTRO_FEATURES
> > > > and MACHINE_FEATURES.
> > > > +EXTRA_OECONF_prepend = "${@bb.utils.contains('COMBINED_FEATURES'
> > > > , 'gobject-introspection-data', '--enable-introspection', '-
> > > > -disable-introspection', d)} "
> > > 
> > > testing only DISTRO_FEATURES would be better. If MACHINE_FEATURES
]> > > gets
> > > tested, even though indirectly, I'd expect every recipe inheriting
> > > this
> > > class to switch to MACHINE_ARCH implicitly.
> > 
> > I think the idea was to prevent using qemu for MACHINEs without
> > support
> > in qemu. But I fully agree that causing all recipes which inherit
> > this
> > bbclass effectively MACHINE_ARCH is even worse.
> > 
> > DISTRO needs to make sure that all supported MACHINEs have support in
> > qemu or disable introspection for all of them.
> 
> Remember that bitbake has special knowledge of bb.utils.contains() and
> is clever enough to make the checksums depend on "gobject-introspection
> -data" being present or not and not the actual complete value.

But then the same TUNE_PKGARCH package created for 2 MACHINEs where one
has gobject-introspection-data in MACHINE_FEATURES and the second has
not, will still use different EXTRA_OECONF value.

So it will be overwriting the same package in same architecture with and
without introspection enabled, because on which MACHINE was built last.
Which is even worse than admitting that this is fscked combination and
turning such recipe and all depending on it to MACHINE_ARCH so that it
at leasts keeps the introspection enabled or disabled consistently.

On the other hand we can expect that if the DEFAULTTUNE has support in
qemu for MACHINE1, then MACHINE2 should be supported as well and this
combination is probably just overlook when setting MACHINE_FEATURES.

> So we can get the best of both worlds here, you can disable g-i on a
> per machine basis yet still enable at the distro level. Recipes don't
> become machine specific.
> 
> Cheers,
> 
> Richard
> 

-- 
Martin 'JaMa' Jansa     jabber: Martin.Jansa@gmail.com

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 188 bytes --]

^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 06/24] gobject-introspection.bbclass: add a class that enables gobject introspection
  2016-03-10  0:28           ` Richard Purdie
@ 2016-03-10  1:38             ` Andreas Oberritter
  0 siblings, 0 replies; 41+ messages in thread
From: Andreas Oberritter @ 2016-03-10  1:38 UTC (permalink / raw)
  To: Richard Purdie, Martin Jansa; +Cc: openembedded-core

On 10.03.2016 01:28, Richard Purdie wrote:
> On Thu, 2016-03-10 at 01:26 +0100, Andreas Oberritter wrote:
>> How does this work out on a shared package feed, of which some
>> machines
>> have the required qemu support and others don't?
> 
> Generally its done by "tune" rather than machine and we're dependent on
> qemu's support of that architecture/tune, not machine. A given package
> feed corresponds to a tune and that will either be supported by qemu or
> not so I'd have thought it would all be consistent.

Right. I hadn't thought about that.

I guess a less confusing implementation should encode the knowledge
about the necessary qemu support into conf/machine/include/tune-*.inc
then (using a different variable), so all builds get consistent settings
automatically.

Regards,
Andreas



^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 02/24] python3-native: use the previous version of python-config script
  2016-03-09 15:01 ` [PATCH 02/24] python3-native: use the previous version of python-config script Alexander Kanavin
@ 2016-03-10 21:24   ` Andreas Müller
  2016-03-15 15:59     ` Alexander Kanavin
  0 siblings, 1 reply; 41+ messages in thread
From: Andreas Müller @ 2016-03-10 21:24 UTC (permalink / raw)
  To: Alexander Kanavin; +Cc: Patches and discussions about the oe-core layer

On Wed, Mar 9, 2016 at 4:01 PM, Alexander Kanavin
<alexander.kanavin@linux.intel.com> wrote:
> In python 3.4 python-config was rewritten in shell, ironically
> to support cross-compilation:
> https://bugs.python.org/issue16235
>
> This new shell version is broken in several ways, and doesn't
> have our oe-specific tweaks. Let's revert to the old script,
> which is still provided.
>
> Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
> ---
>  .../python/python3-native_3.5.1.bb                 |  1 +
>  ...the-shell-version-of-python-config-that-w.patch | 38 ++++++++++++++++++++++
>  2 files changed, 39 insertions(+)
>  create mode 100644 meta/recipes-devtools/python/python3/0001-Do-not-use-the-shell-version-of-python-config-that-w.patch
>
> diff --git a/meta/recipes-devtools/python/python3-native_3.5.1.bb b/meta/recipes-devtools/python/python3-native_3.5.1.bb
> index 152da1c..7bad11a 100644
> --- a/meta/recipes-devtools/python/python3-native_3.5.1.bb
> +++ b/meta/recipes-devtools/python/python3-native_3.5.1.bb
> @@ -25,6 +25,7 @@ file://unixccompiler.patch \
>  ${DISTRO_SRC_URI} \
>  file://sysconfig.py-add-_PYTHON_PROJECT_SRC.patch \
>  file://setup.py-check-cross_compiling-when-get-FLAGS.patch \
> +file://0001-Do-not-use-the-shell-version-of-python-config-that-w.patch \
>  "
>  SRC_URI[md5sum] = "e9ea6f2623fffcdd871b7b19113fde80"
>  SRC_URI[sha256sum] = "c6d57c0c366d9060ab6c0cdf889ebf3d92711d466cc0119c441dbf2746f725c9"
> diff --git a/meta/recipes-devtools/python/python3/0001-Do-not-use-the-shell-version-of-python-config-that-w.patch b/meta/recipes-devtools/python/python3/0001-Do-not-use-the-shell-version-of-python-config-that-w.patch
> new file mode 100644
> index 0000000..b7e0ac6
> --- /dev/null
> +++ b/meta/recipes-devtools/python/python3/0001-Do-not-use-the-shell-version-of-python-config-that-w.patch
> @@ -0,0 +1,38 @@
> +From 045c99b5f1eb6e4e0d8ad1ef9f0ba6574f738150 Mon Sep 17 00:00:00 2001
> +From: Alexander Kanavin <alex.kanavin@gmail.com>
> +Date: Fri, 23 Oct 2015 12:25:09 +0300
> +Subject: [PATCH] Do not use the shell version of python-config that was
> + introduced in 3.4
> +
> +Revert instead to the original python version: it has our tweaks and
> +outputs directories correctly.
> +
> +Upstream-Status: Inappropriate [oe-specific]
> +Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
> +---
> + Makefile.pre.in | 9 +++------
> + 1 file changed, 3 insertions(+), 6 deletions(-)
> +
> +diff --git a/Makefile.pre.in b/Makefile.pre.in
> +index d7fc9a0..47e60bc 100644
> +--- a/Makefile.pre.in
> ++++ b/Makefile.pre.in
> +@@ -1270,12 +1270,9 @@ python-config: $(srcdir)/Misc/python-config.in Misc/python-config.sh
> +       sed -e "s,@EXENAME@,$(BINDIR)/python$(LDVERSION)$(EXE)," < $(srcdir)/Misc/python-config.in >python-config.py
> +       # Replace makefile compat. variable references with shell script compat. ones; $(VAR) -> ${VAR}
> +       sed -e 's,\$$(\([A-Za-z0-9_]*\)),\$$\{\1\},g' < Misc/python-config.sh >python-config
> +-      # On Darwin, always use the python version of the script, the shell
> +-      # version doesn't use the compiler customizations that are provided
> +-      # in python (_osx_support.py).
> +-      if test `uname -s` = Darwin; then \
> +-              cp python-config.py python-config; \
> +-      fi
> ++      # In OpenEmbedded, always use the python version of the script, the shell
> ++      # version is broken in multiple ways, and doesn't return correct directories
> ++      cp python-config.py python-config
> +
> +
> + # Install the include files
> +--
> +2.1.4
> +
> --
> 2.7.0
>
This one seems to report host's python3 version:

[superandy@localhost sysroots]$
x86_64-linux/usr/bin/python3-native/python3-config --ldflags
-lpython3.4m -lpthread -ldl -lutil -lm -Xlinker -export-dynamic

We are at 3.5

Andreas


^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 02/24] python3-native: use the previous version of python-config script
  2016-03-10 21:24   ` Andreas Müller
@ 2016-03-15 15:59     ` Alexander Kanavin
  2016-03-15 16:40       ` Andreas Müller
  2016-03-15 19:23       ` Khem Raj
  0 siblings, 2 replies; 41+ messages in thread
From: Alexander Kanavin @ 2016-03-15 15:59 UTC (permalink / raw)
  To: Andreas Müller; +Cc: Patches and discussions about the oe-core layer

On 03/10/2016 11:24 PM, Andreas Müller wrote:

> This one seems to report host's python3 version:
>
> [superandy@localhost sysroots]$
> x86_64-linux/usr/bin/python3-native/python3-config --ldflags
> -lpython3.4m -lpthread -ldl -lutil -lm -Xlinker -export-dynamic
>
> We are at 3.5

This is because python3-config does not contain the version within 
itself, it reports the version of the python interpreter that it is run 
with. So NOTABUG.


Alex



^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 02/24] python3-native: use the previous version of python-config script
  2016-03-15 15:59     ` Alexander Kanavin
@ 2016-03-15 16:40       ` Andreas Müller
  2016-03-15 19:23       ` Khem Raj
  1 sibling, 0 replies; 41+ messages in thread
From: Andreas Müller @ 2016-03-15 16:40 UTC (permalink / raw)
  To: Alexander Kanavin; +Cc: Patches and discussions about the oe-core layer

On Tue, Mar 15, 2016 at 4:59 PM, Alexander Kanavin
<alexander.kanavin@linux.intel.com> wrote:
> On 03/10/2016 11:24 PM, Andreas Müller wrote:
>
>> This one seems to report host's python3 version:
>>
>> [superandy@localhost sysroots]$
>> x86_64-linux/usr/bin/python3-native/python3-config --ldflags
>> -lpython3.4m -lpthread -ldl -lutil -lm -Xlinker -export-dynamic
>>
>> We are at 3.5
>
>
> This is because python3-config does not contain the version within itself,
> it reports the version of the python interpreter that it is run with. So
> NOTABUG.
I am tired of your way of dealing things but leave in total disagreement

Andreas


^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 02/24] python3-native: use the previous version of python-config script
  2016-03-15 15:59     ` Alexander Kanavin
  2016-03-15 16:40       ` Andreas Müller
@ 2016-03-15 19:23       ` Khem Raj
  2016-03-15 22:29         ` alexander.kanavin
  1 sibling, 1 reply; 41+ messages in thread
From: Khem Raj @ 2016-03-15 19:23 UTC (permalink / raw)
  To: Alexander Kanavin; +Cc: Patches and discussions about the oe-core layer

On Tue, Mar 15, 2016 at 8:59 AM, Alexander Kanavin
<alexander.kanavin@linux.intel.com> wrote:
> On 03/10/2016 11:24 PM, Andreas Müller wrote:
>
>> This one seems to report host's python3 version:
>>
>> [superandy@localhost sysroots]$
>> x86_64-linux/usr/bin/python3-native/python3-config --ldflags
>> -lpython3.4m -lpthread -ldl -lutil -lm -Xlinker -export-dynamic
>>
>> We are at 3.5
>
>
> This is because python3-config does not contain the version within itself,
> it reports the version of the python interpreter that it is run with. So
> NOTABUG.

If its supposed to report the version of python pack its coming with
and not the interpreter its run with
then how do you decide its not a behavior change ?
Lets keep the semantics as they were. I am perfectly fine to revert to
python 3.4 if thats what it takes.


^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 02/24] python3-native: use the previous version of python-config script
  2016-03-15 19:23       ` Khem Raj
@ 2016-03-15 22:29         ` alexander.kanavin
  2016-03-15 22:37           ` Andreas Müller
  0 siblings, 1 reply; 41+ messages in thread
From: alexander.kanavin @ 2016-03-15 22:29 UTC (permalink / raw)
  To: Khem Raj; +Cc: Patches and discussions about the oe-core layer

>> This is because python3-config does not contain the version within
>> itself,
>> it reports the version of the python interpreter that it is run with. So
>> NOTABUG.
>
> If its supposed to report the version of python pack its coming with
> and not the interpreter its run with
> then how do you decide its not a behavior change ?

Apologies for being terse. I should've explained that when building
recipes that make use of this script, it will be run with the native
python (instead of host python) because native python will come first in
the PATH, and so the version reported will be correct, because native
python will match target python. This is set up in pythonnative.bbclass
for python 2, and in python3native.bbclass for python 3.

> Lets keep the semantics as they were. I am perfectly fine to revert to
> python 3.4 if thats what it takes.

We *are* keeping semantics as they were with this patch. Python 3.4
defaults to this script, python 3.5 changes python-config to the broken
shell-based rewrite. This patch reverts back to the 3.4 behaviour.


Alex


^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 02/24] python3-native: use the previous version of python-config script
  2016-03-15 22:29         ` alexander.kanavin
@ 2016-03-15 22:37           ` Andreas Müller
  2016-03-16 16:23             ` alexander.kanavin
  0 siblings, 1 reply; 41+ messages in thread
From: Andreas Müller @ 2016-03-15 22:37 UTC (permalink / raw)
  To: Alexander Kanavin; +Cc: Patches and discussions about the oe-core layer

On Tue, Mar 15, 2016 at 11:29 PM,  <alexander.kanavin@linux.intel.com> wrote:
>>> This is because python3-config does not contain the version within
>>> itself,
>>> it reports the version of the python interpreter that it is run with. So
>>> NOTABUG.
>>
>> If its supposed to report the version of python pack its coming with
>> and not the interpreter its run with
>> then how do you decide its not a behavior change ?
>
> Apologies for being terse. I should've explained that when building
> recipes that make use of this script, it will be run with the native
> python (instead of host python) because native python will come first in
> the PATH, and so the version reported will be correct, because native
> python will match target python. This is set up in pythonnative.bbclass
> for python 2, and in python3native.bbclass for python 3.
Sorry but I don't get it: The script reports the version of host's
python which might be different from what we are building native and
cross. When something is trying to link against python libs and is
using this script this crashes for host's with python < 3.5. This is a
bug. It should be either corrected or using of pkg-config should be
enforced if possible.

By the way: What was wrong with the shell script exactly? We have used
it for long time and it reported the correct version.

Andreas


^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 02/24] python3-native: use the previous version of python-config script
  2016-03-15 22:37           ` Andreas Müller
@ 2016-03-16 16:23             ` alexander.kanavin
  2016-03-16 21:28               ` Andreas Müller
  0 siblings, 1 reply; 41+ messages in thread
From: alexander.kanavin @ 2016-03-16 16:23 UTC (permalink / raw)
  To: Andreas Müller; +Cc: Patches and discussions about the oe-core layer

>> Apologies for being terse. I should've explained that when building
>> recipes that make use of this script, it will be run with the native
>> python (instead of host python) because native python will come first in
>> the PATH, and so the version reported will be correct, because native
>> python will match target python. This is set up in pythonnative.bbclass
>> for python 2, and in python3native.bbclass for python 3.
> Sorry but I don't get it: The script reports the version of host's
> python which might be different from what we are building native and
> cross. When something is trying to link against python libs and is
> using this script this crashes for host's with python < 3.5. This is a
> bug. It should be either corrected or using of pkg-config should be
> enforced if possible.

The script reports the version of the host python, because you are running
it with the host python. If you run it with the native python, it will
report version of the native python. All recipes that need to execute
python code as a part of their build are doing that, and therefore are
getting the correct version. Where is the bug here? Can you demonstrate
it? (by something else than running the script using host python,
obviously)

I agree that we should generally get rid of such custom,
separately-maintained configuration scripts and migrate everything to
pkgconfig, but that is a separate issue.

> By the way: What was wrong with the shell script exactly? We have used
> it for long time and it reported the correct version.

The shell script was introduced with Python 3.4. All previous versions of
python, including python 2.x, are using a different, python-based version
of the script, to which we do some patching so that it reports things
correctly in our cross-compilation environment. [1]

The problem with the shell script is that it lacks those tweaks, and
things break down when you try to build python3-based software with it.
Specifically, I ran into issues building pygobject 3.x, and after trying
to fix the shell script, I gave up and reverted to tried and tested
python-based version - which is what this patch does. I believe the
problem wasn't noticed earlier, because prior to pygobject 3.x there was
no other python3-based software using python-config.

Now you need to be exact: where and how did you use the shell script for a
long time? Why should oe-core start using it, if it's known to be broken
and requires patching?

Alex

[1]
http://git.yoctoproject.org/cgit/cgit.cgi/poky/tree/meta/recipes-devtools/python/python3/python-config.patch



^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 02/24] python3-native: use the previous version of python-config script
  2016-03-16 16:23             ` alexander.kanavin
@ 2016-03-16 21:28               ` Andreas Müller
  2016-03-18 19:29                 ` alexander.kanavin
  0 siblings, 1 reply; 41+ messages in thread
From: Andreas Müller @ 2016-03-16 21:28 UTC (permalink / raw)
  To: Alexander Kanavin; +Cc: Patches and discussions about the oe-core layer

On Wed, Mar 16, 2016 at 5:23 PM,  <alexander.kanavin@linux.intel.com> wrote:
>>> Apologies for being terse. I should've explained that when building
>>> recipes that make use of this script, it will be run with the native
>>> python (instead of host python) because native python will come first in
>>> the PATH, and so the version reported will be correct, because native
>>> python will match target python. This is set up in pythonnative.bbclass
>>> for python 2, and in python3native.bbclass for python 3.
>> Sorry but I don't get it: The script reports the version of host's
>> python which might be different from what we are building native and
>> cross. When something is trying to link against python libs and is
>> using this script this crashes for host's with python < 3.5. This is a
>> bug. It should be either corrected or using of pkg-config should be
>> enforced if possible.
>
> The script reports the version of the host python, because you are running
> it with the host python. If you run it with the native python, it will
> report version of the native python. All recipes that need to execute
> python code as a part of their build are doing that, and therefore are
> getting the correct version.
This was the missing bit for me. Seems for some reason (qmake-native?
- see below) my recipe is running host's python.
> Where is the bug here? Can you demonstrate
> it? (by something else than running the script using host python,
> obviously)
>
> I agree that we should generally get rid of such custom,
> separately-maintained configuration scripts and migrate everything to
> pkgconfig, but that is a separate issue.
>
>> By the way: What was wrong with the shell script exactly? We have used
>> it for long time and it reported the correct version.
>
> The shell script was introduced with Python 3.4. All previous versions of
> python, including python 2.x, are using a different, python-based version
> of the script, to which we do some patching so that it reports things
> correctly in our cross-compilation environment. [1]
>
> The problem with the shell script is that it lacks those tweaks, and
> things break down when you try to build python3-based software with it.
> Specifically, I ran into issues building pygobject 3.x, and after trying
> to fix the shell script, I gave up and reverted to tried and tested
> python-based version - which is what this patch does. I believe the
> problem wasn't noticed earlier, because prior to pygobject 3.x there was
> no other python3-based software using python-config.
>
> Now you need to be exact: where and how did you use the shell script for a
> long time? Why should oe-core start using it, if it's known to be broken
> and requires patching?
>
Ok 'long time' was an assumption I have to regret but [1] first failed
when I updated 3.4 -> 3.5 (due to hard coded version in qmake pri -
file) and then failed again after updating to pythonic python3-config.
I know the fix I chose then is bad hack, but I tried to backport an
upstream solution and that failed for reasons we discuss here: linking
python3.4m which does not exist.

Thanks for explanation and sorry for shouting out - I'll rework that
recipe to use pkg-config as it is interested in version of python's
libraries - not the interpreter scripts are running on.

[1] https://github.com/schnitzeltony/meta-qt5-extra/blob/master/recipes-misc/recipes-cad/antimony/antimony_0.9.0c.bb

Andreas


^ permalink raw reply	[flat|nested] 41+ messages in thread

* Re: [PATCH 02/24] python3-native: use the previous version of python-config script
  2016-03-16 21:28               ` Andreas Müller
@ 2016-03-18 19:29                 ` alexander.kanavin
  0 siblings, 0 replies; 41+ messages in thread
From: alexander.kanavin @ 2016-03-18 19:29 UTC (permalink / raw)
  To: Andreas Müller; +Cc: Patches and discussions about the oe-core layer

> Thanks for explanation and sorry for shouting out - I'll rework that
> recipe to use pkg-config as it is interested in version of python's
> libraries - not the interpreter scripts are running on.

You're welcome. Changing to use pkg-config is really the best way out -
the python-config stuff and support for python runtimes in general in
oe-core is a very old pile of kludges that nobody understands very well.
We have an open issue to refactor/tidy it up:
https://bugzilla.yoctoproject.org/show_bug.cgi?id=9212

Alex


^ permalink raw reply	[flat|nested] 41+ messages in thread

end of thread, other threads:[~2016-03-18 18:42 UTC | newest]

Thread overview: 41+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-03-09 15:01 [PATCH 00/24] Add gobject introspection support to oe-core Alexander Kanavin
2016-03-09 15:01 ` [PATCH 01/24] qemu.bbclass: add qemu_wrapper_cmdline() Alexander Kanavin
2016-03-09 15:01 ` [PATCH 02/24] python3-native: use the previous version of python-config script Alexander Kanavin
2016-03-10 21:24   ` Andreas Müller
2016-03-15 15:59     ` Alexander Kanavin
2016-03-15 16:40       ` Andreas Müller
2016-03-15 19:23       ` Khem Raj
2016-03-15 22:29         ` alexander.kanavin
2016-03-15 22:37           ` Andreas Müller
2016-03-16 16:23             ` alexander.kanavin
2016-03-16 21:28               ` Andreas Müller
2016-03-18 19:29                 ` alexander.kanavin
2016-03-09 15:01 ` [PATCH 03/24] python3: fix patching get_python_lib() in distutils/sysconfig.py Alexander Kanavin
2016-03-09 15:01 ` [PATCH 04/24] gobject-introspection: add the recipe Alexander Kanavin
2016-03-09 15:01 ` [PATCH 05/24] gtk-doc-stub: remove introspection stubs Alexander Kanavin
2016-03-09 15:01 ` [PATCH 06/24] gobject-introspection.bbclass: add a class that enables gobject introspection Alexander Kanavin
2016-03-09 23:52   ` Andreas Oberritter
2016-03-10  0:09     ` Martin Jansa
2016-03-10  0:15       ` Richard Purdie
2016-03-10  0:26         ` Andreas Oberritter
2016-03-10  0:28           ` Richard Purdie
2016-03-10  1:38             ` Andreas Oberritter
2016-03-10  0:30         ` Martin Jansa
2016-03-09 15:01 ` [PATCH 07/24] vala: enable the use of vapigen by packages with vala support Alexander Kanavin
2016-03-09 15:01 ` [PATCH 08/24] vala.bbclass: remove pre-packaged vapigen.m4 from tarballs Alexander Kanavin
2016-03-09 15:01 ` [PATCH 09/24] avahi-ui: remove the dependency on python-pygtk by disabling avahi-discover Alexander Kanavin
2016-03-09 15:01 ` [PATCH 10/24] python-pygtk: remove the recipe Alexander Kanavin
2016-03-09 15:01 ` [PATCH 11/24] avahi: enable gobject-introspection Alexander Kanavin
2016-03-09 15:01 ` [PATCH 12/24] gtk+: enable gobject introspection Alexander Kanavin
2016-03-09 15:01 ` [PATCH 13/24] gtk+3: enable gobject-introspection Alexander Kanavin
2016-03-09 15:02 ` [PATCH 14/24] clutter: enable gobject introspection Alexander Kanavin
2016-03-09 15:02 ` [PATCH 15/24] libsoup-2.4: " Alexander Kanavin
2016-03-09 15:02 ` [PATCH 16/24] gstreamer: " Alexander Kanavin
2016-03-09 15:02 ` [PATCH 17/24] gnomebase.bbclass: do not disable " Alexander Kanavin
2016-03-09 15:02 ` [PATCH 18/24] python-pygobject: update to 3.18.2 Alexander Kanavin
2016-03-09 15:02 ` [PATCH 19/24] recipes-gnome: fix introspection support Alexander Kanavin
2016-03-09 15:02 ` [PATCH 20/24] webkitgtk: enable gobject introspection Alexander Kanavin
2016-03-09 15:02 ` [PATCH 21/24] packagegroup-core-x11-sato: add python-pygobject and gtk+3 Alexander Kanavin
2016-03-09 15:02 ` [PATCH 22/24] bitbake.conf: add 'gobject-introspection-data' to DISTRO/MACHINE_FEATURES_BACKFILL Alexander Kanavin
2016-03-09 15:02 ` [PATCH 23/24] machine/include/arch-x86: Make x32 ABI not supporting gobject-introspection-data Alexander Kanavin
2016-03-09 15:02 ` [PATCH 24/24] musl: disable building of gobject introspection data Alexander Kanavin

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.