# Maintainer: Kevin Daudt <kdaudt@alpinelinux.org>
pkgname=colord-gtk
pkgver=0.3.1
pkgrel=0
pkgdesc="GTK support library for colord"
options="!check" # Requires bus session
url="https://www.freedesktop.org/software/colord/"
arch="all"
license="LGPL-2.1-or-later"
makedepends="
	colord-dev
	glib-dev
	gtk+3.0-dev
	gtk4.0-dev
	lcms2-dev
	meson
	"
checkdepends="xvfb-run"
subpackages="$pkgname-dev $pkgname-lang"
source="https://www.freedesktop.org/software/colord/releases/colord-gtk-$pkgver.tar.xz"

build() {
	abuild-meson \
		-Dgtk2=false \
		-Dvapi=true \
		-Dtests=true \
		-Dman=false \
		-Ddocs=false \
		. output
	meson compile -C output
}

check() {
	xvfb-run meson test --no-rebuild --print-errorlogs -C output
}

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

sha512sums="
d8ac4e6f32a0672cd4e87585a03e82ecfc359ae4b99a4a6529ad81025f9beec5a3b479e94dff9a7e49db03e99671099b7f8370f6f87791e5a9fc008da859b238  colord-gtk-0.3.1.tar.xz
"
