# Automatically generated by apkbuild-cpan, template 3
# Contributor: Timothy Legge <timlegge@gmail.com>
# Maintainer: Timothy Legge <timlegge@gmail.com>
pkgname=perl-xml-sig
#_pkgreal is used by apkbuild-cpan to find modules at MetaCpan
_pkgreal=XML-Sig
pkgver=0.65
pkgrel=0
pkgdesc="A toolkit to help sign and verify XML Digital Signatures."
url="https://metacpan.org/release/XML-Sig/"
arch="noarch"
license="GPL-1.0-or-later OR Artistic-1.0-Perl"
depends="
	perl perl-crypt-openssl-bignum perl-crypt-openssl-dsa perl-class-accessor
	perl-crypt-openssl-x509 perl-crypt-openssl-rsa perl-xml-libxml perl-cryptx perl-uri
	"
checkdepends="
	perl-test-exception perl-file-which perl-crypt-openssl-guess
	perl-import-into perl-test-lib
	"
subpackages="$pkgname-doc"
source="https://cpan.metacpan.org/authors/id/T/TI/TIMLEGGE/XML-Sig-$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
	make
}

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

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

sha512sums="
023d22a377de3ba3d344d4cef089deeccf8b081282f3eca3569391860907b68afe02b4b93cc407c75efa34c6e3f8808d9aa0167daaa3c8bf03301dc1dde13dc4  XML-Sig-0.65.tar.gz
"
