# Contributor: A. Wilcox <awilfox@adelielinux.org>
# Maintainer: Síle Ekaterin Liszka <sheila@vulpine.house>
pkgname=perl-template-toolkit
_pkgreal=Template-Toolkit
_author=TODDR
_au=${_author%%"${_author#??}"}
_a=${_author%%"${_author#?}"}
pkgver=3.100
pkgrel=0
pkgdesc="Comprehensive template processing system"
url="https://metacpan.org/release/Template-Toolkit"
arch="all"
license="Artistic-1.0-Perl OR GPL-1.0+"
depends="perl-appconfig"
checkdepends="perl-cgi perl-test-leaktrace"
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="7a23254450662a71761f7f8f6d774f71695ce975ef5638d04e45858a39003f82453cefdfed4528840094126a6148fe68d98a39fd5dde4908a08b6128576b3767  Template-Toolkit-3.100.tar.gz"