summaryrefslogtreecommitdiffstats
path: root/meta/recipes-gnome/gobject-introspection
diff options
context:
space:
mode:
authorAndre McCurdy <armccurdy@gmail.com>2018-07-06 13:54:55 -0700
committerRichard Purdie <richard.purdie@linuxfoundation.org>2018-07-09 22:48:39 +0100
commitcfd0c39fbf611ed428c0fe8dc39bd61081ff664e (patch)
tree9e25a75b3deb91168b5c09060fec74211b075df6 /meta/recipes-gnome/gobject-introspection
parent5f033859e2f538c80106fc8c2bda4ca0a7bc336b (diff)
downloadpoky-cfd0c39fbf611ed428c0fe8dc39bd61081ff664e.tar.gz
gobject-introspection: minor recipe formatting tweaks
Re-order variables to align more closely to the OE style-guide. (From OE-Core rev: 5c9c61250bb23fd5fd1c18e243cab0d80573b749) Signed-off-by: Andre McCurdy <armccurdy@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-gnome/gobject-introspection')
-rw-r--r--meta/recipes-gnome/gobject-introspection/gobject-introspection_1.56.1.bb97
1 files changed, 50 insertions, 47 deletions
diff --git a/meta/recipes-gnome/gobject-introspection/gobject-introspection_1.56.1.bb b/meta/recipes-gnome/gobject-introspection/gobject-introspection_1.56.1.bb
index 96e0d6cb08..f3479565ea 100644
--- a/meta/recipes-gnome/gobject-introspection/gobject-introspection_1.56.1.bb
+++ b/meta/recipes-gnome/gobject-introspection/gobject-introspection_1.56.1.bb
@@ -17,17 +17,13 @@ SRC_URI = "${GNOME_MIRROR}/${BPN}/${@oe.utils.trim_version("${PV}", 2)}/${BPN}-$
17 file://0005-Prefix-pkg-config-paths-with-PKG_CONFIG_SYSROOT_DIR-.patch \ 17 file://0005-Prefix-pkg-config-paths-with-PKG_CONFIG_SYSROOT_DIR-.patch \
18 file://0001-giscanner-add-a-lib-dirs-envvar-option.patch \ 18 file://0001-giscanner-add-a-lib-dirs-envvar-option.patch \
19 " 19 "
20
20SRC_URI[md5sum] = "62e5f5685b8d9752fdeaf17c057d53d1" 21SRC_URI[md5sum] = "62e5f5685b8d9752fdeaf17c057d53d1"
21SRC_URI[sha256sum] = "5b2875ccff99ff7baab63a34b67f8c920def240e178ff50add809e267d9ea24b" 22SRC_URI[sha256sum] = "5b2875ccff99ff7baab63a34b67f8c920def240e178ff50add809e267d9ea24b"
22 23
23SRC_URI_append_class-native = " file://0001-Relocate-the-repository-directory-for-native-builds.patch " 24SRC_URI_append_class-native = " file://0001-Relocate-the-repository-directory-for-native-builds.patch"
24 25
25inherit autotools pkgconfig gtk-doc python3native qemu gobject-introspection-data upstream-version-is-even 26inherit autotools pkgconfig gtk-doc python3native qemu gobject-introspection-data upstream-version-is-even
26BBCLASSEXTEND = "native"
27
28# needed for writing out the qemu wrapper script
29export STAGING_DIR_HOST
30export B
31 27
32DEPENDS_append = " libffi zlib glib-2.0 python3 flex-native bison-native" 28DEPENDS_append = " libffi zlib glib-2.0 python3 flex-native bison-native"
33 29
@@ -38,7 +34,29 @@ DEPENDS_append = " libffi zlib glib-2.0 python3 flex-native bison-native"
38# (standard ldd doesn't work when cross-compiling). 34# (standard ldd doesn't work when cross-compiling).
39DEPENDS_class-target_append = " gobject-introspection-native qemu-native prelink-native" 35DEPENDS_class-target_append = " gobject-introspection-native qemu-native prelink-native"
40 36
41SSTATE_SCAN_FILES += "g-ir-scanner-qemuwrapper g-ir-scanner-wrapper g-ir-compiler-wrapper g-ir-scanner-lddwrapper Gio-2.0.gir postinst-ldsoconf-${PN}" 37# needed for writing out the qemu wrapper script
38export STAGING_DIR_HOST
39export B
40
41PACKAGECONFIG ?= ""
42PACKAGECONFIG[doctool] = "--enable-doctool,--disable-doctool,python3-mako,"
43
44# Configure target build to use native tools of itself and to use a qemu wrapper
45# and optionally to generate introspection data
46EXTRA_OECONF_class-target = " \
47 --disable-static \
48 --enable-host-gi \
49 --enable-gi-cross-wrapper=${B}/g-ir-scanner-qemuwrapper \
50 --enable-gi-ldd-wrapper=${B}/g-ir-scanner-lddwrapper \
51 ${@bb.utils.contains('GI_DATA_ENABLED', 'True', '--enable-introspection-data', '--disable-introspection-data', d)} \
52"
53
54# Need to ensure ld.so.conf exists so prelink-native works
55# both before we build and if we install from sstate
56do_configure[prefuncs] += "gobject_introspection_preconfigure"
57python gobject_introspection_preconfigure () {
58 oe.utils.write_ld_so_conf(d)
59}
42 60
43do_configure_prepend_class-native() { 61do_configure_prepend_class-native() {
44 # Tweak the native python scripts so that they don't refer to the 62 # Tweak the native python scripts so that they don't refer to the
@@ -100,18 +118,6 @@ EOF
100 sed -i -e '1s,#!.*,#!${USRBINPATH}/env python3,' ${S}/tools/g-ir-tool-template.in 118 sed -i -e '1s,#!.*,#!${USRBINPATH}/env python3,' ${S}/tools/g-ir-tool-template.in
101} 119}
102 120
103# Configure target build to use native tools of itself and to use a qemu wrapper
104# and optionally to generate introspection data
105EXTRA_OECONF_class-target = "--enable-host-gi \
106 --disable-static \
107 --enable-gi-cross-wrapper=${B}/g-ir-scanner-qemuwrapper \
108 --enable-gi-ldd-wrapper=${B}/g-ir-scanner-lddwrapper \
109 ${@bb.utils.contains('GI_DATA_ENABLED', 'True', '--enable-introspection-data', '--disable-introspection-data', d)} \
110 "
111
112PACKAGECONFIG ?= ""
113PACKAGECONFIG[doctool] = "--enable-doctool,--disable-doctool,python3-mako,"
114
115do_compile_prepend() { 121do_compile_prepend() {
116 # This prevents g-ir-scanner from writing cache data to $HOME 122 # This prevents g-ir-scanner from writing cache data to $HOME
117 export GI_SCANNER_DISABLE_CACHE=1 123 export GI_SCANNER_DISABLE_CACHE=1
@@ -130,27 +136,6 @@ do_install_append_class-target() {
130 install ${B}/g-ir-scanner-lddwrapper ${D}${bindir}/ 136 install ${B}/g-ir-scanner-lddwrapper ${D}${bindir}/
131} 137}
132 138
133# .typelib files are needed at runtime and so they go to the main package
134FILES_${PN}_append = " ${libdir}/girepository-*/*.typelib"
135
136# .gir files go to dev package, as they're needed for developing (but not for running)
137# things that depends on introspection.
138FILES_${PN}-dev_append = " ${datadir}/gir-*/*.gir"
139FILES_${PN}-dev_append = " ${datadir}/gir-*/*.rnc"
140
141# These are used by gobject-based packages
142# to generate transient introspection binaries
143FILES_${PN}-dev_append = " ${datadir}/gobject-introspection-1.0/gdump.c \
144 ${datadir}/gobject-introspection-1.0/Makefile.introspection"
145
146# These are used by dependent packages (e.g. pygobject) to build their
147# testsuites.
148FILES_${PN}-dev_append = " ${datadir}/gobject-introspection-1.0/tests/*.c \
149 ${datadir}/gobject-introspection-1.0/tests/*.h"
150
151FILES_${PN}-dbg += "${libdir}/gobject-introspection/giscanner/.debug/"
152FILES_${PN}-staticdev += "${libdir}/gobject-introspection/giscanner/*.a"
153
154# we need target versions of introspection tools in sysroot so that they can be run via qemu 139# we need target versions of introspection tools in sysroot so that they can be run via qemu
155# when building introspection files in other packages 140# when building introspection files in other packages
156SYSROOT_DIRS_append_class-target = " ${bindir}" 141SYSROOT_DIRS_append_class-target = " ${bindir}"
@@ -165,13 +150,6 @@ gi_binaries_sysroot_preprocess() {
165 ${SYSROOT_DESTDIR}${libdir}/pkgconfig/gobject-introspection-1.0.pc 150 ${SYSROOT_DESTDIR}${libdir}/pkgconfig/gobject-introspection-1.0.pc
166} 151}
167 152
168# Need to ensure ld.so.conf exists so prelink-native works
169# both before we build and if we install from sstate
170do_configure[prefuncs] += "gobject_introspection_preconfigure"
171python gobject_introspection_preconfigure () {
172 oe.utils.write_ld_so_conf(d)
173}
174
175SYSROOT_PREPROCESS_FUNCS_append = " gi_ldsoconf_sysroot_preprocess" 153SYSROOT_PREPROCESS_FUNCS_append = " gi_ldsoconf_sysroot_preprocess"
176gi_ldsoconf_sysroot_preprocess () { 154gi_ldsoconf_sysroot_preprocess () {
177 mkdir -p ${SYSROOT_DESTDIR}${bindir} 155 mkdir -p ${SYSROOT_DESTDIR}${bindir}
@@ -191,3 +169,28 @@ gi_package_preprocess() {
191 rm -f ${PKGD}${bindir}/g-ir-compiler-wrapper 169 rm -f ${PKGD}${bindir}/g-ir-compiler-wrapper
192 rm -f ${PKGD}${bindir}/g-ir-scanner-lddwrapper 170 rm -f ${PKGD}${bindir}/g-ir-scanner-lddwrapper
193} 171}
172
173SSTATE_SCAN_FILES += "g-ir-scanner-qemuwrapper g-ir-scanner-wrapper g-ir-compiler-wrapper g-ir-scanner-lddwrapper Gio-2.0.gir postinst-ldsoconf-${PN}"
174
175# .typelib files are needed at runtime and so they go to the main package
176FILES_${PN}_append = " ${libdir}/girepository-*/*.typelib"
177
178# .gir files go to dev package, as they're needed for developing (but not for running)
179# things that depends on introspection.
180FILES_${PN}-dev_append = " ${datadir}/gir-*/*.gir"
181FILES_${PN}-dev_append = " ${datadir}/gir-*/*.rnc"
182
183# These are used by gobject-based packages
184# to generate transient introspection binaries
185FILES_${PN}-dev_append = " ${datadir}/gobject-introspection-1.0/gdump.c \
186 ${datadir}/gobject-introspection-1.0/Makefile.introspection"
187
188# These are used by dependent packages (e.g. pygobject) to build their
189# testsuites.
190FILES_${PN}-dev_append = " ${datadir}/gobject-introspection-1.0/tests/*.c \
191 ${datadir}/gobject-introspection-1.0/tests/*.h"
192
193FILES_${PN}-dbg += "${libdir}/gobject-introspection/giscanner/.debug/"
194FILES_${PN}-staticdev += "${libdir}/gobject-introspection/giscanner/*.a"
195
196BBCLASSEXTEND = "native"