1 |
wschlich 08/02/23 11:43:25 |
2 |
|
3 |
Modified: ChangeLog |
4 |
Added: dovecot-1.1_rc1.ebuild |
5 |
Log: |
6 |
version bump |
7 |
(Portage version: 2.1.4) |
8 |
|
9 |
Revision Changes Path |
10 |
1.144 net-mail/dovecot/ChangeLog |
11 |
|
12 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-mail/dovecot/ChangeLog?rev=1.144&view=markup |
13 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-mail/dovecot/ChangeLog?rev=1.144&content-type=text/plain |
14 |
diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-mail/dovecot/ChangeLog?r1=1.143&r2=1.144 |
15 |
|
16 |
Index: ChangeLog |
17 |
=================================================================== |
18 |
RCS file: /var/cvsroot/gentoo-x86/net-mail/dovecot/ChangeLog,v |
19 |
retrieving revision 1.143 |
20 |
retrieving revision 1.144 |
21 |
diff -u -r1.143 -r1.144 |
22 |
--- ChangeLog 17 Feb 2008 16:32:27 -0000 1.143 |
23 |
+++ ChangeLog 23 Feb 2008 11:43:24 -0000 1.144 |
24 |
@@ -1,6 +1,12 @@ |
25 |
# ChangeLog for net-mail/dovecot |
26 |
# Copyright 2000-2008 Gentoo Foundation; Distributed under the GPL v2 |
27 |
-# $Header: /var/cvsroot/gentoo-x86/net-mail/dovecot/ChangeLog,v 1.143 2008/02/17 16:32:27 wschlich Exp $ |
28 |
+# $Header: /var/cvsroot/gentoo-x86/net-mail/dovecot/ChangeLog,v 1.144 2008/02/23 11:43:24 wschlich Exp $ |
29 |
+ |
30 |
+*dovecot-1.1_rc1 (22 Feb 2008) |
31 |
+ |
32 |
+ 22 Feb 2008; Wolfram Schlich <wschlich@g.o> |
33 |
+ +dovecot-1.1_rc1.ebuild: |
34 |
+ version bump |
35 |
|
36 |
*dovecot-1.1_beta16 (17 Feb 2008) |
37 |
|
38 |
|
39 |
|
40 |
|
41 |
1.1 net-mail/dovecot/dovecot-1.1_rc1.ebuild |
42 |
|
43 |
file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-mail/dovecot/dovecot-1.1_rc1.ebuild?rev=1.1&view=markup |
44 |
plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-mail/dovecot/dovecot-1.1_rc1.ebuild?rev=1.1&content-type=text/plain |
45 |
|
46 |
Index: dovecot-1.1_rc1.ebuild |
47 |
=================================================================== |
48 |
# Copyright 1999-2008 Gentoo Foundation |
49 |
# Distributed under the terms of the GNU General Public License v2 |
50 |
# $Header: /var/cvsroot/gentoo-x86/net-mail/dovecot/dovecot-1.1_rc1.ebuild,v 1.1 2008/02/23 11:43:24 wschlich Exp $ |
51 |
|
52 |
inherit autotools eutils ssl-cert versionator |
53 |
|
54 |
MY_P="${P/_/.}" |
55 |
MY_PV12=$(get_version_component_range 1-2 ${PV}) |
56 |
S="${WORKDIR}/${MY_P}" |
57 |
SIEVE="dovecot-sieve-1.1.4" |
58 |
SIEVE_S="${WORKDIR}/${SIEVE}" |
59 |
MANAGESIEVE="managesieve-0.10.0" |
60 |
MANAGESIEVE_S="${WORKDIR}/${PN}-${MY_PV12}-${MANAGESIEVE}" |
61 |
|
62 |
SRC_URI="http://dovecot.org/releases/${MY_PV12}/rc/${MY_P}.tar.gz |
63 |
sieve? ( http://dovecot.org/releases/sieve/${SIEVE}.tar.gz ) |
64 |
managesieve? ( http://www.rename-it.nl/${PN}/${MY_PV12}/${MY_P}-${MANAGESIEVE}.diff.gz |
65 |
http://www.rename-it.nl/${PN}/${MY_PV12}/${PN}-${MY_PV12}-${MANAGESIEVE}.tar.gz )" |
66 |
|
67 |
DESCRIPTION="An IMAP and POP3 server written with security primarily in mind" |
68 |
HOMEPAGE="http://www.dovecot.org/" |
69 |
|
70 |
SLOT="0" |
71 |
LICENSE="LGPL-2.1" |
72 |
KEYWORDS="-* ~alpha ~amd64 ~ppc ~sparc ~x86 ~x86-fbsd" |
73 |
|
74 |
IUSE="debug doc ipv6 kerberos ldap managesieve mbox mysql pop3d pam postgres sieve ssl suid vpopmail" |
75 |
|
76 |
# Developer documentation, controlled by the doc USE flag |
77 |
DEVDOCS="auth-protocol index multiaccess securecoding" |
78 |
|
79 |
DEPEND=">=sys-apps/sed-4 |
80 |
kerberos? ( virtual/krb5 ) |
81 |
ldap? ( net-nds/openldap ) |
82 |
pam? ( virtual/pam ) |
83 |
ssl? ( dev-libs/openssl ) |
84 |
postgres? ( dev-db/postgresql ) |
85 |
mysql? ( virtual/mysql ) |
86 |
vpopmail? ( net-mail/vpopmail )" |
87 |
|
88 |
RDEPEND="${DEPEND} |
89 |
>=net-mail/mailbase-0.00-r8" |
90 |
|
91 |
src_unpack() { |
92 |
unpack ${A} |
93 |
cd "${S}" |
94 |
if use managesieve; then |
95 |
epatch "${WORKDIR}"/${MY_P}-${MANAGESIEVE}.diff |
96 |
eautoreconf |
97 |
fi |
98 |
} |
99 |
|
100 |
pkg_setup() { |
101 |
if ! use sieve && use managesieve; then |
102 |
eerror "managesieve USE flag selected but sieve USE flag unselected" |
103 |
die "USE flag problem" |
104 |
fi |
105 |
# Add user and group for login process (same as for fedora/redhat) |
106 |
enewgroup dovecot 97 |
107 |
enewuser dovecot 97 -1 /dev/null dovecot |
108 |
} |
109 |
|
110 |
src_compile() { |
111 |
local myconf= |
112 |
use ssl && myconf="${myconf} --with-ssl=openssl" \ |
113 |
|| myconf="${myconf} --without-ssl" |
114 |
econf \ |
115 |
--localstatedir=/var \ |
116 |
--sysconfdir=/etc/dovecot \ |
117 |
--enable-header-install \ |
118 |
--with-ioloop=best \ |
119 |
--with-poll=best \ |
120 |
$(use_enable debug) \ |
121 |
$(use_enable ipv6) \ |
122 |
$(use_with kerberos gssapi) \ |
123 |
$(use_with ldap) \ |
124 |
$(use_with mysql) \ |
125 |
$(use_with pam) \ |
126 |
$(use_with pop3d) \ |
127 |
$(use_with postgres pgsql) \ |
128 |
$(use_with vpopmail) \ |
129 |
${myconf} \ |
130 |
|| die "configure failed" |
131 |
emake || die "make failed" |
132 |
|
133 |
if use sieve; then |
134 |
einfo "Building sieve" |
135 |
cd "${SIEVE_S}" |
136 |
econf --with-dovecot="${S}" || die "configure failed (sieve)" |
137 |
emake || die "make failed (sieve)" |
138 |
fi |
139 |
|
140 |
if use managesieve; then |
141 |
einfo "Building managesieve" |
142 |
cd "${MANAGESIEVE_S}" |
143 |
econf --with-dovecot="${S}" --with-dovecot-sieve="${SIEVE_S}" \ |
144 |
|| die "configure failed (managesieve)" |
145 |
emake || die "make failed (managesieve)" |
146 |
fi |
147 |
} |
148 |
|
149 |
src_install () { |
150 |
make DESTDIR="${D}" install || die "make install failed" |
151 |
use suid && fperms u+s /usr/libexec/dovecot/deliver |
152 |
|
153 |
rm -f "${D}"/etc/dovecot/dovecot-{ldap,sql}-example.conf |
154 |
|
155 |
newinitd "${FILESDIR}"/dovecot.init dovecot |
156 |
|
157 |
# Documentation |
158 |
rm -rf "${D}"/usr/share/doc/dovecot |
159 |
dodoc AUTHORS NEWS README TODO dovecot-example.conf |
160 |
use managesieve && newdoc ${MANAGESIEVE_S}/README README.managesieve |
161 |
if use doc; then |
162 |
dodoc doc/*.txt |
163 |
else |
164 |
local x= n= |
165 |
for x in doc/*.txt; do |
166 |
n=$(basename "${x}" .txt) |
167 |
[[ " ${DEVDOCS} " != *" ${n} "* ]] && dodoc "${x}" |
168 |
done |
169 |
fi |
170 |
|
171 |
# Create the dovecot.conf file from the dovecot-example.conf file that |
172 |
# the dovecot folks nicely left for us.... |
173 |
local conf="${D}/etc/dovecot/dovecot.conf" |
174 |
mv "${D}"/etc/dovecot/dovecot-example.conf "${D}"/etc/dovecot/dovecot.conf |
175 |
|
176 |
# .maildir is the Gentoo default, but we need to support mbox to |
177 |
local mail_location="maildir:~/.maildir" |
178 |
if use mbox; then |
179 |
mail_location="mbox:/var/spool/mail/%u:INDEX=/var/dovecot/%u" |
180 |
keepdir /var/dovecot |
181 |
sed -i -e 's|#mail_extra_groups =|mail_extra_groups = mail|' "${conf}" |
182 |
fi |
183 |
sed -i -e \ |
184 |
"s|#mail_location =|mail_location = ${mail_location}|" "${conf}" \ |
185 |
|| die "failed to update mail location settings in dovecot.conf" |
186 |
|
187 |
# We're using pam files (imap and pop3) provided by mailbase |
188 |
if use pam; then |
189 |
sed -i -e '/passdb pam/, /^[ \t]*}/ s|#args = dovecot|args = "\*"|' \ |
190 |
"${conf}" || die "failed to update PAM settings in dovecot.conf" |
191 |
fi |
192 |
|
193 |
# Listen on ipv6 and ipv4 |
194 |
if use ipv6; then |
195 |
sed -i -e 's/^#listen = \*/listen = \[::\]/g' "${conf}" \ |
196 |
|| die "failed to update listen settings in dovecot.conf" |
197 |
fi |
198 |
|
199 |
# Update ssl cert locations |
200 |
if use ssl; then |
201 |
sed -i -e 's,^#ssl_cert_file =.*,ssl_cert_file = /etc/ssl/dovecot/server.pem,' \ |
202 |
-e 's,^#ssl_key_file =.*,ssl_key_file = /etc/ssl/dovecot/server.key,' \ |
203 |
"${conf}" || die "failed to update SSL settings in dovecot.conf" |
204 |
fi |
205 |
|
206 |
# Install SQL configuration |
207 |
if use mysql || use postgres; then |
208 |
cp doc/dovecot-sql-example.conf "${D}"/etc/dovecot/dovecot-sql.conf |
209 |
fperms 600 /etc/dovecot/dovecot-sql.conf |
210 |
sed -i -e '/db sql/,/args/ s|=|= /etc/dovecot-sql.conf|' "${conf}" \ |
211 |
|| die "failed to update SQL settings in dovecot-sql.conf" |
212 |
dodoc doc/dovecot-sql-example.conf |
213 |
fi |
214 |
|
215 |
# Install LDAP configuration |
216 |
if use ldap; then |
217 |
cp doc/dovecot-ldap-example.conf "${D}"/etc/dovecot/dovecot-ldap.conf |
218 |
fperms 600 /etc/dovecot/dovecot-ldap.conf |
219 |
sed -i -e '/db ldap/,/args/ s|=|= /etc/dovecot-ldap.conf|' "${conf}" \ |
220 |
|| die "failed to update LDAP settings in dovecot-ldap.conf" |
221 |
dodoc doc/dovecot-ldap-example.conf |
222 |
fi |
223 |
|
224 |
# Install sieve plugin |
225 |
if use sieve; then |
226 |
make -C "${SIEVE_S}" DESTDIR="${D}" install \ |
227 |
|| die "make install failed (sieve)" |
228 |
fi |
229 |
|
230 |
# Install managesieve |
231 |
if use managesieve; then |
232 |
make -C "${MANAGESIEVE_S}" DESTDIR="${D}" install \ |
233 |
|| die "make install failed (managesieve)" |
234 |
fi |
235 |
|
236 |
dodir /var/run/dovecot |
237 |
fowners root:0 /var/run/dovecot |
238 |
fperms 0755 /var/run/dovecot |
239 |
keepdir /var/run/dovecot/login |
240 |
fowners root:dovecot /var/run/dovecot/login |
241 |
fperms 0750 /var/run/dovecot/login |
242 |
} |
243 |
|
244 |
get_config_var() { |
245 |
local varname=${1} |
246 |
if [[ -z ${varname} ]]; then |
247 |
die "${FUNCNAME}: variable name missing" |
248 |
fi |
249 |
sed -n 's/^[[:space:]]\?'"${varname}"'[[:space:]]*="*\([^#"]\+\)"*/\1/p' \ |
250 |
"${ROOT}"/etc/dovecot/dovecot.conf |
251 |
} |
252 |
|
253 |
pkg_postinst() { |
254 |
elog "The Dovecot configuration has vastly changed since 0.99." |
255 |
elog "You are encouraged to start afresh with a new configuration file." |
256 |
elog "see http://wiki.dovecot.org/ for configuration examples." |
257 |
|
258 |
if [[ -e "${ROOT}"/etc/dovecot.conf ]]; then |
259 |
echo |
260 |
ewarn "The Dovecot configuration now resides in ${ROOT}/etc/dovecot" |
261 |
fi |
262 |
|
263 |
local base_dir="$(get_config_var base_dir)" |
264 |
base_dir="${base_dir:-/var/run/dovecot}" |
265 |
if use ssl; then |
266 |
# Let's not make a new certificate if we already have one |
267 |
if ! [[ -e "${ROOT}"/etc/ssl/dovecot/server.pem && \ |
268 |
-e "${ROOT}"/etc/ssl/dovecot/server.key ]]; then |
269 |
einfo "Creating SSL certificate" |
270 |
SSL_ORGANIZATION="${SSL_ORGANIZATION:-Dovecot IMAP Server}" |
271 |
install_cert /etc/ssl/dovecot/server |
272 |
chown dovecot:mail "${ROOT}"/etc/ssl/dovecot/server.{key,pem} |
273 |
fi |
274 |
if [[ ! -e "${ROOT}${base_dir}/login/ssl-parameters.dat" ]]; then |
275 |
echo |
276 |
elog "Dovecot requires DH SSL Parameters if you use SSL connections" |
277 |
elog "These take some time to make, and dovecot will create them before" |
278 |
elog "it allows any SSL connections." |
279 |
elog "You can create them now before starting dovecot like so" |
280 |
elog " emerge --config =${PF}" |
281 |
fi |
282 |
fi |
283 |
} |
284 |
|
285 |
pkg_config() { |
286 |
local base_dir="$(get_config_var base_dir)" |
287 |
base_dir="${base_dir:-/var/run/dovecot}" |
288 |
|
289 |
if use ssl; then |
290 |
einfo "Regenerating SSL parameters. This will take some time." |
291 |
"${ROOT}"/usr/libexec/dovecot/ssl-build-param "${base_dir}/login/ssl-parameters.dat" |
292 |
fi |
293 |
} |
294 |
|
295 |
|
296 |
|
297 |
-- |
298 |
gentoo-commits@l.g.o mailing list |