changeset 719:a70abf476771

lang/vala: add VALADOC option
author David Demelier <markand@malikania.fr>
date Mon, 05 Aug 2019 12:40:35 +0200
parents 08f07e05c4ad
children 100b1ba8672d
files lang/vala/vala.sh
diffstat 1 files changed, 11 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/lang/vala/vala.sh	Mon Aug 05 12:40:13 2019 +0200
+++ b/lang/vala/vala.sh	Mon Aug 05 12:40:35 2019 +0200
@@ -22,7 +22,7 @@
 PKGSUMMARY="compiler using the gobject type system"
 PKGDOWNLOAD="https://download.gnome.org/sources/$PKGNAME/0.44/$PKGNAME-$PKGVERSION.tar.xz"
 PKGDEPENDS="lib/glib"
-# PKGOPTIONS="FOO BAR BAZ"
+PKGOPTIONS="VALADOC"
 
 : ${CHOST:=$(uname -m)-linux-musl}
 : ${CBUILD:=$(uname -m)-linux-musl}
@@ -30,6 +30,14 @@
 : ${CFLAGS:=-O2}
 : ${LDFLAGS:=}
 : ${LIBS:=}
+: ${VALADOC:=yes}
+
+if [ "$VALADOC" = "yes" ]; then
+	PKGDEPENDS="graphics/graphviz $PKGDEPENDS"
+	with_valadoc="--enable-valadoc"
+else
+	with_valadoc="--disable-valadoc"
+fi
 
 build()
 {
@@ -46,7 +54,8 @@
 		--host=$CHOST \
 		--prefix= \
 		--disable-static \
-		--enable-shared
+		--enable-shared \
+		$with_valadoc
 	make
 	make install DESTDIR=$DESTDIR
 	rm -f $DESTDIR/lib/libvala*.la