aboutsummaryrefslogtreecommitdiffstats
path: root/unmaintained/dbmail/APKBUILD
blob: ac5e3063d9d549494636c4e99098825f2e65a79b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
# Contributor: Carlo Landmeter <clandmeter@gmail.com>
# Maintainer: Francesco Colista <fcolista@alpinelinux.org>
pkgname=dbmail
_realpkgver=3.2.3
pkgver=3.2.3
pkgrel=2
pkgdesc="Fast and scalable sql based mail services"
url="http://dbmail.org"
arch="all"
license="GPL"
pkgusers="dbmail"
pkggroups="dbmail"
depends=
depends_dev="openldap-dev libsieve-dev glib-dev gmime-dev
	mhash-dev libevent-dev libzdb-dev"
makedepends="$depends_dev asciidoc xmlto automake autoconf bsd-compat-headers"
install=""
subpackages="$pkgname-doc $pkgname-auth-ldap:auth_ldap"
source="http://www.dbmail.org/download/3.2/dbmail-${_realpkgver}.tar.gz
	$pkgname-imapd.initd
	$pkgname-lmtpd.initd
	$pkgname-pop3d.initd
	$pkgname-httpd.initd
	$pkgname-timsieved.initd
	$pkgname.pre-install
	dbmail.conf
	"

_builddir="$srcdir/${pkgname}-${_realpkgver}"

prepare() {
	local i
	cd "$_builddir"
	# we need support for gmine 2.6
	sed -i 's/gmime-2.4/gmime-2.6/g' configure
}

build() {
	cd "$_builddir"
	./configure --prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info \
		--with-sieve \
		--with-ldap \
		--disable-static
	make || return 1
	# make man pages
	cd "$_builddir/man"
	make || return 1
}

package() {
	cd "$_builddir"
	make DESTDIR="$pkgdir" install || return 1
	mkdir -p "$pkgdir/usr/share/$pkgname"
	mv sql/* "$pkgdir/usr/share/$pkgname/"
	mv "$pkgname.schema" "$pkgdir/usr/share/$pkgname/"
	for i in imapd lmtpd pop3d httpd timsieved; do
		install -Dm755 "$srcdir/$pkgname-$i.initd" \
			"$pkgdir/etc/init.d/dbmail-$i" || return 1
	done
	#install man pages
	cd "$_builddir/man"
	make DESTDIR="$pkgdir" install || return 1
	install -m644 -D "$srcdir"/$pkgname.conf \
		"$pkgdir"/etc/$pkgname.conf || return 1
	install -dDo dbmail "$pkgdir"/var/run/dbmail || return 1
	install -dDo dbmail "$pkgdir"/var/lib/dbmail || return 1
}

auth_ldap() {
	pkgdesc="$pkgname ldap authentication"
	mkdir -p "$subpkgdir"/usr/lib/dbmail
	mv "$pkgdir"/usr/lib/dbmail/libauth_ldap* \
		"$subpkgdir"/usr/lib/dbmail/ || return 1
}

md5sums="4f140751642559395dfe3a6bb2cc9300  dbmail-3.2.3.tar.gz
8ea023b384fd5145d02c4bc3e3935757  dbmail-imapd.initd
e372b5e0e7dcd81fd92337bef75787d3  dbmail-lmtpd.initd
6f432545b19e7188cd466fa2a50d2ee3  dbmail-pop3d.initd
3074c124b974679ba092ad8cb30b851b  dbmail-httpd.initd
f380ec728fb70f1133b15caf54699abb  dbmail-timsieved.initd
490a8d4705d58a41a00486503ad597a5  dbmail.pre-install
549f2073f1c6ac902f783b493c0667d4  dbmail.conf"
sha256sums="fd4d90e3e5ddb0c3fbdaa766d19d2464b5027a8c8d0b0df614418a3aac811832  dbmail-3.2.3.tar.gz
1467d4de9b1a90bdbf97f258e29c2b5dde98895e50201ef238d8f5c7b49d0781  dbmail-imapd.initd
15f89484c1a1e78cc75292662b711de9ee3b6154caaa655b2c20a0856371dc65  dbmail-lmtpd.initd
1341aa3ce86598d896ef5ef9d4ae5eef9b5fffede0df9c594faf46cdb9a95947  dbmail-pop3d.initd
b06b29b165742556191322acaeeda6c108ee21c25479f7f57f8341e430a559db  dbmail-httpd.initd
9f86c821b348ce24fe1f8d1b67761d51d26831b4022783e4f65253d995935911  dbmail-timsieved.initd
da148226dd530694130d7df59d1399c5ca26f3de7a4475c4082c1576f1d5460e  dbmail.pre-install
b73fc15ab36423fe2c4c5a677fb21c706ca51aa9e0a948ca582e8bb27cc8ce67  dbmail.conf"
sha512sums="29cc89830278f2ff28a4221fc81d4ff13cc371fbca7fb51d5376e9243234220b552cb4b6ec035c150e6cfa178435c4f36b9ce132fc02334bc6cdeb1a41c8ed85  dbmail-3.2.3.tar.gz
c1c22a0732b51eec6fbeaa30e13fe15aa752836135b52fdae0ce5539053127b53ad75b3b48cd8475ccfe1db59cbb1ddce9af8e201e722691294dcf8fc7cec30d  dbmail-imapd.initd
114a71f9ab06ad113e31f986eb534f1aa1ecb366954304e9768f2441337fa682fe6cd11af4357577bbc5dc26185891d7d6454baa18e28054306501e3ed9cf347  dbmail-lmtpd.initd
a76d5b4bd57ae4790e45ac4458107badb66e18a923f5bb3ab88e64af6445cffedffedba525945208bbade993f28db252d12c1de7b13a4e149489745e1645660c  dbmail-pop3d.initd
c2780709b188ef745182b87ea7454a65e221ec3222c9c3961cb22e09a6a51d824961939a9568243c93c68d2894547a4f14aab18ec00e9dcdd965f0ab12ec054b  dbmail-httpd.initd
8115d830610bd769ac0169cc6a9d5f961bd80c668baff336dec5296180ea725267542aad70a6286faff081380a3dcd3597df19fd7fb9577d669ee35537c7a198  dbmail-timsieved.initd
e3f5de0fed253b3f9dab8b93cd984a7ed5a7eed3e10472bb9342719b3ed1ec1b0d8c78b87a6c68a787be8f4c94614c88ed1abf457bc524fad43a3f2762761129  dbmail.pre-install
2726eb944043face96fdcbc7210b2e3b9a6d4f0981825dc134a88217935b01f33935b90bb0458534d87e4941d7da3cad279876912a6c7da108b15d684829117f  dbmail.conf"