# Contributor: Carlo Landmeter <clandmeter@gmail.com>
# Maintainer: Francesco Colista <fcolista@alpinelinux.org>
pkgname=perl-xml-namespacesupport
pkgver=1.12
pkgrel=0
pkgdesc="Generic namespace helpers (ported from SAX2)"
url="http://search.cpan.org/dist/XML-NamespaceSupport"
arch="noarch"
license="GPL"
depends="perl"
makedepends="perl-dev"
subpackages="$pkgname-doc"
source="http://www.cpan.org/authors/id/P/PE/PERIGRIN/XML-NamespaceSupport-$pkgver.tar.gz"

builddir="$srcdir"/XML-NamespaceSupport-$pkgver

check() {
	cd "$builddir"
	make test
}

build() {
	cd "$builddir"
	PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
	make
}

package() {
	cd "$builddir"
	make DESTDIR="$pkgdir" install
	find "$pkgdir" \( -name perllocal.pod -o -name .packlist \) -delete
}

sha512sums="8a29698acc152888b3abd53b277f89209252830cc3b57d587a5b66e5019445d7c1858a08fa548d42387c1143b726da1440e36eb0c69b0b59c3770b5f528f38b2  XML-NamespaceSupport-1.12.tar.gz"
