# Maintainer: Alexey Pavlov <alexpux@gmail.com>

_realname=Parallel-ForkManager
pkgname=perl-${_realname}
pkgver=2.02
pkgrel=2
pkgdesc="A simple parallel processing fork manager"
arch=('any')
url="https://metacpan.org/release/Parallel-ForkManager"
groups=('perl-modules')
depends=('perl' 'perl-Moo')
makedepends=('perl-ExtUtils-MakeMaker')
#checkdepends=('perl-test-warn')
license=('PerlArtistic' 'GPL')
source=("http://search.cpan.org/CPAN/authors/id/Y/YA/YANICK/Parallel-ForkManager-$pkgver.tar.gz")
sha256sums=('c1b2970a8bb666c3de7caac4a8f4dbcc043ab819bbc337692ec7bf27adae4404')

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}"
}
