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

_realname=Sub-Install
pkgname=perl-${_realname}
pkgver=0.929
pkgrel=1
pkgdesc="Install subroutines into packages easily"
arch=('any')
url="https://metacpan.org/release/Sub-Install"
msys2_references=(
  'purl: pkg:cpan/RJBS/Sub-Install'
)
groups=('perl-modules')
depends=('perl')
license=('GPL' 'PerlArtistic')
source=("https://search.cpan.org/CPAN/authors/id/R/RJ/RJBS/Sub-Install-${pkgver}.tar.gz")
sha256sums=('80b1e281d8cd3b2b31dac711f5c8a1657a87cd80bbe69af3924bcbeb4e5db077')

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

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

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