aboutsummaryrefslogtreecommitdiffstats
path: root/testing/perl-anyevent-http/APKBUILD
blob: 5331dcab5bb692b3ecdad37af1875849d2b5ebda (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: Nick Andrew <nick@nick-andrew.net>
# Maintainer: Nick Andrew <nick@nick-andrew.net>
pkgname=perl-anyevent-http
_pkgreal=AnyEvent-HTTP
pkgver=2.23
pkgrel=0
pkgdesc="simple but non-blocking HTTP/HTTPS client"
url="http://search.cpan.org/dist/AnyEvent-HTTP/"
arch="noarch"
license="GPL PerlArtistic"
cpandepends="perl-anyevent perl-dancer-plugin-swig"
cpanmakedepends=""
cpancheckdepends=""
depends="$cpandepends"
makedepends="perl-dev $cpanmakedepends"
checkdepends="$cpancheckdepends"
subpackages="$pkgname-doc"
source="http://search.cpan.org/CPAN/authors/id/M/ML/MLEHMANN/$_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="ba28bb01c042c6fbf51c7055ddf38dbea1b6a7e84a8a8c8ec845bf63f16f9919a388e092c59f07a9588972da45b87de3627dc66dd2b2b958b731c6b699197d90  AnyEvent-HTTP-2.23.tar.gz"