X-Original-To: alpine-aports@lists.alpinelinux.org Received: from mail.infogroup.kiev.ua (tera.infogroup.kiev.ua [195.144.25.26]) by lists.alpinelinux.org (Postfix) with ESMTP id 8B1A75C4F92 for ; Fri, 14 Apr 2017 23:42:42 +0000 (GMT) Received: from ost.org.ua ([195.144.25.230] helo=alpine.ost.org.ua) by mail.infogroup.kiev.ua with esmtpsa (TLSv1:DHE-RSA-AES256-SHA:256) (Exim 4.80.1) (envelope-from ) id 1czArR-0005Ve-Hg for alpine-aports@lists.alpinelinux.org; Sat, 15 Apr 2017 02:42:41 +0300 From: Valery Kartel To: alpine-aports@lists.alpinelinux.org Subject: [alpine-aports] [PATCH] testing/perl-test-unit: new aport Date: Sat, 15 Apr 2017 02:42:41 +0300 Message-Id: <20170414234241.27408-1-valery.kartel@gmail.com> X-Mailer: git-send-email 2.12.2 Sender: droid@infogroup.kiev.ua X-Mailinglist: alpine-aports Precedence: list List-Id: Alpine Development List-Unsubscribe: List-Post: List-Help: List-Subscribe: A unit testing framework http://search.cpan.org/dist/Test-Unit --- testing/perl-test-unit/APKBUILD | 51 +++++++++++++++++++++++++++++++++++ testing/perl-test-unit/testcase.patch | 11 ++++++++ 2 files changed, 62 insertions(+) create mode 100644 testing/perl-test-unit/APKBUILD create mode 100644 testing/perl-test-unit/testcase.patch diff --git a/testing/perl-test-unit/APKBUILD b/testing/perl-test-unit/APKBUILD new file mode 100644 index 0000000000..61b9376523 --- /dev/null +++ b/testing/perl-test-unit/APKBUILD @@ -0,0 +1,51 @@ +# Automatically generated by apkbuild-cpan, template 2 +# Contributor: Valery Kartel +# Maintainer: Valery Kartel +pkgname=perl-test-unit +_pkgreal=Test-Unit +pkgver=0.25 +pkgrel=0 +pkgdesc="A unit testing framework" +url="http://search.cpan.org/dist/Test-Unit/" +arch="noarch" +license="GPL PerlArtistic" +options="!check" +cpandepends="perl-class-inner perl-error perl-devel-symdump" +cpanmakedepends="" +cpancheckdepends="" +depends="$cpandepends" +makedepends="perl-dev $cpanmakedepends" +checkdepends="$cpancheckdepends" +subpackages="$pkgname-doc" +source="http://search.cpan.org/CPAN/authors/id/M/MC/MCAST/$_pkgreal-$pkgver.tar.gz + testcase.patch" +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="8f76583c7480eec825080eb6cd94d1b1a1c7c3bc7f297607414c95777e9a9f880b5a0d927a41521389ae50c2ba1b9ec3d76149da47d5997add739970df6b154d Test-Unit-0.25.tar.gz +d7e874a687f93347cb03b403b55a9a765caa38aed1f24c437c6e4a43d287084366aff5a97b4990487f00979288146a29d36989059c8e83b702824348c0f86bc5 testcase.patch" diff --git a/testing/perl-test-unit/testcase.patch b/testing/perl-test-unit/testcase.patch new file mode 100644 index 0000000000..9f28755591 --- /dev/null +++ b/testing/perl-test-unit/testcase.patch @@ -0,0 +1,11 @@ +--- a/lib/Test/Unit/TestCase.pm ++++ b/lib/Test/Unit/TestCase.pm +@@ -103,7 +103,7 @@ + my $class = ref($_[0]) || $_[0]; + my @tests = (); + no strict 'refs'; +- if (defined(@{"$class\::TESTS"})) { ++ if (@{"$class\::TESTS"}) { + push @tests, @{"$class\::TESTS"}; + } + else { -- 2.12.2 --- Unsubscribe: alpine-aports+unsubscribe@lists.alpinelinux.org Help: alpine-aports+help@lists.alpinelinux.org ---