# Contributor: Jakub Jirutka <jakub@jirutka.cz>
# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
pkgname=c-rbtree
pkgver=3.2.0
pkgrel=0
pkgdesc="Intrusive Red-Black Tree Collection"
url="https://github.com/c-util/c-rbtree"
arch="all"
license="Apache-2.0 OR LGPL-2.1-or-later"
makedepends="
	c-stdaux-dev~1
	meson
	"
subpackages="$pkgname-dev"
source="https://github.com/c-util/c-rbtree/archive/v$pkgver/c-rbtree-$pkgver.tar.gz"

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

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

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

sha512sums="
028c910162200c67cb050fbba20c0cda5aca89dbd931c5456984adb87b1873d831364b0b939ffd6752f1d6df6d87bc250a1ad13aebea1365c747b854d7e5395e  c-rbtree-3.2.0.tar.gz
"
