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

_realname=Authen-SASL
pkgname=perl-${_realname}
pkgver=2.16
pkgrel=2
pkgdesc="Perl/CPAN Module Authen::SASL : SASL authentication framework"
arch=('any')
license=('GPL' 'PerlArtistic')
url="http://search.cpan.org/dist/${_realname}/"
depends=('perl')
groups=('perl-modules')
options=('!emptydirs')
source=(http://www.cpan.org/authors/id/G/GB/GBARR/${_realname}-${pkgver}.tar.gz
        Authen-SASL-2.16.patch)
md5sums=('7c03a689d4c689e5a9e2f18a1c586b2f'
         '622760382e0b2bb9ed53f488a8f50a5c')

prepare() {
  cd ${_realname}-${pkgver}
  patch -p1 -i ${srcdir}/Authen-SASL-2.16.patch
}

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

package() {
  cd ${_realname}-${pkgver}
  make pure_install doc_install DESTDIR=$pkgdir
  find $pkgdir -name '.packlist' -delete
  find $pkgdir -name '*.pod' -delete
}
