libosinfo: enable gir

This commit is contained in:
maxice8 2019-02-04 02:08:55 -02:00 committed by maxice8
parent 46f50b7f93
commit 960f3fc434
1 changed files with 13 additions and 8 deletions

View File

@ -1,11 +1,13 @@
# Template file for 'libosinfo'
pkgname=libosinfo
version=1.3.0
revision=1
revision=2
build_style=gnu-configure
build_helper="gir"
configure_args="--disable-static $(vopt_enable gir introspection)"
hostmakedepends="glib-devel intltool pkg-config wget"
makedepends="libxslt-devel vala-devel $(vopt_if gir 'gobject-introspection')"
hostmakedepends="glib-devel intltool pkg-config wget
$(vopt_if vala vala)"
makedepends="libxslt-devel libglib-devel"
depends="osinfo-db"
checkdepends="libosinfo"
short_desc="GObject based library API for managing info about operating systems"
@ -17,12 +19,13 @@ distfiles="https://releases.pagure.org/libosinfo/${pkgname}-${version}.tar.gz"
checksum=2159b969fe90715ee779eb3921365a9148e862e1ed60328ef1ba57714e511da5
# Package build options
build_options="gir"
build_options="gir vala"
# Disable gir for cross builds.
if [ -z "$CROSS_BUILD" ]; then
build_options_default="gir"
fi
case "$XBPS_TARGET_MACHINE" in
x86_64-musl) build_options_default+=" gir vala" ;;
*-musl) ;;
*) build_options_default+=" gir vala" ;;
esac
libosinfo-devel_package() {
depends="libglib-devel ${sourcepkg}-${version}_${revision}"
@ -34,6 +37,8 @@ libosinfo-devel_package() {
vmove usr/share/gtk-doc
if [ "$build_option_gir" ]; then
vmove usr/share/gir-1.0
fi
if [ "$build_option_vala" ]; then
vmove usr/share/vala
fi
}