aboutsummaryrefslogtreecommitdiffstats
path: root/community/perl-datetime-format-natural/APKBUILD
blob: 265362d33505bb88158169acc2c098251984accf (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# Contributor: Leonardo Arena <rnalrd@alpinelinux.org>
# Maintainer: Leonardo Arena <rnalrd@alpinelinux.org>
pkgname=perl-datetime-format-natural
_pkgreal=DateTime-Format-Natural
pkgver=1.11
pkgrel=0
pkgdesc="Create machine readable date/time with natural parsing logic"
url="https://metacpan.org/release/DateTime-Format-Natural"
arch="noarch"
license="GPL-1.0-or-later OR Artistic-1.0-Perl"
depends="perl-datetime-timezone perl-clone perl-params-validate
	perl-list-moreutils perl-datetime perl-boolean"
makedepends="perl-module-util perl-test-mocktime perl-date-calc
	perl-mro-compat perl-role-tiny perl-dev"
subpackages="$pkgname-doc"
source="https://cpan.metacpan.org/authors/id/S/SC/SCHUBIGER/DateTime-Format-Natural-$pkgver.tar.gz"

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

build() {
	export CFLAGS=$(perl -MConfig -E 'say $Config{ccflags}')
	PERL_MM_USE_DEFAULT=1 perl 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="1e89fe7ea05eec620f453cde4874bba6ced5d4055944e9e396226041c1d2efaa9b5a4852b88484b7dc00d792d2842a5c74f5eb86e70b220a3a8afbc7e1111c80  DateTime-Format-Natural-1.11.tar.gz"