1 |
patrick 10/01/26 20:43:51 |
2 |
|
3 |
Modified: ChangeLog |
4 |
Added: dovecot-1.2.10-r1.ebuild |
5 |
Removed: dovecot-1.2.10.ebuild |
6 |
Log: |
7 |
Another sieve bump |
8 |
(Portage version: 2.2_rc61/cvs/Linux x86_64) |
9 |
|
10 |
Revision Changes Path |
11 |
1.230 net-mail/dovecot/ChangeLog |
12 |
|
13 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-mail/dovecot/ChangeLog?rev=1.230&view=markup |
14 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-mail/dovecot/ChangeLog?rev=1.230&content-type=text/plain |
15 |
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-mail/dovecot/ChangeLog?r1=1.229&r2=1.230 |
16 |
|
17 |
Index: ChangeLog |
18 |
=================================================================== |
19 |
RCS file: /var/cvsroot/gentoo-x86/net-mail/dovecot/ChangeLog,v |
20 |
retrieving revision 1.229 |
21 |
retrieving revision 1.230 |
22 |
diff -u -r1.229 -r1.230 |
23 |
--- ChangeLog 26 Jan 2010 20:10:36 -0000 1.229 |
24 |
+++ ChangeLog 26 Jan 2010 20:43:51 -0000 1.230 |
25 |
@@ -1,6 +1,12 @@ |
26 |
# ChangeLog for net-mail/dovecot |
27 |
# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 |
28 |
-# $Header: /var/cvsroot/gentoo-x86/net-mail/dovecot/ChangeLog,v 1.229 2010/01/26 20:10:36 patrick Exp $ |
29 |
+# $Header: /var/cvsroot/gentoo-x86/net-mail/dovecot/ChangeLog,v 1.230 2010/01/26 20:43:51 patrick Exp $ |
30 |
+ |
31 |
+*dovecot-1.2.10-r1 (26 Jan 2010) |
32 |
+ |
33 |
+ 26 Jan 2010; Patrick Lauer <patrick@g.o> -dovecot-1.2.10.ebuild, |
34 |
+ +dovecot-1.2.10-r1.ebuild: |
35 |
+ Another sieve bump |
36 |
|
37 |
*dovecot-1.2.10 (26 Jan 2010) |
38 |
|
39 |
|
40 |
|
41 |
|
42 |
1.1 net-mail/dovecot/dovecot-1.2.10-r1.ebuild |
43 |
|
44 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-mail/dovecot/dovecot-1.2.10-r1.ebuild?rev=1.1&view=markup |
45 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-mail/dovecot/dovecot-1.2.10-r1.ebuild?rev=1.1&content-type=text/plain |
46 |
|
47 |
Index: dovecot-1.2.10-r1.ebuild |
48 |
=================================================================== |
49 |
# Copyright 1999-2010 Gentoo Foundation |
50 |
# Distributed under the terms of the GNU General Public License v2 |
51 |
# $Header: /var/cvsroot/gentoo-x86/net-mail/dovecot/dovecot-1.2.10-r1.ebuild,v 1.1 2010/01/26 20:43:51 patrick Exp $ |
52 |
|
53 |
EAPI="2" |
54 |
|
55 |
inherit eutils versionator |
56 |
|
57 |
major_minor="$( get_version_component_range 1-2 )" |
58 |
sieve_version="0.1.15" |
59 |
managesieve_version="0.11.11" |
60 |
SRC_URI="http://dovecot.org/releases/${major_minor}/${P}.tar.gz |
61 |
sieve? ( http://www.rename-it.nl/dovecot/${major_minor}/dovecot-${major_minor}-sieve-${sieve_version}.tar.gz ) |
62 |
managesieve? ( |
63 |
http://www.rename-it.nl/dovecot/${major_minor}/dovecot-1.2.10-managesieve-${managesieve_version}.diff.gz |
64 |
http://www.rename-it.nl/dovecot/${major_minor}/dovecot-${major_minor}-managesieve-${managesieve_version}.tar.gz |
65 |
)" |
66 |
DESCRIPTION="An IMAP and POP3 server written with security primarily in mind" |
67 |
HOMEPAGE="http://www.dovecot.org/" |
68 |
|
69 |
SLOT="0" |
70 |
LICENSE="LGPL-2.1" # MIT too? |
71 |
KEYWORDS="~alpha ~amd64 ~sparc ~x86" |
72 |
|
73 |
IUSE="berkdb bzip2 caps cydir dbox doc ipv6 kerberos ldap +maildir managesieve mbox mysql pam postgres sieve sqlite +ssl suid vpopmail zlib" |
74 |
|
75 |
DEPEND="berkdb? ( sys-libs/db ) |
76 |
caps? ( sys-libs/libcap ) |
77 |
kerberos? ( virtual/krb5 ) |
78 |
ldap? ( net-nds/openldap ) |
79 |
mysql? ( virtual/mysql ) |
80 |
pam? ( virtual/pam ) |
81 |
postgres? ( virtual/postgresql-base ) |
82 |
sqlite? ( dev-db/sqlite ) |
83 |
ssl? ( dev-libs/openssl ) |
84 |
vpopmail? ( net-mail/vpopmail )" |
85 |
|
86 |
RDEPEND="${DEPEND} |
87 |
>=net-mail/mailbase-0.00-r8" |
88 |
|
89 |
pkg_setup() { |
90 |
if use managesieve && ! use sieve; then |
91 |
eerror "managesieve USE flag selected but sieve USE flag unselected" |
92 |
die "USE flag problem" |
93 |
fi |
94 |
|
95 |
if use dbox && ! use maildir; then |
96 |
eerror "dbox USE flag needs maildir USE flag enabled" |
97 |
die "USE flag problem" |
98 |
fi |
99 |
|
100 |
# Add user and group for login process (same as for fedora/redhat) |
101 |
enewgroup dovecot 97 |
102 |
enewuser dovecot 97 -1 /dev/null dovecot |
103 |
# add "mail" group for suid'ing. Better security isolation. |
104 |
if use suid; then |
105 |
enewgroup mail |
106 |
fi |
107 |
} |
108 |
|
109 |
src_prepare() { |
110 |
use managesieve && epatch "${WORKDIR}"/dovecot-1.2.7-managesieve-${managesieve_version}.diff |
111 |
} |
112 |
|
113 |
src_configure() { |
114 |
local conf="" |
115 |
|
116 |
if use postgres || use mysql || use sqlite; then |
117 |
conf="${conf} --with-sql" |
118 |
fi |
119 |
|
120 |
local storages="" |
121 |
for storage in cydir dbox maildir mbox; do |
122 |
use ${storage} && storages="${storage} ${storages}" |
123 |
done |
124 |
[ "${storages}" ] || storages="maildir" |
125 |
|
126 |
econf \ |
127 |
--sysconfdir=/etc/dovecot \ |
128 |
--localstatedir=/var \ |
129 |
--with-moduledir="/usr/$( get_libdir )/dovecot" \ |
130 |
$( use_with berkdb db ) \ |
131 |
$( use_with bzip2 bzlib ) \ |
132 |
$( use_with caps libcap ) \ |
133 |
$( use_with kerberos gssapi ) \ |
134 |
$( use_with ldap ) \ |
135 |
$( use_with mysql ) \ |
136 |
$( use_with pam ) \ |
137 |
$( use_with postgres pgsql ) \ |
138 |
$( use_with sqlite ) \ |
139 |
$( use_with ssl ) \ |
140 |
$( use_with vpopmail ) \ |
141 |
$( use_with zlib ) \ |
142 |
$( use_with ldap) \ |
143 |
--with-storages="${storages}" \ |
144 |
--with-pic \ |
145 |
--enable-header-install \ |
146 |
${conf} |
147 |
|
148 |
if use sieve; then |
149 |
# The sieve plugin needs this file to be build to determine the plugin |
150 |
# directory and the list of libraries to link to. |
151 |
emake dovecot-config || die "emake dovecot-config failed" |
152 |
cd "../dovecot-${major_minor}-sieve-${sieve_version}" |
153 |
econf --with-dovecot="${S}" |
154 |
|
155 |
if use managesieve; then |
156 |
cd "../dovecot-${major_minor}-managesieve-${managesieve_version}" |
157 |
econf --with-dovecot="${S}" --with-dovecot-sieve="../dovecot-${major_minor}-sieve-${sieve_version}" |
158 |
fi |
159 |
fi |
160 |
} |
161 |
|
162 |
src_compile() { |
163 |
emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}" || die "make failed" |
164 |
|
165 |
if use sieve; then |
166 |
cd "../dovecot-${major_minor}-sieve-${sieve_version}" |
167 |
emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}" || die "make failed" |
168 |
|
169 |
if use managesieve; then |
170 |
cd "../dovecot-${major_minor}-managesieve-${managesieve_version}" |
171 |
emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}" || die "make failed" |
172 |
fi |
173 |
fi |
174 |
} |
175 |
|
176 |
src_install () { |
177 |
emake DESTDIR="${D}" install || die "make install failed" |
178 |
|
179 |
# insecure: |
180 |
#use suid && fperms u+s /usr/libexec/dovecot/deliver |
181 |
#better: |
182 |
if use suid;then |
183 |
einfo "Changing perms to allow deliver to be suided" |
184 |
fowners root:mail /usr/libexec/dovecot/deliver |
185 |
fperms 4750 /usr/libexec/dovecot/deliver |
186 |
fi |
187 |
|
188 |
rm -f "${D}"/etc/dovecot/dovecot-{ldap,sql}-example.conf |
189 |
|
190 |
newinitd "${FILESDIR}"/dovecot.init-r2 dovecot |
191 |
|
192 |
rm -rf "${D}"/usr/share/doc/dovecot |
193 |
|
194 |
if use ssl; then |
195 |
sed -i -e 's,^CERTDIR=.*,CERTDIR=\$SSLDIR/dovecot,' \ |
196 |
-e 's,^KEYDIR=.*,KEYDIR=\$SSLDIR/dovecot,' \ |
197 |
-e 's,^CERTFILE=.*,CERTFILE=\$CERTDIR/server.pem,' \ |
198 |
-e 's,^KEYFILE=.*,KEYFILE=\$KEYDIR/server.key,' \ |
199 |
doc/mkcert.sh || die "failed to update SSL settings in mkcert.sh" |
200 |
fi |
201 |
|
202 |
dodoc AUTHORS NEWS README TODO dovecot-example.conf || die "basic dodoc failed" |
203 |
dodoc doc/* || die "dodoc doc/ failed" |
204 |
docinto wiki |
205 |
dodoc doc/wiki/* || die "dodoc doc/wiki/ failed" |
206 |
|
207 |
# Create the dovecot.conf file from the dovecot-example.conf file that |
208 |
# the dovecot folks nicely left for us.... |
209 |
local conf="${D}/etc/dovecot/dovecot.conf" |
210 |
mv "${D}"/etc/dovecot/dovecot-example.conf "${D}"/etc/dovecot/dovecot.conf |
211 |
|
212 |
# .maildir is the Gentoo default, but we need to support mbox to |
213 |
local mail_location="maildir:~/.maildir" |
214 |
if use mbox; then |
215 |
mail_location="mbox:/var/spool/mail/%u:INDEX=/var/dovecot/%u" |
216 |
keepdir /var/dovecot |
217 |
sed -i -e 's|#mail_privileged_group =|mail_privileged_group = mail|' "${conf}" |
218 |
fi |
219 |
sed -i -e \ |
220 |
"s|#mail_location =|mail_location = ${mail_location}|" "${conf}" \ |
221 |
|| die "failed to update mail location settings in dovecot.conf" |
222 |
|
223 |
# We're using pam files (imap and pop3) provided by mailbase |
224 |
if use pam; then |
225 |
sed -i -e '/passdb pam/, /^[ \t]*}/ s|#args = dovecot|args = "\*"|' \ |
226 |
"${conf}" || die "failed to update PAM settings in dovecot.conf" |
227 |
# mailbase does not provide a managesieve pam file |
228 |
use managesieve && dosym imap /etc/pam.d/managesieve |
229 |
fi |
230 |
|
231 |
# Listen on ipv6 and ipv4 |
232 |
if use ipv6; then |
233 |
sed -i -e 's/^#listen = \*/listen = \*, \[::\]/g' "${conf}" \ |
234 |
|| die "failed to update listen settings in dovecot.conf" |
235 |
fi |
236 |
|
237 |
# Update ssl cert locations |
238 |
if use ssl; then |
239 |
sed -i -e 's,^#ssl_cert_file =.*,ssl_cert_file = /etc/ssl/dovecot/server.pem,' \ |
240 |
-e 's,^#ssl_key_file =.*,ssl_key_file = /etc/ssl/dovecot/server.key,' \ |
241 |
"${conf}" || die "failed to update SSL settings in dovecot.conf" |
242 |
fi |
243 |
|
244 |
# Install SQL configuration |
245 |
if use mysql || use postgres; then |
246 |
cp doc/dovecot-sql-example.conf "${D}"/etc/dovecot/dovecot-sql.conf |
247 |
fperms 600 /etc/dovecot/dovecot-sql.conf |
248 |
sed -i -e '/db sql/,/args/ s|=|= /etc/dovecot-sql.conf|' "${conf}" \ |
249 |
|| die "failed to update SQL settings in dovecot-sql.conf" |
250 |
dodoc doc/dovecot-sql-example.conf |
251 |
fi |
252 |
|
253 |
# Install LDAP configuration |
254 |
if use ldap; then |
255 |
cp doc/dovecot-ldap-example.conf "${D}"/etc/dovecot/dovecot-ldap.conf |
256 |
fperms 600 /etc/dovecot/dovecot-ldap.conf |
257 |
sed -i -e '/db ldap/,/args/ s|=|= /etc/dovecot-ldap.conf|' "${conf}" \ |
258 |
|| die "failed to update LDAP settings in dovecot-ldap.conf" |
259 |
dodoc doc/dovecot-ldap-example.conf |
260 |
fi |
261 |
|
262 |
if use sieve; then |
263 |
cd "../dovecot-${major_minor}-sieve-${sieve_version}" |
264 |
emake DESTDIR="${D}" install || die "make install failed (sieve)" |
265 |
|
266 |
if use managesieve; then |
267 |
cd "../dovecot-${major_minor}-managesieve-${managesieve_version}" |
268 |
emake DESTDIR="${D}" install || die "make install failed (managesieve)" |
269 |
fi |
270 |
fi |
271 |
|
272 |
dodir /var/run/dovecot |
273 |
fowners root:root /var/run/dovecot |
274 |
fperms 0755 /var/run/dovecot |
275 |
keepdir /var/run/dovecot/login |
276 |
fowners root:dovecot /var/run/dovecot/login |
277 |
fperms 0750 /var/run/dovecot/login |
278 |
|
279 |
ewarn "If you are upgrading from Dovecot 1.1, read " |
280 |
ewarn " http://wiki.dovecot.org/Upgrading/1.2" |
281 |
if use sieve; then |
282 |
ewarn " http://wiki.dovecot.org/LDA/Sieve/Dovecot#Migration_from_CMUSieve" |
283 |
ewarn " In particular, do not forget to change cmusieve to sieve" |
284 |
fi |
285 |
} |