# Automatically generated by apkbuild-cpan, template 1
# Contributor: Francesco Colista <fcolista@alpinelinux.org>
# Maintainer: Francesco Colista <fcolista@alpinelinux.org>
pkgname=perl-datetime-format-strptime
_pkgreal=DateTime-Format-Strptime
pkgver=1.79
pkgrel=1
pkgdesc="Parse and format strp and strf time patterns"
url="https://metacpan.org/release/DateTime-Format-Strptime/"
arch="noarch"
license="Artistic-2.0"
depends="perl-params-validate perl-datetime perl-try-tiny
	perl-package-deprecationmanager perl-datetime-timezone
	perl-datetime-locale"
makedepends="perl-test-warnings perl-test-fatal perl-dev"
subpackages="$pkgname-doc"
source="https://cpan.metacpan.org/authors/id/D/DR/DROLSKY/$_pkgreal-$pkgver.tar.gz"

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

prepare() {
	export CFLAGS=$(perl -MConfig -E 'say $Config{ccflags}')
	PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
}

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

check() {
	make test
}

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

sha512sums="
842da603c4314e2506f12de2a8ce5e7bf29b183d6064b7f40b663934fba3612e26073835c49c5f58accc9727f1c1883d48deb69e11ceec28f9f47e776c4e2d7c  DateTime-Format-Strptime-1.79.tar.gz
"
