summaryrefslogtreecommitdiffstats
path: root/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-use-binary-wrapper-option.patch
diff options
context:
space:
mode:
authorAlexander Kanavin <alexander.kanavin@linux.intel.com>2016-06-03 12:14:52 +0300
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-06-04 14:13:34 +0100
commit2a16d50a8effab62b5121ef0e0392e355224ef76 (patch)
tree340a6f54b67d9e8f4f7b4745d50da8a5dec49537 /meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-use-binary-wrapper-option.patch
parent3b85abf8bd1f9823dd8710a7170936ad588b588f (diff)
downloadpoky-2a16d50a8effab62b5121ef0e0392e355224ef76.tar.gz
gobject-introspection: update to 1.48.0
Add a patch that reverts an incomplete upstream attempt at cross-compile support; upstream has been notified: https://bugzilla.gnome.org/show_bug.cgi?id=696773 (From OE-Core rev: 7070c02c4878f479ae7002184c56b44bc408fb26) Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-use-binary-wrapper-option.patch')
-rw-r--r--meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-use-binary-wrapper-option.patch52
1 files changed, 0 insertions, 52 deletions
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
deleted file mode 100644
index e1241a9499..0000000000
--- a/meta/recipes-gnome/gobject-introspection/gobject-introspection/0001-giscanner-add-use-binary-wrapper-option.patch
+++ /dev/null
@@ -1,52 +0,0 @@
1From 2322f36056265f809aaffb74fcf5ac0c83129752 Mon Sep 17 00:00:00 2001
2From: Alexander Kanavin <alex.kanavin@gmail.com>
3Date: Mon, 19 Oct 2015 18:26:40 +0300
4Subject: [PATCH 2/4] giscanner: add --use-binary-wrapper option
5
6With this option, giscanner will use a wrapper executable to run
7binaries it's producing, instead of running them directly. This
8is useful when binaries are cross-compiled and cannot be run directly,
9but they can be run using for example QEMU emulation.
10
11Upstream-Status: Pending [review on oe-core list]
12Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
13
14---
15 giscanner/scannermain.py | 14 ++++++++++++++
16 1 file changed, 14 insertions(+)
17
18diff --git a/giscanner/scannermain.py b/giscanner/scannermain.py
19index b36284d..e37d3e3 100755
20--- a/giscanner/scannermain.py
21+++ b/giscanner/scannermain.py
22@@ -118,6 +118,9 @@ def _get_option_parser():
23 parser.add_option("", "--program",
24 action="store", dest="program", default=None,
25 help="program to execute")
26+ parser.add_option("", "--use-binary-wrapper",
27+ action="store", dest="wrapper", default=None,
28+ help="wrapper to use for running programs (useful when cross-compiling)")
29 parser.add_option("", "--program-arg",
30 action="append", dest="program_args", default=[],
31 help="extra arguments to program")
32@@ -406,6 +409,17 @@ def create_binary(transformer, options, args):
33 gdump_parser.get_error_quark_functions())
34
35 shlibs = resolve_shlibs(options, binary, options.libraries)
36+ if options.wrapper:
37+ # The wrapper needs the binary itself, not the libtool wrapper script,
38+ # so we check if libtool has sneaked the binary into .libs subdirectory
39+ # and adjust the path accordingly
40+ import os.path
41+ dir_name, binary_name = os.path.split(binary.args[0])
42+ libtool_binary = os.path.join(dir_name, '.libs', binary_name)
43+ if os.path.exists(libtool_binary):
44+ binary.args[0] = libtool_binary
45+ # Then prepend the wrapper to the command line to execute
46+ binary.args = [options.wrapper] + binary.args
47 gdump_parser.set_introspection_binary(binary)
48 gdump_parser.parse()
49 return shlibs
50--
512.1.4
52