1 # Contributor: Roberto Alsina <ralsina@kde.org>
5 pkgdesc="The second most popular MTA in the internet"
6 url="http://www.qmail.org"
8 depends=('glibc' 'ipsvd' 'runit' 'checkpassword-pam' 'ucspi-ipc')
16 source=(http://cr.yp.to/software/$pkgname-$pkgver.tar.gz \
18 qmail-1.03-errno.patch \
19 qmail-1.03-msglog.patch \
20 qmtpd-badmailfrom-1.1.patch \
21 qmail-1.03-showctl.patch \
22 qmail-1.03-bind-interface.patch \
24 qmail-1.03-install-path-big-todo.patch \
25 qmail-1.03-autouidgid.patch \
26 qmail-1.03-syncdir.patch \
27 qmail-1.03-pop3d-stat.patch \
28 qmail-1.03-queuevar.patch \
29 big-concurrency.patch \
30 qmail-1.03-qmtpc-mailroutes-1.5.patch \
32 ext_todo-20030105.patch \
33 ext_todo-20020524-add-big-todo.patch \
34 netqmail-1.05-ucspitls-0.3.patch \
35 qmail-1.03-quotas-1.1.patch \
36 qmail-maildir++-universal.patch \
37 qmail-queue-custom-error.patch \
38 qmail-authentication-064.patch \
39 qmail-remote-auth.patch \
40 qmail-1.03-bigdns.patch \
41 qmail-1.03-rfc2821.patch \
42 qmail-1.03-doublebounce-trim.patch \
43 qmail-1.03-spp.patch \
44 http://qmail.jms1.net/patches/qmail-date-localtime.patch \
45 http://www.netmeridian.com/e-huss/queue-fix.tar.gz \
46 http://www.qmail.org/queue-fix-todo.patch \
47 queue-fix-errno.patch \
56 md5sums=('622f65f982e380dbe86e6574f3abcb7c'
57 'f9e69afdf7fe0bc8547c865919b01bb3'
58 '1806b4cc25597e106a9e8e27ac62a03c'
59 '76f2ed581176aa906b507435cc416cf8'
60 '34d59d4e93897790055d562788623b21'
61 '904ec650848677bcbfe6ad1d0f55c5a4'
62 '8bb5e1a76d346a7062e3f57b10df5f85'
63 'ce3d1fadcf441c434479d91455b60adf'
64 '5268d64e0de60eb1bc06abfb0399db78'
65 'f8d8a58273c557960317e30652ad43df'
66 '2e39d7a056cf33e7467029c50d985954'
67 'c3d8d7dc9db4588f8573e07dd59382e8'
68 '2c4ef26ddc2b3614c2972765365883ae'
69 '66fdd0cf5e49f87b5134d076946d0cf3'
70 '821dff356c9dbca644ba3956e86acdcf'
71 '8edda59102180973dd1bb546da7de160'
72 '9ff2f52db53242da0a196bc4fedbae62'
73 'bd8d874604e39d7994408be5b5049bbb'
74 '9543ab0ac2ece0540a822b43edeeec16'
75 '8ef1833aa2b063470099c0c309a529df'
76 'fa77cf624461f30e37c1adc20a7ab651'
77 '88c05425b8c20d748ab85739d8ffeb28'
78 '88333425eb93f87c2567e666cde46d78'
79 'acdb8621767165598baaf7b69136e0e2'
80 'e1d696cd2762b525c6f7ba1d302b97c5'
81 'a554edeafd43df65f2ce868e73b28d38'
82 '9f726c6e7f846424c233fed0587ab530'
83 '38890e2abc26d2fa0a2c8180b5089d69'
84 'd566e8bd99b33efee0194e855b8d6995'
85 '43f915c104024e6f33a5b3ff52dfb75b'
86 'cbebb217b1b3b32f20995f2c869f6121'
87 'cb4fef6f8d2003661632a8395f8430f3'
88 '8252e1212c97aab8da6640992ff92661'
89 'fb9e338b59358ab85fe9691588c83ab4'
90 '306b60c140a8a8104b397d31fa5e455f'
91 '254ae5d0d8fe333bb76be470e9b9acd3'
92 'fa20700c5b781f874bfa18afc4bbcc64'
93 '84e67354be30817933976df76a7e66ff')
97 install -d $startdir/pkg/usr/bin $startdir/pkg/usr/sbin
99 ###############################################
101 ###############################################
103 cd $startdir/src/queue-fix-1.4
104 patch -p1 < ../queue-fix-todo.patch || return 1
105 patch -p1 -R < ../queue-fix-errno.patch || return 1
107 install -m 0755 queue-fix $startdir/pkg/usr/bin
109 ###############################################
111 ###############################################
113 cd $startdir/src/$pkgname-$pkgver
115 # Patch to fix compilation on modern Linux
116 patch -p1 < ../qmail-1.03-errno.patch || return 1
117 # If you enable this one, a copy of every mail will be
118 # sent to the msglog account
119 #patch -p1 < ../qmail-1.03-msglog.patch || return 1
120 patch -p1 < ../qmtpd-badmailfrom-1.1.patch || return 1
121 patch -p1 < ../qmail-1.03-showctl.patch || return 1
122 patch -p1 < ../qmail-1.03-bind-interface.patch || return 1
123 patch -p1 < ../big-todo.patch || return 1
124 patch -p1 < ../qmail-1.03-install-path-big-todo.patch || return 1
125 patch -p1 < ../qmail-1.03-autouidgid.patch || return 1
126 patch -p1 < ../qmail-1.03-syncdir.patch || return 1
127 patch -p1 < ../qmail-1.03-pop3d-stat.patch || return 1
128 patch -p1 < ../qmail-1.03-queuevar.patch || return 1
129 patch -p1 < ../big-concurrency.patch || return 1
130 patch -p1 < ../qmail-1.03-qmtpc-mailroutes-1.5.patch || return 1
131 patch -p1 < ../qmail-0.0.0.0.patch || return 1
132 patch -p1 < ../ext_todo-20030105.patch || return 1
133 patch -p1 < ../ext_todo-20020524-add-big-todo.patch || return 1
134 patch -p1 < ../netqmail-1.05-ucspitls-0.3.patch || return 1
135 patch -p1 < ../qmail-1.03-quotas-1.1.patch || return 1
136 patch -p1 < ../qmail-maildir++-universal.patch || return 1
137 patch -p1 < ../qmail-queue-custom-error.patch || return 1
138 patch -p1 < ../qmail-authentication-064.patch || return 1
139 patch -p1 < ../qmail-remote-auth.patch || return 1
140 patch -p1 < ../qmail-1.03-bigdns.patch || return 1
141 patch -p1 < ../qmail-1.03-rfc2821.patch || return 1
142 patch -p1 < ../qmail-1.03-doublebounce-trim.patch || return 1
143 patch -p1 < ../qmail-1.03-spp.patch || return 1
144 # Changes dates in headers to localtime
145 patch -p1 < ../qmail-date-localtime.patch || return 1
148 let spawnlimit='(fds-6)/2'
149 echo $spawnlimit >conf-spawn
155 ./makelib libsyncdir.a syncdir.o
159 for BIN in bouncesaying \
195 install -m 0755 $BIN $startdir/pkg/usr/bin
198 for BIN in qmail-clean \
208 install -m 0711 $BIN $startdir/pkg/usr/bin
211 for BIN in qmail-lspawn \
217 install -m 0700 $BIN $startdir/pkg/usr/bin
220 install -m 4711 qmail-queue $startdir/pkg/usr/bin
222 install -m 0755 sendmail $startdir/pkg/usr/sbin
224 install -d $startdir/pkg/etc/qmail/{alias,control,users,owners,plugins}
225 install -d $startdir/pkg/var/qmail/
227 # Set up all the symlinks so regular qmail users find their stuff
228 ln -s /etc/qmail/{alias,control,users,owners,plugins} $startdir/pkg/var/qmail/
229 ln -s /usr/bin $startdir/pkg/var/qmail/bin
230 ln -s /usr/man $startdir/pkg/var/qmail/man
233 for N in 0 1 3 5 7 8 9
235 install -d $startdir/pkg/usr/man/man$N
236 install -m 0644 *.$N $startdir/pkg/usr/man/man$N
239 # Shell script helper
241 install -d $startdir/pkg/usr/share/qmail
242 install -m 644 ../run-functions $startdir/pkg/usr/share/qmail
245 touch $startdir/pkg/etc/qmail/control/smtpplugins
249 install -d $startdir/pkg/etc/sv
250 cd $startdir/src/services
251 cp -Rv * $startdir/pkg/etc/sv