# Contributor: Carlo Landmeter # Maintainer: pkgname=clapf pkgver=0.4.7.4 pkgrel=0 pkgdesc="clapf is an open source email content filter application" url="http://clapf.acts.hu" arch="all" license="as-is" depends="clamav-db" depends_dev="gsl-dev mysql-dev clamav-dev zlib-dev bzip2-dev" makedepends="$depends_dev autoconf automake" install="$pkgname.pre-install" pkgusers="clapf" subpackages="$pkgname-dev" source="http://clapf.acts.hu/clapf-$pkgver.tar.gz gsl-libs.patch def__user.patch ldflags.patch $pkgname.confd $pkgname.initd" _builddir="$srcdir/$pkgname-$pkgver" prepare() { local i cd "$_builddir" for i in $source; do case $i in *.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;; esac done aclocal && autoconf } build() { cd "$_builddir" ./configure --prefix=/usr \ --sysconfdir=/etc \ --mandir=/usr/share/man \ --infodir=/usr/share/info \ --localstatedir=/var \ --enable-libclamav \ --with-tokendb=mysql \ --enable-lmtp \ --with-store=fs \ --enable-blackhole \ --enable-rbl \ --enable-policy \ --enable-whitelist \ --enable-blackhole \ --with-clapf-user=clapf \ --enable-language-detection \ --enable-memcached \ --enable-spamsum make || return 1 } package() { cd "$_builddir" make -j1 DESTDIR="$pkgdir" install || return 1 install -Dm755 "$srcdir/$pkgname".initd \ "$pkgdir/etc/init.d/$pkgname" || return 1 install -Dm644 "$srcdir/$pkgname".confd \ "$pkgdir/etc/cond.d/$pkgname" || return 1 install -do $pkgname "$pkgdir"/var/run/clapf || return 1 } md5sums="e6be84e17886401b4818c6285a7b2888 clapf-0.4.7.4.tar.gz 7f480d5a8d0da4863b682deddfe47eff gsl-libs.patch ba31f71c066f3f6159548808d2e26d8b def__user.patch c6bd9005236f6a40c32fe1f04fafc94b ldflags.patch 385318b45b2bccdd76fd312576380735 clapf.confd 263283c96608d696cd5e9eb9de921b16 clapf.initd" sha256sums="a38e5b28ff58119abf50054fac2c03b04f959251e844893f0c9f669ce76c99e3 clapf-0.4.7.4.tar.gz 4b4bb8530ac740a5279e0fdd959c6b706b3635792030f6b242e282f8d923202c gsl-libs.patch 0523e889808f6aa3ec71a34846cbdfc9d1b185463583dcd7239673d098402346 def__user.patch 00035eb11386f40c68ebaea79c31659f19f4f5a29503d47e9e0d3a6efc32f9fe ldflags.patch 1c5c87adfa2efdaa55d7c8e07ac7ca6b4a068313723dbf46dd1d1ccaf3e54e6a clapf.confd f5c849b01734115ff83e9a2bb0eb4a34bd25d20f646c7945a8887815a65f1ec3 clapf.initd" sha512sums="7eb95e25671d0ad4d37cd16f5c293bb7cc8466cbc3dd6b7ac250d75f277423f57012e57373bd8f69174bcb15e865caa33e97dd6adcb0a52553b6ce9069036b05 clapf-0.4.7.4.tar.gz 096ed4afe1b0fad569a172d6af952f1590d230dd38f6f0c4c0b1e7f29a1515fd887f1c099267aa926ce698864b75cb50626a9b7f49914549748d22ba7058a31d gsl-libs.patch 18b8bf55f20e86e05958f2b4a8bdea8bedeb712bc91bb9a6a67faa2928b545707d3391671ab843415fe11703fef4683594571136cf9b2ec87aa41b0875d34588 def__user.patch d71081b2f1bdc9f44ee5cee6e4149e6e53d5ef5415069814dd22d9c2df6eee0195b9e3466468d01d0b5bcfadfc20ec0eacfd1299d5f37cbe7f326ffab435972b ldflags.patch 99795b8063234c5dbf10da145660c39dfe3f121aa4bb17869abc0dcab5dfd765bfba033a701c8b70d57cb4fe2811d122da1e56506a1c45c0afdcc2102719d798 clapf.confd 08e42083bcdfe39099d78db23961c0585883cfb3ad4b789376ca34d1d89556dbae153eeda281f08ffe179a4305188062c03ed1a53ca98d636c44ddbd7b40112a clapf.initd"