gtksourceview4: enable gir and add vala build_option

This commit is contained in:
maxice8 2019-02-05 15:28:14 -02:00 committed by maxice8
parent 353cc52fcf
commit dea969b6d0
1 changed files with 17 additions and 10 deletions

View File

@ -1,33 +1,38 @@
# Template file for 'gtksourceview4' # Template file for 'gtksourceview4'
pkgname=gtksourceview4 pkgname=gtksourceview4
version=4.0.3 version=4.0.3
revision=2 revision=3
wrksrc="gtksourceview-${version}" wrksrc="gtksourceview-${version}"
build_style=gnu-configure build_style=gnu-configure
configure_args="--enable-glade-catalog $(vopt_enable gir introspection)" build_helper="gir"
configure_args="--enable-glade-catalog $(vopt_enable gir introspection)
$(vopt_enable vala)"
hostmakedepends="gtk+3-devel glib-devel itstool libxslt pkg-config hostmakedepends="gtk+3-devel glib-devel itstool libxslt pkg-config
$(vopt_if gir "gobject-introspection")" $(vopt_if vala vala)"
makedepends="glade3-devel gtk+3-devel libglib-devel libxml2-devel vala-devel" makedepends="glade3-devel gtk+3-devel libglib-devel libxml2-devel
$(vopt_if vala vala)"
short_desc="Text widget that extends GTK+ GtkTextView widget" short_desc="Text widget that extends GTK+ GtkTextView widget"
maintainer="Rasmus Thomsen <rasmus.thomsen@protonmail.com>" maintainer="Rasmus Thomsen <rasmus.thomsen@protonmail.com>"
license="GPL-2.0-or-later" license="GPL-2.0-or-later"
homepage="https://wiki.gnome.org/Projects/GtkSourceView" homepage="https://wiki.gnome.org/Projects/GtkSourceView"
distfiles="${GNOME_SITE}/gtksourceview/${version%.*}/gtksourceview-${version}.tar.xz" distfiles="${GNOME_SITE}/gtksourceview/${version%.*}/gtksourceview-${version}.tar.xz"
checksum=3d55a7b82841d96bf414ced2e1e912d4881c9ba2f7b74f0ff8aad636087f9d73 checksum=3d55a7b82841d96bf414ced2e1e912d4881c9ba2f7b74f0ff8aad636087f9d73
nocross="gobject-introspection from glade3"
# Package build options # Package build options
build_options="gir" build_options="gir vala"
# Disable gir for cross builds.
if [ -z "$CROSS_BUILD" ]; then if [ -z "$CROSS_BUILD" ]; then
# gtk-doc generation is broken on cross # gtk-doc generation is broken on cross
configure_args+=" --enable-gtk-doc" configure_args+=" --enable-gtk-doc"
hostmakedepends+=" gtk-doc" hostmakedepends+=" gtk-doc"
build_options_default="gir"
fi fi
case "$XBPS_TARGET_MACHINE" in
x86_64-musl) build_options_default+=" gir vala" ;;
*-musl) ;;
*) build_options_default+=" gir vala" ;;
esac
do_check() { do_check() {
# Needs access to X # Needs access to X
: :
@ -41,7 +46,9 @@ gtksourceview4-devel_package() {
vmove usr/lib/pkgconfig vmove usr/lib/pkgconfig
vmove "usr/lib/*.so" vmove "usr/lib/*.so"
vmove usr/share/glade vmove usr/share/glade
vmove usr/share/vala if [ "$build_option_vala" ]; then
vmove usr/share/vala
fi
if [ "$build_option_gir" ]; then if [ "$build_option_gir" ]; then
vmove usr/share/gir-1.0 vmove usr/share/gir-1.0
fi fi