1 |
patrick 13/08/26 11:17:47 |
2 |
|
3 |
Modified: ChangeLog |
4 |
Added: courier-0.71.ebuild |
5 |
Log: |
6 |
Bump |
7 |
|
8 |
(Portage version: 2.2.1/cvs/Linux x86_64, unsigned Manifest commit) |
9 |
|
10 |
Revision Changes Path |
11 |
1.165 mail-mta/courier/ChangeLog |
12 |
|
13 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/mail-mta/courier/ChangeLog?rev=1.165&view=markup |
14 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/mail-mta/courier/ChangeLog?rev=1.165&content-type=text/plain |
15 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/mail-mta/courier/ChangeLog?r1=1.164&r2=1.165 |
16 |
|
17 |
Index: ChangeLog |
18 |
=================================================================== |
19 |
RCS file: /var/cvsroot/gentoo-x86/mail-mta/courier/ChangeLog,v |
20 |
retrieving revision 1.164 |
21 |
retrieving revision 1.165 |
22 |
diff -u -r1.164 -r1.165 |
23 |
--- ChangeLog 15 Jun 2013 22:29:38 -0000 1.164 |
24 |
+++ ChangeLog 26 Aug 2013 11:17:46 -0000 1.165 |
25 |
@@ -1,6 +1,11 @@ |
26 |
# ChangeLog for mail-mta/courier |
27 |
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 |
28 |
-# $Header: /var/cvsroot/gentoo-x86/mail-mta/courier/ChangeLog,v 1.164 2013/06/15 22:29:38 vincent Exp $ |
29 |
+# $Header: /var/cvsroot/gentoo-x86/mail-mta/courier/ChangeLog,v 1.165 2013/08/26 11:17:46 patrick Exp $ |
30 |
+ |
31 |
+*courier-0.71 (26 Aug 2013) |
32 |
+ |
33 |
+ 26 Aug 2013; Patrick Lauer <patrick@g.o> +courier-0.71.ebuild: |
34 |
+ Bump |
35 |
|
36 |
15 Jun 2013; Vicente Olivert Riera <vincent@g.o> courier-0.69.0.ebuild: |
37 |
fixing collitions with two qmail related packages: bug #441774 |
38 |
|
39 |
|
40 |
|
41 |
1.1 mail-mta/courier/courier-0.71.ebuild |
42 |
|
43 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/mail-mta/courier/courier-0.71.ebuild?rev=1.1&view=markup |
44 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/mail-mta/courier/courier-0.71.ebuild?rev=1.1&content-type=text/plain |
45 |
|
46 |
Index: courier-0.71.ebuild |
47 |
=================================================================== |
48 |
# Copyright 1999-2013 Gentoo Foundation |
49 |
# Distributed under the terms of the GNU General Public License v2 |
50 |
# $Header: /var/cvsroot/gentoo-x86/mail-mta/courier/courier-0.71.ebuild,v 1.1 2013/08/26 11:17:46 patrick Exp $ |
51 |
|
52 |
inherit eutils flag-o-matic multilib |
53 |
|
54 |
DESCRIPTION="An MTA designed specifically for maildirs" |
55 |
SRC_URI="mirror://sourceforge/courier/${P}.tar.bz2" |
56 |
HOMEPAGE="http://www.courier-mta.org/" |
57 |
SLOT="0" |
58 |
LICENSE="GPL-2" |
59 |
# not in keywords due to missing dependencies: ~arm ~s390 ~ppc64 |
60 |
KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~sparc ~x86" |
61 |
IUSE="postgres ldap mysql pam nls ipv6 spell fax crypt norewrite \ |
62 |
fam web webmail gnutls" |
63 |
|
64 |
DEPEND=" |
65 |
>=net-libs/courier-authlib-0.61.0 |
66 |
!gnutls? ( >=dev-libs/openssl-0.9.6 ) |
67 |
gnutls? ( net-libs/gnutls ) |
68 |
>=sys-libs/gdbm-1.8.0 |
69 |
dev-libs/libpcre |
70 |
app-misc/mime-types |
71 |
fax? ( >=media-libs/netpbm-9.12 app-text/ghostscript-gpl >=net-dialup/mgetty-1.1.28 ) |
72 |
pam? ( virtual/pam ) |
73 |
mysql? ( virtual/mysql ) |
74 |
ldap? ( >=net-nds/openldap-1.2.11 ) |
75 |
postgres? ( dev-db/postgresql-base ) |
76 |
spell? ( app-text/aspell ) |
77 |
fam? ( virtual/fam ) |
78 |
!mail-filter/maildrop |
79 |
!mail-mta/esmtp |
80 |
!mail-mta/exim |
81 |
!mail-mta/mini-qmail |
82 |
!mail-mta/msmtp |
83 |
!mail-mta/netqmail |
84 |
!mail-mta/nullmailer |
85 |
!mail-mta/postfix |
86 |
!mail-mta/qmail-ldap |
87 |
!mail-mta/sendmail |
88 |
!mail-mta/ssmtp |
89 |
!mail-mta/opensmtpd |
90 |
" |
91 |
|
92 |
RDEPEND="${DEPEND} |
93 |
dev-lang/perl |
94 |
sys-process/procps" |
95 |
|
96 |
# get rid of old style virtual/imapd - bug 350792 |
97 |
# all blockers really needed? |
98 |
RDEPEND="${RDEPEND} |
99 |
!net-mail/bincimap |
100 |
!net-mail/courier-imap |
101 |
!net-mail/cyrus-imapd |
102 |
!net-mail/uw-imap" |
103 |
|
104 |
PDEPEND="pam? ( net-mail/mailbase ) |
105 |
crypt? ( >=app-crypt/gnupg-1.0.4 )" |
106 |
|
107 |
src_unpack() { |
108 |
unpack ${A} |
109 |
cd "${S}" |
110 |
use norewrite && epatch "${FILESDIR}/norewrite.patch" |
111 |
} |
112 |
|
113 |
src_compile() { |
114 |
filter-flags '-fomit-frame-pointer' |
115 |
|
116 |
local myconf |
117 |
myconf="" |
118 |
|
119 |
use ldap && myconf="${myconf} --with-ldapconfig=/etc/courier/maildropldap.conf" |
120 |
|
121 |
econf ${myconf} \ |
122 |
$(use_with fam) \ |
123 |
$(use_with ipv6) \ |
124 |
$(use_with spell ispell) \ |
125 |
$(use_with ldap ldapaliasd) \ |
126 |
$(use_enable ldap maildroldap) \ |
127 |
$(use_with gnutls) \ |
128 |
--enable-mimetypes=/etc/mime.types \ |
129 |
--prefix=/usr \ |
130 |
--disable-root-check \ |
131 |
--mandir=/usr/share/man \ |
132 |
--sysconfdir=/etc/courier \ |
133 |
--libexecdir=/usr/$(get_libdir)/courier \ |
134 |
--datadir=/usr/share/courier \ |
135 |
--sharedstatedir=/var/lib/courier/com \ |
136 |
--localstatedir=/var/lib/courier \ |
137 |
--with-piddir=/var/run/courier \ |
138 |
--with-authdaemonvar=/var/lib/courier/authdaemon \ |
139 |
--with-mailuser=mail \ |
140 |
--with-mailgroup=mail \ |
141 |
--with-paranoid-smtpext \ |
142 |
--with-db=gdbm \ |
143 |
--disable-autorenamesent \ |
144 |
--cache-file="${S}/configuring.cache" \ |
145 |
--host="${CHOST}" debug=true || die "./configure" |
146 |
sed -e'/^install-perms-local:/a\ sed -e\"s|^|'"${D}"'|g\" -i permissions.dat' -i Makefile |
147 |
emake || die "Compile problem" |
148 |
} |
149 |
|
150 |
etc_courier() { |
151 |
# Import existing /etc/courier/file if it exists. |
152 |
# Add option only if it was not already set or even commented out |
153 |
file="${1}" ; word="`echo \"${2}\" | sed -e\"s|=.*$||\" -e\"s|^.*opt ||\"`" |
154 |
[ ! -e "${D}/etc/courier/${file}" ] && [ -e "/etc/courier/${file}" ] && \ |
155 |
cp "/etc/courier/${file}" "${D}/etc/courier/${file}" |
156 |
grep -q "${word}" "${D}/etc/courier/${file}" || \ |
157 |
echo "${2}" >> "${D}/etc/courier/${file}" |
158 |
} |
159 |
|
160 |
etc_courier_chg() { |
161 |
file="${1}" ; key="${2}" ; value="${3}" ; section="${4}" |
162 |
[ -z "${section}" ] && section="${2}" |
163 |
grep -q "${key}" "${file}" && elog "Changing ${file}: ${key} to ${value}" |
164 |
sed -i -e"/\#\#NAME: ${section}/,+30 s|${key}=.*|${key}=\"${value}\"|g" ${file} |
165 |
} |
166 |
|
167 |
src_install() { |
168 |
local f |
169 |
diropts -o mail -g mail |
170 |
keepdir /var/lib/courier/tmp |
171 |
keepdir /var/lib/courier/msgs |
172 |
make install DESTDIR="${D}" || die "install" |
173 |
make install-configure || die "install-configure" |
174 |
|
175 |
# Get rid of files we dont want |
176 |
if ! use webmail ; then |
177 |
rm -rf "${D}/usr/$(get_libdir)/courier/courier/webmail" \ |
178 |
"${D}/usr/$(get_libdir)/courier/courier/sqwebmaild" \ |
179 |
"${D}/usr/share/courier/sqwebmail/" \ |
180 |
"${D}/usr/sbin/webmaild" \ |
181 |
"${D}/usr/sbin/webgpg" \ |
182 |
"${D}/etc/courier/webmail.authpam" \ |
183 |
"${D}/var/lib/courier/webmail-logincache" \ |
184 |
"${D}"/etc/courier/sqwebmaild* |
185 |
fi |
186 |
|
187 |
if ! use web ; then |
188 |
rm -rf "${D}/usr/share/courier/courierwebadmin/" \ |
189 |
"${D}/etc/courier/webadmin" |
190 |
fi |
191 |
|
192 |
for dir2keep in $(cd "${D}" && find ./var/lib/courier -type d) ; do |
193 |
keepdir "$dir2keep" || die "failed running keepdir: $dir2keep" |
194 |
done |
195 |
|
196 |
newinitd "${FILESDIR}/courier-init-r4" "courier" |
197 |
use fam || sed -i -e's|^.*use famd$||g' "${D}/etc/init.d/courier" |
198 |
|
199 |
cd "${D}/etc/courier" |
200 |
if use webmail ; then |
201 |
insinto /etc/courier |
202 |
newins "${FILESDIR}/apache-sqwebmail.inc" apache-sqwebmail.inc |
203 |
fi |
204 |
|
205 |
for f in *.dist ; do cp "${f}" "${f%%.dist}" ; done |
206 |
if use ldap ; then |
207 |
[ -e ldapaliasrc ] && ( chown root:0 ldapaliasrc ; chmod 400 ldapaliasrc ) |
208 |
else |
209 |
rm -f ldapaliasrc |
210 |
fi |
211 |
|
212 |
( [ -e /etc/courier/sizelimit ] && cat /etc/courier/sizelimit || echo 0 ) \ |
213 |
> "${D}/etc/courier/sizelimit" |
214 |
etc_courier maildroprc "" |
215 |
etc_courier esmtproutes "" |
216 |
etc_courier backuprelay "" |
217 |
etc_courier locallowercase "" |
218 |
etc_courier bofh "opt BOFHBADMIME=accept" |
219 |
etc_courier bofh "opt BOFHSPFTRUSTME=1" |
220 |
etc_courier bofh "opt BOFHSPFHELO=pass,neutral,unknown,none,error,softfail,fail" |
221 |
etc_courier bofh "opt BOFHSPFHELO=pass,neutral,unknown,none" |
222 |
etc_courier bofh "opt BOFHSPFFROM=all" |
223 |
etc_courier bofh "opt BOFHSPFMAILFROM=all" |
224 |
etc_courier bofh "#opt BOFHSPFHARDERROR=fail" |
225 |
etc_courier esmtpd "BOFHBADMIME=accept" |
226 |
etc_courier esmtpd-ssl "BOFHBADMIME=accept" |
227 |
etc_courier esmtpd-msa "BOFHBADMIME=accept" |
228 |
|
229 |
use fam && etc_courier_chg imapd IMAP_CAPABILITY "IMAP4rev1 UIDPLUS CHILDREN NAMESPACE THREAD=ORDEREDSUBJECT THREAD=REFERENCES SORT QUOTA AUTH=CRAM-MD5 AUTH=CRAM-SHA1 AUTH=CRAM-SHA256 IDLE" |
230 |
use fam || etc_courier_chg imapd IMAP_CAPABILITY "IMAP4rev1 UIDPLUS CHILDREN NAMESPACE THREAD=ORDEREDSUBJECT THREAD=REFERENCES SORT QUOTA AUTH=CRAM-MD5 AUTH=CRAM-SHA1 AUTH=CRAM-SHA256" |
231 |
|
232 |
# Fix for a sandbox violation on subsequential merges |
233 |
# - ticho@g.o, 2005-07-10 |
234 |
dosym /usr/share/courier/pop3d /usr/sbin/courier-pop3d |
235 |
dosym /usr/share/courier/pop3d-ssl /usr/sbin/courier-pop3d-ssl |
236 |
dosym /usr/share/courier/imapd /usr/sbin/courier-imapd |
237 |
dosym /usr/share/courier/imapd-ssl /usr/sbin/courier-imapd-ssl |
238 |
|
239 |
cd "${S}" |
240 |
cp imap/README README.imap |
241 |
use nls && cp unicode/README README.unicode |
242 |
dodoc AUTHORS BENCHMARKS COPYING* ChangeLog* INSTALL NEWS README* TODO courier/doc/*.txt |
243 |
dodoc tcpd/README.couriertls |
244 |
mv "${D}/usr/share/courier/htmldoc" "${D}/usr/share/doc/${PF}/html" |
245 |
|
246 |
if use webmail ; then |
247 |
insinto /usr/$(get_libdir)/courier/courier |
248 |
insopts -m 755 -o mail -g mail |
249 |
doins "${S}/courier/webmaild" |
250 |
fi |
251 |
|
252 |
if use web ; then |
253 |
insinto /etc/courier/webadmin |
254 |
insopts -m 400 -o mail -g mail |
255 |
doins "${FILESDIR}/password.dist" |
256 |
fi |
257 |
|
258 |
# avoid name collisions in /usr/sbin, make webadmin match |
259 |
cd "${D}/usr/sbin" |
260 |
for f in imapd imapd-ssl pop3d pop3d-ssl ; do mv "${f}" "courier-${f}" ; done |
261 |
if use web ; then |
262 |
sed -i -e 's:\$sbindir\/imapd:\$sbindir\/courier-imapd:g' \ |
263 |
-e 's:\$sbindir\/imapd-ssl:\$sbindir\/courier-imapd-ssl:g' \ |
264 |
"${D}/usr/share/courier/courierwebadmin/admin-40imap.pl" \ |
265 |
|| ewarn "failed to fix webadmin" |
266 |
sed -i -e 's:\$sbindir\/pop3d:\$sbindir\/courier-pop3d:g' \ |
267 |
-e 's:\$sbindir\/pop3d-ssl:\$sbindir\/courier-pop3d-ssl:g' \ |
268 |
"${D}/usr/share/courier/courierwebadmin/admin-45pop3.pl" \ |
269 |
|| ewarn "failed to fix webadmin" |
270 |
fi |
271 |
|
272 |
# users should be able to send mail. Could be restricted with suictl. |
273 |
chmod u+s "${D}/usr/bin/sendmail" |
274 |
|
275 |
dosym /usr/bin/sendmail /usr/sbin/sendmail |
276 |
} |
277 |
|
278 |
src_test() { |
279 |
if [ `whoami` != 'root' ]; then |
280 |
emake -j1 check || die "Make check failed." |
281 |
else |
282 |
einfo "make check skipped, can't run as root." |
283 |
einfo "You can enable it with FEATURES=\"userpriv\"" |
284 |
fi |
285 |
} |
286 |
|
287 |
pkg_postinst() { |
288 |
use fam && elog "fam daemon is needed for courier-imapd" \ |
289 |
|| ewarn "courier was built without fam support" |
290 |
} |
291 |
|
292 |
pkg_config() { |
293 |
mailhost="$(hostname)" |
294 |
export mailhost |
295 |
|
296 |
domainname="$(domainname)" |
297 |
if [ "x$domainname" = "x(none)" ] ; then |
298 |
domainname="$(echo ${mailhost} | sed -e "s/[^\.]*\.\(.*\)/\1/")" |
299 |
fi |
300 |
export domainname |
301 |
|
302 |
if [ "${ROOT}" = "/" ] ; then |
303 |
file="${ROOT}/etc/courier/locals" |
304 |
if [ ! -f "${file}" ] ; then |
305 |
echo "localhost" > "${file}"; |
306 |
echo "${domainname}" >> "${file}"; |
307 |
fi |
308 |
file="${ROOT}/etc/courier/esmtpacceptmailfor.dir/${domainname}" |
309 |
if [ ! -f "${file}" ] ; then |
310 |
echo "${domainname}" > "${file}" |
311 |
/usr/sbin/makeacceptmailfor |
312 |
fi |
313 |
|
314 |
file="${ROOT}/etc/courier/smtpaccess/${domainname}" |
315 |
if [ ! -f "${file}" ] |
316 |
then |
317 |
netstat -nr | grep "^[1-9]" | while read network gateway netmask rest |
318 |
do |
319 |
i=1 |
320 |
net="" |
321 |
TIFS="${IFS}" |
322 |
IFS="." |
323 |
for o in "${netmask}" |
324 |
do |
325 |
if [ "${o}" == "255" ] |
326 |
then |
327 |
[ "_${net}" == "_" ] || net="${net}." |
328 |
t="$(echo "${network}" | cut -d " " -f ${i})" |
329 |
net="${net}${t}" |
330 |
fi |
331 |
i="$((${i} + 1))" |
332 |
done |
333 |
IFS="${TIFS}" |
334 |
echo "doing configuration - relay control for the network ${net} !" |
335 |
echo "${net} allow,RELAYCLIENT" >> ${file} |
336 |
done |
337 |
/usr/sbin/makesmtpaccess |
338 |
fi |
339 |
fi |
340 |
|
341 |
echo "creating cert for esmtpd-ssl:" |
342 |
/usr/sbin/mkesmtpdcert |
343 |
echo "creating cert for imapd-ssl:" |
344 |
/usr/sbin/mkpop3dcert |
345 |
echo "creating cert for pop3d-ssl:" |
346 |
/usr/sbin/mkimapdcert |
347 |
} |