Contents of /trunk/extras/dovecot/dovecot-1.2.10-r1.smage2
Parent Directory | Revision Log
Revision 5089 -
(show annotations)
(download)
Thu Mar 4 17:09:01 2010 UTC (14 years, 2 months ago) by niro
File size: 2660 byte(s)
Thu Mar 4 17:09:01 2010 UTC (14 years, 2 months ago) by niro
File size: 2660 byte(s)
-rev bump to -r2; config fixes, build ldap and mysql support as plugins, db and sqlite support, ipv4&6 at the same time, maildir as default, added missing dependencies
1 | # $Id$ |
2 | |
3 | PNAME="dovecot" |
4 | PVER="1.2.10" |
5 | PBUILD="r2" |
6 | |
7 | PCATEGORIE="net-mail" |
8 | STATE="unstable" |
9 | |
10 | DESCRIPTION="Dovecot is an IMAP and POP3 server written with security primarily in mind." |
11 | HOMEPAGE="http://dovecot.org/" |
12 | |
13 | DEPEND=">= net-mail/mail-base-files-0.1 |
14 | >= sys-libs/pam-1.1 |
15 | >= sys-libs/libcap-2.17 |
16 | >= dev-libs/openssl-0.9.8k |
17 | >= net-nds/openldap-2.4 |
18 | >= dev-db/mysql5-5.1 |
19 | >= dev-db/sqlite-3.6 |
20 | >= dev-db/db-4.8" |
21 | |
22 | SRCFILE="${PNAME}-${PVER}.tar.gz" |
23 | SRCDIR="${BUILDDIR}/${PNAME}-${PVER}" |
24 | |
25 | RC_CVS_REV=1.2 |
26 | |
27 | sminclude mtools |
28 | |
29 | SRC_URI=( |
30 | http://dovecot.org/releases/${PVER%.*}/${SRCFILE} |
31 | mirror://${PNAME}/${SRCFILE} |
32 | mirror://${PNAME}/dovecot.rc-${RC_CVS_REV} |
33 | mirror://${PNAME}/${PNAME}-${PVER}-magellan-defaults.patch |
34 | mirror://${PNAME}/${PNAME}-${PVER}-config-install.patch |
35 | ) |
36 | |
37 | UP2DATE="updatecmd ${HOMEPAGE}/download.html | grep -A3 'Stable' | grep 'Download' | sed 's:.*v\(.*\)\ sources.*:\1:'" |
38 | |
39 | src_prepare() |
40 | { |
41 | munpack ${SRCFILE} || die |
42 | cd ${SRCDIR} |
43 | |
44 | # apply our default settings |
45 | mpatch ${PNAME}-${PVER}-magellan-defaults.patch || die |
46 | |
47 | # install only devcot.conf and not any examples to /etc/dovecot |
48 | mpatch ${PNAME}-${PVER}-config-install.patch || die |
49 | } |
50 | |
51 | src_compile() |
52 | { |
53 | cd ${SRCDIR} |
54 | |
55 | mconfigure \ |
56 | --sysconfdir=/etc/dovecot \ |
57 | --with-moduledir=/usr/$(mlibdir)/dovecot \ |
58 | --localstatedir=/var \ |
59 | --enable-header-install \ |
60 | --enable-ipv6 \ |
61 | --disable-debug \ |
62 | --with-ioloop=best \ |
63 | --with-poll=best \ |
64 | --with-libcap \ |
65 | --with-ssl=openssl \ |
66 | --with-ssldir=/etc/ssl \ |
67 | --with-ldap=plugin \ |
68 | --with-sql=plugin \ |
69 | --with-sql-drivers \ |
70 | --with-mysql \ |
71 | --with-sqlite \ |
72 | --with-db \ |
73 | --with-pam \ |
74 | || die |
75 | |
76 | mmake || die |
77 | } |
78 | |
79 | src_install() |
80 | { |
81 | cd ${SRCDIR} |
82 | mmake DESTDIR=${BINDIR} install || die |
83 | |
84 | # we're using pam files (imap and pop3) provided by mailbase |
85 | sed -i '/passdb pam/, /^[ \t]*}/ s|#args = dovecot|args = "\*"|' \ |
86 | ${BINDIR}/etc/dovecot/dovecot.conf || die |
87 | |
88 | # install our initscript |
89 | minstallrc dovecot.rc-${RC_CVS_REV} dovecot || die |
90 | |
91 | # remove unwanted docs |
92 | rm -rf ${BINDIR}/usr/share/doc/dovecot || die |
93 | |
94 | minstalldocs AUTHORS ChangeLog COPYING* NEWS README TODO || die |
95 | minstalldocs dovecot-example.conf || die |
96 | } |
97 | |
98 | preinstall() |
99 | { |
100 | # adding proftpd user |
101 | ${MLIBDIR}/mgroupadd -o "-g 97" dovecot |
102 | ${MLIBDIR}/museradd -o "-u 97 -g dovecot -d /dev/null -s /bin/false" dovecot |
103 | } |
104 | |
105 | postinstall() |
106 | { |
107 | # generate a self-signed ssl-cert |
108 | if [[ ! -f /etc/ssl/certs/dovecot.pem ]] |
109 | then |
110 | /usr/sbin/openssl-make-certs dovecot |
111 | fi |
112 | |
113 | # rebuild ssl-parametes |
114 | if [[ ! -f /var/run/dovecot/login/ssl-parameters.dat ]] |
115 | then |
116 | dovecot --build-ssl-parameters &> /dev/null |
117 | fi |
118 | |
119 | mstartservice dovecot |
120 | } |
121 | |
122 | postremove() |
123 | { |
124 | mstopservice dovecot |
125 | } |
Properties
Name | Value |
---|---|
svn:keywords | Id |