2019-01-29 13:18:06 +00:00
|
|
|
#
|
|
|
|
# gir - build-helper for gobject-introspection
|
|
|
|
#
|
|
|
|
# This build-helper is used for packages that make use of
|
|
|
|
# the GObject introspection middleware layer.
|
|
|
|
#
|
|
|
|
|
|
|
|
# Check if the 'gir' build_option is set or if there is no
|
|
|
|
# 'gir' build_option.
|
|
|
|
if [ "$build_option_gir" ] || [[ $build_options != *"gir"* ]]; then
|
2019-04-29 11:14:42 +00:00
|
|
|
if [[ $hostmakedepends != *"gobject-introspection"* ]]; then
|
|
|
|
# Provide the host tooling, g-ir-scanner, g-ir-compiler
|
|
|
|
# and its wrappers.
|
|
|
|
hostmakedepends+=" gobject-introspection"
|
|
|
|
fi
|
2019-01-29 13:18:06 +00:00
|
|
|
|
|
|
|
if [ "$CROSS_BUILD" ]; then
|
|
|
|
# Required for running binaries produced from g-ir-compiler
|
|
|
|
# via g-ir-scanner-qemuwrapper
|
|
|
|
hostmakedepends+=" qemu-user-static"
|
|
|
|
|
|
|
|
# Required for running the g-ir-scanner-lddwrapper
|
|
|
|
hostmakedepends+=" prelink-cross"
|
|
|
|
|
2019-04-29 13:36:28 +00:00
|
|
|
if [[ $makedepends != *"gobject-introspection"* ]]; then
|
|
|
|
# Provide basic .gir types like GLib, GObject, DBus, Gio, cairo
|
|
|
|
# and tooling like g-ir-compiler
|
|
|
|
makedepends+=" gobject-introspection"
|
|
|
|
fi
|
2019-04-28 15:36:53 +00:00
|
|
|
|
2019-04-29 02:55:54 +00:00
|
|
|
export VAPIGEN_VAPIDIRS=${XBPS_CROSS_BASE}/usr/share/vala/vapi
|
|
|
|
export VAPIGEN_GIRDIRS=${XBPS_CROSS_BASE}/usr/share/gir-1.0
|
|
|
|
|
2019-05-07 12:26:45 +00:00
|
|
|
# Provide some packages in hostmakedepends if they are in makedepends
|
2022-03-03 20:41:44 +00:00
|
|
|
for f in gtk+3-devel python3-gobject-devel; do
|
2019-05-07 12:26:45 +00:00
|
|
|
if [[ $makedepends == *"${f}"* ]]; then
|
|
|
|
hostmakedepends+=" ${f}"
|
|
|
|
fi
|
|
|
|
done
|
|
|
|
unset f
|
2019-01-29 13:18:06 +00:00
|
|
|
fi
|
|
|
|
fi
|