# Maintainer: Peter Budai <peterbudai@hotmail.com>

_realname=Test-Needs
pkgname=perl-${_realname}
pkgver=0.002009
pkgrel=1
pkgdesc="Skip tests when modules not available"
arch=('any')
url="https://metacpan.org/release/Test-Needs"
groups=('perl-modules')
depends=('perl')
license=('PerlArtistic')
source=("https://cpan.metacpan.org/authors/id/H/HA/HAARG/Test-Needs-${pkgver}.tar.gz")
sha256sums=('571c21193ad16195df58b06b268798796a391b398c443271721d2cc0fb7c4ac3')

prepare() {
  cd "${srcdir}/${_realname}-${pkgver}"
}

build() {
  cd "${srcdir}/${_realname}-${pkgver}"
  PERL_MM_USE_DEFAULT=1 perl Makefile.PL INSTALLDIRS=vendor
  make
}

package() {
  cd "${srcdir}/${_realname}-${pkgver}"
  make install DESTDIR="${pkgdir}"
}
