# Automatically generated by apkbuild-cpan, template 1
# Contributor: Natanael Copa <ncopa@alpinelinux.org>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=perl-test-leaktrace
_pkgreal=Test-LeakTrace
pkgver=0.15
pkgrel=3
pkgdesc="Traces memory leaks"
url="http://search.cpan.org/dist/Test-LeakTrace/"
arch="all"
license="GPL PerlArtistic"
cpandepends=""
cpanmakedepends="   "
depends="$cpandepends"
makedepends="perl-dev $cpanmakedepends"
subpackages="$pkgname-doc"
source="http://search.cpan.org/CPAN/authors/id/G/GF/GFUJI/$_pkgreal-$pkgver.tar.gz
	perl-5.26.patch
	"

builddir="$srcdir/$_pkgreal-$pkgver"

build() {
	cd "$builddir"
	export CFLAGS=`perl -MConfig -E 'say $Config{ccflags}'`
	PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
	make
}

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

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

sha512sums="664d1648cc9ce229456ca0c27430bdd36ba1d9bf6907afce6c612b90d6885aa6a71caeceb266aec1f843287e6bcda35ac28eab2ad6b662019c0fcb87d7f0d6be  Test-LeakTrace-0.15.tar.gz
6fa0cf487f0ceb5cfa9eeaffd34a3bb2bcef7fa800e48493e67e6f872dcff8186e2617191a5412612efee843764770da5c49049b4f78637d3f79e8ddaac57bd0  perl-5.26.patch"
