aboutsummaryrefslogtreecommitdiffstats
path: root/community/perl-moo/APKBUILD
blob: 660d2baf97c20421219ec55886704d1aacf31a5c (plain)
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
37
38
39
40
41
42
43
44
45
46
47
48
# Automatically generated by apkbuild-cpan, template 2
# Contributor: Kiyoshi Aman <kiyoshi.aman@gmail.com>
# Maintainer: Kiyoshi Aman <kiyoshi.aman@gmail.com>
pkgname=perl-moo
_pkgreal=Moo
pkgver=2.003004
pkgrel=0
pkgdesc="Minimalist Object Orientation (with Moose compatibility)"
url="http://search.cpan.org/dist/Moo/"
arch="noarch"
license="GPL PerlArtistic"
cpandepends="perl-module-runtime perl-sub-quote perl-role-tiny perl-devel-globaldestruction perl-class-method-modifiers"
cpanmakedepends=""
cpancheckdepends="perl-test-fatal"
depends="$cpandepends"
makedepends="perl-dev $cpanmakedepends"
checkdepends="perl-strictures $cpancheckdepends"
subpackages="$pkgname-doc"
source="http://search.cpan.org/CPAN/authors/id/H/HA/HAARG/$_pkgreal-$pkgver.tar.gz"
builddir="$srcdir/$_pkgreal-$pkgver"

prepare() {
	default_prepare || return 1

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

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

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

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

sha512sums="686996e4dd0238cff7483e4e06db5439660e390c67e65ace67c3fd0b05ade379a168d36ae649812c8a5e2b715eefea7cb17e5db323a0cd31b90667d8954eb38a  Moo-2.003004.tar.gz"