# Contributor: Leo <thinkabit.ukim@gmail.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=grilo
pkgver=0.3.16
pkgrel=1
pkgdesc="GNOME media discovery framework"
url="https://wiki.gnome.org/Projects/Grilo"
arch="all"
license="LGPL-2.1-or-later"
makedepends="
	docbook-xml
	docbook-xsl
	gmime-dev
	gnome-desktop-dev
	gobject-introspection-dev
	itstool
	liboauth-dev
	libsoup3-dev
	libxml2-dev
	libxml2-utils
	libxslt
	meson
	totem-pl-parser-dev
	vala
	"
subpackages="$pkgname-dev $pkgname-doc $pkgname-lang $pkgname-libs"
source="https://download.gnome.org/sources/grilo/${pkgver%.*}/grilo-$pkgver.tar.xz"
build() {
	abuild-meson \
		-Db_lto=true \
		-Denable-introspection=true \
		-Denable-vala=true \
		-Denable-gtk-doc=false \
		-Dsoup3=true \
		build
	meson compile -C build
}

check() {
	meson test -t 4 --print-errorlogs -C build
}

package() {
	DESTDIR="$pkgdir" meson install --no-rebuild -C build
}

sha512sums="
ef04f8c3e5308893d60831580262724bf427e9e3cd2093dcc4917ac93c7e814c9524badaf5246e3ee3748ec2e70afae03df188bf0a1c3e405f4bd6264eedd313  grilo-0.3.16.tar.xz
"
