aboutsummaryrefslogtreecommitdiffstats
path: root/testing/perl-sereal/APKBUILD
blob: 65865a7bb3f759dabb115226ab368732680146f6 (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
# Automatically generated by apkbuild-cpan, template 2
# Contributor: Timo Teräs <timo.teras@iki.fi>
# Maintainer: Timo Teräs <timo.teras@iki.fi>
pkgname=perl-sereal
_pkgreal=Sereal
pkgver=4.011
pkgrel=0
pkgdesc="Fast, compact, powerful binary (de-)serialization"
url="https://metacpan.org/release/Sereal"
arch="noarch"
license="GPL-1.0-or-later OR Artistic-1.0-Perl"
depends="perl perl-sereal-decoder perl-sereal-encoder"
makedepends="perl-dev"
checkdepends="perl-test-warn perl-test-longstring"
subpackages="$pkgname-doc"
source="https://cpan.metacpan.org/authors/id/Y/YV/YVES/Sereal-$pkgver.tar.gz"
builddir="$srcdir/$_pkgreal-$pkgver"

prepare() {
	default_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
}

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

check() {
	# Fails on builders
	# t/700_roundtrip/v4/zstd.t
	# t/700_roundtrip/v4/zstd_force.t
	[ "$CARCH" = armhf ] && return 0

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

sha512sums="f8a0fddbddb73decabcfa676390d002c26e6ed71489e352ed438c58c46e5c3a65dd502cce5e5653ea6647b860548488e1df1403123b502d14c57e7f5981bb899  Sereal-4.011.tar.gz"