# Contributor: Kay Thomas <kaythomas@pm.me>
# Maintainer: Kay Thomas <kaythomas@pm.me>
pkgname=lingot
pkgver=1.1.1
pkgrel=2
pkgdesc="Musical instrument tuner"
url="https://github.com/ibancg/lingot"
arch="all"
license="GPL-2.0-or-later"
makedepends="autoconf automake intltool gtk+3.0-dev libtool pkgconfig
	json-c-dev alsa-lib-dev pulseaudio-dev jack-dev fftw-dev
	cunit-dev"
subpackages="$pkgname-doc $pkgname-dev"
source="$pkgname-$pkgver.tar.gz::https://github.com/ibancg/lingot/archive/v$pkgver.tar.gz"

prepare() {
	default_prepare

	./bootstrap
}

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--localstatedir=/var \
		--with-alsa \
		--with-pulseaudio \
		--with-jack \
		--with-oss \
		--with-fftw \
		--with-cunit \
		--disable-nls \
		--disable-dependency-tracking
	make
}

check() {
	make check
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="4bcfbabccfdfb4d7077d17eec709f35c1427ce91bc08f967bcc53cb321aaf2f83901cea19025d03ffe926b60c9b64d9d85b976852c709c52438c9d702912291c  lingot-1.1.1.tar.gz"
