aboutsummaryrefslogtreecommitdiffstats
path: root/testing/exim/APKBUILD
blob: 45054a9f760e325583938277f8e5937a8a16bd59 (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
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
# Contributor: Łukasz Jendrysik <scadu@yandex.com>
# Contributor: Jesse Young <jlyo@jlyo.org>
# Maintainer: Jesse Young <jlyo@jlyo.org>
pkgname=exim
pkgver=4.86
pkgrel=1
pkgdesc="A Message Transfer Agent"
url="http://www.exim.org/"
arch="all"
license="GPL2"
options="suid"
depends=
pkgusers="mail"
pkggroups="mail"
depends_dev="db-dev pcre-dev openssl-dev libspf2-dev mariadb-dev postgresql-dev sqlite-dev"
makedepends="bash gawk perl $depends_dev"
install="exim.pre-install exim.post-upgrade"
subpackages="$pkgname-cdb $pkgname-dbmdb $pkgname-dnsdb $pkgname-dsearch $pkgname-passwd $pkgname-sqlite $pkgname-mysql $pkgname-postgresql $pkgname-utils $pkgname-scripts $pkgname-doc"
source="ftp://ftp.exim.org/pub/exim/exim4/$pkgname-$pkgver.tar.bz2
	exim.Makefile
	exim.confd
	exim.initd
	exim.logrotate
	exim.pre-install
	exim.post-upgrade"

_builddir="$srcdir"/$pkgname-$pkgver

prepare() {
	cd "$_builddir"
	cp "$srcdir/$pkgname.Makefile" Local/Makefile
	sed	-e 's/^LIBS = -lnsl/LIBS =/g' \
		-e 's/^HAVE_ICONV=yes/#HAVE_ICONV=yes/' \
		-i OS/Makefile-Linux
}

build() {
	cd "$_builddir"
	make makefile || return 1
	make -j1 || return 1
}

package() {
	cd "$_builddir"
	install -m750 -D -g mail -d "$pkgdir"/etc/mail
	make DESTDIR="$pkgdir" INSTALL_ARG="-no_symlink -no_chown exim" install || return 1
	install -D -m644 doc/exim.8 "$pkgdir"/usr/share/man/man8/exim.8
	cd "$pkgdir"/usr/sbin
	mv exim-${pkgver}-* exim
	chmod u+s exim
	for i in mailq rmail rsmtp runq sendmail newaliases; do
		ln -s exim $i
	done
	install -m644 -D "$srcdir"/$pkgname.logrotate "$pkgdir"/etc/logrotate.d/$pkgname
	install -m644 -D "$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname
	install -m755 -D "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname
	install -m750 -D -g mail -d "$pkgdir"/usr/lib/exim
	install -m750 -D -o mail -d "$pkgdir"/var/log/exim
}

scripts() {
	pkgdesc="exim scripts"
	depends="exim perl"
	arch="noarch"
	cd "$_builddir"
	make	DESTDIR="$subpkgdir" \
		INSTALL_ARG="exicyclog exim_checkaccess eximstats exiqgrep exigrep exinext exiqsumm exipick exiwhat convert4r3 convert4r4" \
		install || return 1
	rm -fr "$subpkgdir"/etc
}

utils() {
	pkgdesc="exim utils"
	depends="exim"
	cd "$_builddir"
	make	DESTDIR="$subpkgdir" \
		INSTALL_ARG="exim_dbmbuild exim_dumpdb exim_tidydb exim_fixdb exim_lock" \
		install || return 1
	rm -fr "$subpkgdir"/etc
}

sqlite() {
	pkgdesc="sqlite support for exim"
	depends="exim"
	_inst_lookup sqlite
}

mysql() {
	pkgdesc="mysql support for exim"
	depends="exim"
	_inst_lookup mysql
}

postgresql() {
	pkgdesc="postgresql support for exim"
	depends="exim"
	_inst_lookup pgsql
}

cdb() {
	pkgdesc="cdb support for exim"
	depends="exim"
	_inst_lookup cdb
}

dbmdb() {
	pkgdesc="dbmdb support for exim"
	depends="exim"
	_inst_lookup dbmdb
}

dnsdb() {
	pkgdesc="dnsdb support for exim"
	depends="exim"
	_inst_lookup dnsdb
}

passwd() {
	pkgdesc="passwd support for exim"
	depends="exim"
	_inst_lookup passwd
}

dsearch() {
	pkgdesc="dsearch support for exim"
	depends="exim"
	_inst_lookup dsearch
}

_inst_lookup() {
	install -D -m755 "$_builddir"/build-Linux-*/lookups/$1.so "$subpkgdir"/usr/lib/exim/$1.so
}
md5sums="797f248ef3e0c0e2f178e915f88fc4e9  exim-4.86.tar.bz2
73b2641c77c2ce07d935afe39ebd0084  exim.Makefile
7fac36b4683fe9e2bd1969ebfded4206  exim.confd
6c7ea5b5d180e398f3fb0dd0c5f3b22f  exim.initd
2aeee003b9526472608bdc4194fb95de  exim.logrotate
5d98a55beab23793dfa503995aa29905  exim.pre-install
038f3285d40f49512fdf178758ccbe5b  exim.post-upgrade"
sha256sums="f1ccf2ce2ea51b7fbbf160e7e0e41d24ca401cf44a185128ad99ea04635fc456  exim-4.86.tar.bz2
e522e9fb0753ef4becc32b9f6e476b25643b8232519b1bedaf90034d01fe68e0  exim.Makefile
02ccb013b3f29183969dceb2dc1285cfacc18b1e8a8a052ace7bc85171ea1a27  exim.confd
171171b454d51b861c30c9ce84af8885d79ac0f287799290dfdda53f3a6cbe7e  exim.initd
71aa7865eea47bb65737cf65e01a73054f34d2feab23d5905619ca1c079041d6  exim.logrotate
50dc0ed25acce493f87057530de2ca110eaa218b59cc1bba0f08f881d6660a1a  exim.pre-install
4426e7962f027bcf4808d96ee37f2de148030e42ada6cabddcc05e765ac7f3ec  exim.post-upgrade"
sha512sums="0b90cd1b4d99bbb976336ccf9c2c3375f453a74bb306f1b0215f7ecca80fbda83cf5cc38c502516c2903c5d753f1f559c534fc4f4b1b32ee3300db86de6610ab  exim-4.86.tar.bz2
afd8a7969bcfa7a51fd8012e3f1127b9f00219e09dba4bae95f402083cdc99746a58818cb5943eb601ad5bfbc2ca8e1fd8b8b1bb6015c5b79e02da4bf09c0349  exim.Makefile
dfc5e5e266c8a249728c7924f66223eadadf69e38b7ad3ae41197fcdb545a4c3a835939941dff41a948f7e26cbab9d5f1a8c412d27b87a0596c0f9d4f0e43eec  exim.confd
afcd96eab622c02897d9e0d79dc34aa3f67b0153b1019f6338f3574d8bc59093e791208b6d2785299dd2fc86cab2d5226c1cc2e6b4aca7302914f7d2e06eb901  exim.initd
b5d197c7da4318d2040395fe7eb9046442604a695530fc861594d0cb38e6ad7f5e56ac1204639c18ac93a005f56ea3d8054ac5c823c54c4cc21fd77266080407  exim.logrotate
37464fb55f58db11799df2b0a95cf5d6ef4ad2ca9951d970a5261d59aa008d0db5d3310d33ff6dacddef885d387f6c8482bd1d6025826d1dc4d9afc21af02731  exim.pre-install
dc79ba01166b0ca7bcb94eb55492daeafc5031ce1901d6908b585fd3b3625cb4ebfcb4b11b12ce204e04bbcffb33ea44c8a93f580e22a8ad812909744d6d67dd  exim.post-upgrade"