# Maintainer: Sergej Pupykin <pupykin.s+arch@gmail.com>
# Maintainer: Charles Mauch <cmauch@gmail.com>

pkgname=perl-mail-sendmail
pkgver=0.82
pkgrel=3
pkgdesc="Perl/CPAN Module Mail::Sendmail : Simple platform independent mailer"
arch=("any")
url="https://search.cpan.org/~mivkovic/Mail-Sendmail/"
license=("GPL" "PerlArtistic")
depends=('perl-sys-hostname-long')
source=("https://www.cpan.org/authors/id/N/NE/NEILB/Mail-Sendmail-$pkgver.tar.gz")
sha256sums=('86c0611be3788afe4005d04bbc047b39f78b6253c68990c7a7680ed95e9ff516')
options=(!emptydirs)

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

package() {
  cd "$srcdir"/Mail-Sendmail-$pkgver
  make install DESTDIR="$pkgdir"
  find "$pkgdir" -name '.packlist' -delete
  find "$pkgdir" -name '*.pod' -delete
}
