# Automatically generated by apkbuild-cpan, template 4
# Contributor: Sean <nantes@albinodrought.com>
# Maintainer: Celeste <cielesti@protonmail.com>
pkgname=perl-archive-cpio
pkgver=0.10
pkgrel=3
#_pkgreal is used by apkbuild-cpan to find modules at MetaCpan
_pkgreal=Archive-Cpio
pkgdesc="module for manipulations of cpio archives"
url="https://metacpan.org/release/Archive-Cpio/"
arch="noarch"
license="GPL-1.0-or-later OR Artistic-1.0-Perl"
depends="perl"
subpackages="$pkgname-doc"
source="https://cpan.metacpan.org/authors/id/P/PI/PIXEL/Archive-Cpio-$pkgver.tar.gz"
builddir="$srcdir/$_pkgreal-$pkgver"

build() {
	export CFLAGS=$(perl -MConfig -E 'say $Config{ccflags}')
	PERL_MM_USE_DEFAULT=1 perl -I. Makefile.PL \
		INSTALLDIRS=vendor \
		NO_PACKLIST=1 \
		NO_PERLLOCAL=1
	make
}

check() {
	export CFLAGS=$(perl -MConfig -E 'say $Config{ccflags}')
	make test
}

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

sha512sums="
c828f6f199de0efd7c7fbe2c3d4c5304df3c714720d91dd9a7d76e2c8d16bab1b92fc93a0b8afe78bd89b043ce7684c31d54b13c4e840f68ee040ca7bff43c3d  Archive-Cpio-0.10.tar.gz
"
