summaryrefslogtreecommitdiff
path: root/perl-test-use-ok/PKGBUILD
blob: 6ae4f57d23b2637dcee3f951b5dc739be73ee37c (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
# Maintainer: Erich Eckner <arch at eckner dot net>

pkgname='perl-test-use-ok'
_realname='Test-use-ok'
pkgver='0.11'
pkgrel=13
_distdir="${_realname}-${pkgver}"
pkgdesc="Alternative to Test::More::use_ok"
arch=('any')
license=('perl')
url="http://search.cpan.org/~audreyt/Test-use-ok"
options=(!emptydirs)

depends=(
  'perl>=5.38'
  'perl<5.39'
  'perl>=5.5.0')
makedepends=(
  'perl-extutils-makemaker>=6.36'
  'perl-module-package')

source=("http://search.cpan.org/CPAN/authors/id/A/AU/AUDREYT/${_distdir}.tar.gz")
sha512sums=('ff831546c7a34edfd1a9e574300f6b299fa280ea7d3be6b3285cf173f8695d2dc51a302954dae95d2b1bb5c3f1b945081a06dc703c465ac0d4e229ce81d45293')

build() {
  cd "${_distdir}"
  # install module in vendor directories.
  export PERL_MM_USE_DEFAULT=1
  perl Makefile.PL
  make
}

check() {
  cd "${_distdir}"
  make test
}

package() {
  cd "${_distdir}"
  make install INSTALLDIRS=vendor DESTDIR=${pkgdir}

  # remove perllocal.pod and .packlist
  find ${pkgdir} -name perllocal.pod -delete
  find ${pkgdir} -name .packlist -delete
}