aboutsummaryrefslogtreecommitdiffstats
path: root/community/perl-try-tiny
diff options
context:
space:
mode:
authorRoberto Oliveira <robertoguimaraes8@gmail.com>2017-11-05 01:16:36 +0000
committerRoberto Oliveira <robertoguimaraes8@gmail.com>2017-11-05 01:39:35 +0000
commitb1274f164d3742fc5a47f4ab85a91baef72338ec (patch)
tree7095e084822242b5cff89ac35bb3dee624642067 /community/perl-try-tiny
parent4c6f8e1fdf89d2899b81dd6a680a65e89e20b7a9 (diff)
downloadaports-b1274f164d3742fc5a47f4ab85a91baef72338ec.tar.bz2
aports-b1274f164d3742fc5a47f4ab85a91baef72338ec.tar.xz
community/perl-[t-y]: modernize APKBUILD
Changes: - Move tests to check() - Remove return 1 - rename _builddir to builddir
Diffstat (limited to 'community/perl-try-tiny')
-rw-r--r--community/perl-try-tiny/APKBUILD19
1 files changed, 12 insertions, 7 deletions
diff --git a/community/perl-try-tiny/APKBUILD b/community/perl-try-tiny/APKBUILD
index d418026e8c..80613159dc 100644
--- a/community/perl-try-tiny/APKBUILD
+++ b/community/perl-try-tiny/APKBUILD
@@ -4,7 +4,7 @@
pkgname=perl-try-tiny
_pkgreal=Try-Tiny
pkgver=0.28
-pkgrel=0
+pkgrel=1
pkgdesc="minimal try/catch with proper preservation of $@"
url="http://search.cpan.org/dist/Try-Tiny/"
arch="noarch"
@@ -16,23 +16,28 @@ makedepends="perl-dev $cpanmakedepends"
subpackages="$pkgname-doc"
source="http://search.cpan.org/CPAN/authors/id/E/ET/ETHER/$_pkgreal-$pkgver.tar.gz"
-_builddir="$srcdir/$_pkgreal-$pkgver"
+builddir="$srcdir/$_pkgreal-$pkgver"
prepare() {
- cd "$_builddir"
+ cd "$builddir"
export CFLAGS=`perl -MConfig -E 'say $Config{ccflags}'`
PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
}
build() {
- cd "$_builddir"
+ cd "$builddir"
export CFLAGS=`perl -MConfig -E 'say $Config{ccflags}'`
- make && make test
+ make
+}
+
+check() {
+ cd "$builddir"
+ make test
}
package() {
- cd "$_builddir"
- make DESTDIR="$pkgdir" install || return 1
+ cd "$builddir"
+ make DESTDIR="$pkgdir" install
find "$pkgdir" \( -name perllocal.pod -o -name .packlist \) -delete
}