# Contributor:
# Maintainer: Leonardo Arena <rnalrd@alpinelinux.org>
pkgname=libnetfilter_acct
pkgver=1.0.3
pkgrel=0
pkgdesc="Userspace library providing interface to extended accounting infrastructure."
url="http://www.netfilter.org/projects/libnetfilter_conntrack/"
arch="all"
license="GPL-2.0"
depends=
makedepends="libnfnetlink-dev libmnl-dev linux-headers"
subpackages="$pkgname-dev"
source="http://www.netfilter.org/projects/$pkgname/files/$pkgname-$pkgver.tar.bz2"

_builddir="$srcdir/$pkgname-$pkgver"

prepare() {
	cd "$_builddir"
	update_config_sub || return 1
}

build() {
	cd "$_builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info \
		|| return 1
	make || return 1
}

package() {
	cd "$_builddir"
	make DESTDIR="$pkgdir" install || return 1
}

sha512sums="5ca332840663941182343fdc0d5e45116bba71a97a913db0b385ea37ef31a04f8267a2279b7a2862ce338c6eeb093bb3ef9908f57770e64acf5d2b2266d3bfe5  libnetfilter_acct-1.0.3.tar.bz2"
