diff options
author | Carlo Landmeter <clandmeter@gmail.com> | 2011-05-17 19:41:44 +0000 |
---|---|---|
committer | Carlo Landmeter <clandmeter@gmail.com> | 2011-05-17 19:42:17 +0000 |
commit | bdaf29c68ca9a14cb2adcbc944f26d59187c7743 (patch) | |
tree | 74415c3e8dfba7ba438e4a6e76d3613a096f04f9 /testing | |
parent | 0038c58e264285009c7e1d3b0f8e396713882f5c (diff) | |
download | aports-bdaf29c68ca9a14cb2adcbc944f26d59187c7743.tar.bz2 aports-bdaf29c68ca9a14cb2adcbc944f26d59187c7743.tar.xz |
testing/clapf: new aport
Diffstat (limited to 'testing')
-rw-r--r-- | testing/clapf/APKBUILD | 67 | ||||
-rw-r--r-- | testing/clapf/clapf.confd | 4 | ||||
-rw-r--r-- | testing/clapf/clapf.initd | 23 | ||||
-rw-r--r-- | testing/clapf/clapf.pre-install | 3 |
4 files changed, 97 insertions, 0 deletions
diff --git a/testing/clapf/APKBUILD b/testing/clapf/APKBUILD new file mode 100644 index 0000000000..5081192831 --- /dev/null +++ b/testing/clapf/APKBUILD @@ -0,0 +1,67 @@ +# Contributor: Carlo Landmeter <clandmeter@gmail.com> +# Maintainer: +pkgname=clapf +pkgver=0.4.6_rc3 +_realver=0.4.6-rc3 +pkgrel=0 +pkgdesc="clapf is an open source email content filter application" +url="http://clapf.acts.hu" +arch="all" +license="as-is" +depends= +depends_dev="gsl-dev sqlite-dev clamav-dev zlib-dev" +makedepends="$depends_dev" +install="$pkgname.pre-install" +pkgusers="clapf" +subpackages="$pkgname-dev" +source="http://clapf.acts.hu/clapf-$_realver.tar.gz + $pkgname.confd + $pkgname.initd" + +_builddir="$srcdir/$pkgname-$_realver" + +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 +} + +build() { + cd "$_builddir" + #temp use sqlite for testing + #probably better to update to mysql + ./configure --prefix=/usr \ + --sysconfdir=/etc \ + --mandir=/usr/share/man \ + --infodir=/usr/share/info \ + --localstatedir=/var \ + --enable-libclamav \ + --with-tokendb=sqlite3 \ + --with-userdb=sqlite3 \ + --enable-lmtp \ + --with-store=fs \ + --enable-blackhole \ + --enable-rbl \ + --enable-policy \ + --enable-whitelist \ + --with-clapf-user=clapf + 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="7850eb8b75988f3944f2b69b9e3b0c4d clapf-0.4.6-rc3.tar.gz +385318b45b2bccdd76fd312576380735 clapf.confd +263283c96608d696cd5e9eb9de921b16 clapf.initd" diff --git a/testing/clapf/clapf.confd b/testing/clapf/clapf.confd new file mode 100644 index 0000000000..f31009d75d --- /dev/null +++ b/testing/clapf/clapf.confd @@ -0,0 +1,4 @@ +# +# Config file for /etc/init.d/clapf +# +TMPDIR="/var/lib/clapf" diff --git a/testing/clapf/clapf.initd b/testing/clapf/clapf.initd new file mode 100644 index 0000000000..eaf2aa49e3 --- /dev/null +++ b/testing/clapf/clapf.initd @@ -0,0 +1,23 @@ +#!/sbin/runscript +# Copyright 1999-2005 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: + +depend() { + need net + use logger + before mta +} + +start() { + ebegin "Starting clapf" + start-stop-daemon --start --quiet --user clapf --background \ + --exec /usr/sbin/clapf --make-pidfile --pid /var/run/clapf/clapf.pid -- -c /etc/clapf.conf + eend $? +} + +stop() { + ebegin "Stopping clapf" + start-stop-daemon --stop --quiet --pidfile /var/run/clapf/clapf.pid + eend $? +} diff --git a/testing/clapf/clapf.pre-install b/testing/clapf/clapf.pre-install new file mode 100644 index 0000000000..01997df895 --- /dev/null +++ b/testing/clapf/clapf.pre-install @@ -0,0 +1,3 @@ +#!/bin/sh +adduser -H -s /bin/false -D clamav 2>/dev/null +exit 0 |