aboutsummaryrefslogtreecommitdiffstats
path: root/main/perl-net-dns-resolver-mock/APKBUILD
blob: bbc77fe3681290b1a4c55fc50febf6da4cef5257 (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
# Automatically generated by apkbuild-cpan, template 2
# Contributor:
# Maintainer: Leonardo Arena <rnalrd@alpinelinux.org>
pkgname=perl-net-dns-resolver-mock
_pkgreal=Net-DNS-Resolver-Mock
pkgver=1.20171219
pkgrel=0
pkgdesc="Mock a DNS Resolver object for testing"
url="https://metacpan.org/release/Net-DNS-Resolver-Mock"
arch="noarch"
license="GPL-1.0-or-later OR Artistic-1.0-Perl"
cpandepends="perl-net-dns"
depends="$cpandepends"
makedepends="perl-dev"
subpackages="$pkgname-doc"
source="https://cpan.metacpan.org/authors/id/M/MB/MBRADSHAW/Net-DNS-Resolver-Mock-$pkgver.tar.gz"
builddir="$srcdir/$_pkgreal-$pkgver"

prepare() {
	default_prepare

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

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

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

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

sha512sums="4c028edc162e7dbf5804d19f35e761086933bf1fbfc84182ad2ab0f3db356ff3f30c280e734e4c85f737ff377350149c559459c0c77d36ef3313c96c1bf046c8  Net-DNS-Resolver-Mock-1.20171219.tar.gz"