# $Id: PKGBUILD 126544 2015-01-25 03:19:59Z anatolik $
# Maintainer:
# Contributor: Firmicus <francois.archlinux.org>
# Contributor: Tom K <tomk@runbox.com>

pkgname=mod_perl
pkgver=2.0.8
pkgrel=4
pkgdesc='Apache module that embeds the Perl interpreter within the server'
arch=(i686 x86_64)
url='http://perl.apache.org/'
license=(APACHE)
depends=(perl apache db apr-util perl-linux-pid)
makedepends=(subversion)
options=(!emptydirs)
# upstream from http://apache.org/dist/perl/$pkgname-$pkgver.tar.gz is not ready for apache 2.4 yet
# See the discussion http://mail-archives.apache.org/mod_mbox/perl-modperl/201402.mbox/thread
# But trunk seems almost ready for Apache 2.4
# http://mail-archives.apache.org/mod_mbox/perl-modperl/201408.mbox/browser
source=(mod_perl::svn+http://svn.apache.org/repos/asf/perl/modperl/trunk#revision=1654615)
sha256sums=('SKIP')

build() {
  cd mod_perl
  perl Makefile.PL INSTALLDIRS=vendor MP_APXS=/usr/bin/apxs
  make
}

check() {
  cd mod_perl
  # tests are very flaky
  # make test
}

package() {
  cd mod_perl
  make install DESTDIR="$pkgdir"
}
