# Maintainer: Jan Alexander Steffens (heftig) <jan.steffens@gmail.com>
# Contributor: Caleb Cushing <xenoterracide@gmail.com>

pkgname=perl-file-sharedir
_realname=File-ShareDir
pkgver=1.116
pkgrel=2
pkgdesc="Locate per-dist and per-module shared files"
arch=(any)
license=(PerlArtistic GPL)
depends=(perl-class-inspector)
url="https://metacpan.org/release/File-ShareDir"
options=('!emptydirs')
_author=REHSACK
source=("https://cpan.metacpan.org/authors/id/${_author::1}/${_author::2}/${_author}/$_realname-$pkgver.tar.gz")
md5sums=('f2a0eee9f04c93753dd56437175e5bda')

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

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