# Contributor: fossdd <fossdd@pwned.life>
maintainer="fossdd <fossdd@pwned.life>"
pkgname=decibels
pkgver=48.0
pkgrel=0
pkgdesc="Play audio files"
url="https://gitlab.gnome.org/GNOME/Incubator/decibels"
arch="noarch !armhf" # armhf: gjs -> mozjs
license="GPL-3.0-or-later"
depends="
	gjs
	gtk4.0
	libadwaita
"
makedepends="
	meson
	gtk4.0-dev
	libadwaita-dev
	gjs-dev
	typescript
	blueprint-compiler
	desktop-file-utils
	gobject-introspection-dev
	"
subpackages="$pkgname-lang"
source="https://download.gnome.org/sources/decibels/${pkgver%.*}/decibels-$pkgver.tar.xz"

build() {
	abuild-meson \
		output .
	meson compile -C output
}

check() {
	meson test --print-errorlogs -C output
}

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

	ln -s org.gnome.Decibels "$pkgdir"/usr/bin/decibels
}

sha512sums="
2e896163771640ab6d4c89607ac0db4577d1a587c3c5a4fa8b935a993904c21ee2ba8f0a63d26b75d7358a2f8a8d2502ab42237229124ae57bb4f501d563a115  decibels-48.0.tar.xz
"
