# Contributor: A. Wilcox <awilfox@adelielinux.org>
# Maintainer: Síle Ekaterin Liszka <sheila@vulpine.house>
pkgname=perl-package-stash-xs
_pkgreal=Package-Stash-XS
_author=ETHER
_au=${_author%%"${_author#??}"}
_a=${_author%%"${_author#?}"}
pkgver=0.30
pkgrel=0
pkgdesc="Faster and more correct implementation of Package::Stash"
url="https://metacpan.org/release/Package-Stash-XS"
arch="all"
license="Artistic-1.0-Perl OR GPL-1.0+"
depends="perl"
checkdepends="perl-test-fatal perl-test-needs perl-test-requires"
makedepends="perl-dev"
subpackages="$pkgname-doc"
source="https://cpan.metacpan.org/authors/id/$_a/$_au/$_author/$_pkgreal-$pkgver.tar.gz"
builddir="$srcdir/$_pkgreal-$pkgver"

build() {
	PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
	make
}

check() {
	make test
}

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

sha512sums="528faaefa71c5c37d378a9bedf325babf3b2717024995d166fc77bb1fb1ce1aed11da775608029a1c215c903dcd7ac9f68569cd8fd3690681ccd72b47c51b0a3  Package-Stash-XS-0.30.tar.gz"