Magellan Linux

Annotation of /trunk/extras/dovecot/dovecot-1.2.10-r2.smage2

Parent Directory Parent Directory | Revision Log Revision Log


Revision 5089 - (hide annotations) (download)
Thu Mar 4 17:09:01 2010 UTC (14 years, 2 months ago) by niro
File size: 3096 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 niro 5089 # $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}-magellan-defaults-maildir.patch
35     mirror://${PNAME}/${PNAME}-${PVER}-magellan-defaults-pam.patch
36     mirror://${PNAME}/${PNAME}-${PVER}-magellan-defaults-ipv4a6.patch
37     mirror://${PNAME}/${PNAME}-${PVER}-config-install.patch
38     )
39    
40     UP2DATE="updatecmd ${HOMEPAGE}/download.html | grep -A3 'Stable' | grep 'Download' | sed 's:.*v\(.*\)\ sources.*:\1:'"
41    
42     src_prepare()
43     {
44     munpack ${SRCFILE} || die
45     cd ${SRCDIR}
46    
47     # apply our default settings
48     mpatch ${PNAME}-${PVER}-magellan-defaults.patch || die
49    
50     # enable maildir as default
51     mpatch ${PNAME}-${PVER}-magellan-defaults-maildir.patch || die
52    
53     # we're using pam files (imap and pop3) provided by mailbase
54     mpatch ${PNAME}-${PVER}-magellan-defaults-pam.patch || die
55    
56     # use ipv4 and ipv6 support
57     mpatch ${PNAME}-${PVER}-magellan-defaults-ipv4a6.patch || die
58    
59     # install only devcot.conf and not any examples to /etc/dovecot
60     mpatch ${PNAME}-${PVER}-config-install.patch || die
61     }
62    
63     src_compile()
64     {
65     cd ${SRCDIR}
66    
67     mconfigure \
68     --sysconfdir=/etc/dovecot \
69     --with-moduledir=/usr/$(mlibdir)/dovecot \
70     --localstatedir=/var \
71     --enable-header-install \
72     --enable-ipv6 \
73     --disable-debug \
74     --with-ioloop=best \
75     --with-poll=best \
76     --with-libcap \
77     --with-ssl=openssl \
78     --with-ssldir=/etc/ssl \
79     --with-ldap=plugin \
80     --with-sql=plugin \
81     --with-sql-drivers \
82     --with-mysql \
83     --with-sqlite \
84     --with-db \
85     --with-pam \
86     || die
87    
88     mmake || die
89     }
90    
91     src_install()
92     {
93     cd ${SRCDIR}
94     mmake DESTDIR=${BINDIR} install || die
95    
96     # install our initscript
97     minstallrc dovecot.rc-${RC_CVS_REV} dovecot || die
98    
99     # remove unwanted docs
100     rm -rf ${BINDIR}/usr/share/doc/dovecot || die
101    
102     minstalldocs AUTHORS ChangeLog COPYING* NEWS README TODO || die
103     minstalldocs dovecot-example.conf || die
104     minstalldocs docs/dovecot-db-example.conf || die
105     minstalldocs docs/dovecot-sql-example.conf || die
106     minstalldocs docs/dovecot-ldap-example.conf || die
107     }
108    
109     preinstall()
110     {
111     # adding proftpd user
112     ${MLIBDIR}/mgroupadd -o "-g 97" dovecot
113     ${MLIBDIR}/museradd -o "-u 97 -g dovecot -d /dev/null -s /bin/false" dovecot
114     }
115    
116     postinstall()
117     {
118     # generate a self-signed ssl-cert
119     if [[ ! -f /etc/ssl/certs/dovecot.pem ]]
120     then
121     echo
122     echo "You need to generate a certificate to run this daemon."
123     echo "Just run: 'openssl-make-certs dovecot'."
124     echo
125     fi
126    
127     mstartservice dovecot
128     }
129    
130     postremove()
131     {
132     mstopservice dovecot
133     }

Properties

Name Value
svn:keywords Id