summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGrant Goodyear <g2boojum@gentoo.org>2004-04-10 14:21:11 +0000
committerGrant Goodyear <g2boojum@gentoo.org>2004-04-10 14:21:11 +0000
commit815297d066d5150584120e9df7d60c2b998614b2 (patch)
tree7d204c00a6b21e74d3ff10391de41c9e1d40be97
parentVersion bumped. (Manifest recommit) (diff)
downloadgentoo-2-815297d066d5150584120e9df7d60c2b998614b2.tar.gz
gentoo-2-815297d066d5150584120e9df7d60c2b998614b2.tar.bz2
gentoo-2-815297d066d5150584120e9df7d60c2b998614b2.zip
New package
-rw-r--r--net-mail/dovecot/ChangeLog8
-rw-r--r--net-mail/dovecot/Manifest4
-rw-r--r--net-mail/dovecot/dovecot-0.99.10.4.ebuild136
-rw-r--r--net-mail/dovecot/files/digest-dovecot-0.99.10.41
-rw-r--r--net-mail/dovecot/files/dovecot.init23
-rw-r--r--net-mail/dovecot/files/dovecot.pam5
-rw-r--r--net-mail/dovecot/metadata.xml8
7 files changed, 185 insertions, 0 deletions
diff --git a/net-mail/dovecot/ChangeLog b/net-mail/dovecot/ChangeLog
new file mode 100644
index 000000000000..df46e3de4c3b
--- /dev/null
+++ b/net-mail/dovecot/ChangeLog
@@ -0,0 +1,8 @@
+# ChangeLog for net-mail/dovecot
+# Copyright 2000-2004 Gentoo Technologies, Inc.; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/net-mail/dovecot/ChangeLog,v 1.1 2004/04/10 14:21:11 g2boojum Exp $
+
+ 10 Apr 2004; Grant Goodyear <g2boojum@hotmail.com> :
+ Long overdue new package. Thanks to Zach Bagnell, Andreas Simon, Lars
+ Trieloff, Andrew Cooks, Tony Vroon, and tseng.
+
diff --git a/net-mail/dovecot/Manifest b/net-mail/dovecot/Manifest
new file mode 100644
index 000000000000..59fcee17fd6c
--- /dev/null
+++ b/net-mail/dovecot/Manifest
@@ -0,0 +1,4 @@
+MD5 a50c38676b505d67d99d6e2ff6571db0 dovecot-0.99.10.4.ebuild 3502
+MD5 1a8aa87fe80627f30665c2c4cc40e84c dovecot.init 426
+MD5 1c0a9ca75cadf12377e70c2ef725ba0e dovecot.pam 220
+MD5 02900826bf90ce0fcbf43a3ebbfa31cf files/digest-dovecot-0.99.10.4 69
diff --git a/net-mail/dovecot/dovecot-0.99.10.4.ebuild b/net-mail/dovecot/dovecot-0.99.10.4.ebuild
new file mode 100644
index 000000000000..d34864afd783
--- /dev/null
+++ b/net-mail/dovecot/dovecot-0.99.10.4.ebuild
@@ -0,0 +1,136 @@
+# Copyright 1999-2004 Gentoo Technologies, Inc.
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-mail/dovecot/dovecot-0.99.10.4.ebuild,v 1.1 2004/04/10 14:21:11 g2boojum Exp $
+
+IUSE="debug ipv6 ldap maildir pam postgres sasl ssl vpopmail nopop3d"
+
+DESCRIPTION="An IMAP and POP3 server written with security primarily in mind"
+HOMEPAGE="http://dovecot.procontrol.fi/"
+SRC_URI="${HOMEPAGE}/${P}.tar.gz"
+
+SLOT="0"
+LICENSE="LGPL-2.1"
+KEYWORDS="~x86"
+
+#PROVIDE="virtual/imapd"
+
+# Note: current dovecot will break on gnutls-1.0.5
+DEPEND=">=sys-libs/db-3.2
+ >=sys-apps/sed-4
+ ldap? ( >=net-nds/openldap-1.2 )
+ pam? ( sys-libs/pam )
+ sasl? ( >=dev-libs/cyrus-sasl-2.1 )
+ ssl? ( >=dev-libs/openssl-0.9.6g )
+ gnutls? ( <=net-libs/gnutls-1.0.4 )
+ postgres? ( dev-db/postgresql )
+ vpopmail? ( net-mail/vpopmail )"
+
+RDEPEND="${DEPEND}
+ net-mail/mailbase"
+
+
+pkg_preinst() {
+ # Add user and group for login process
+ if ! getent group | grep -q ^dovecot
+ then
+ groupadd dovecot || die "problem adding group dovecot"
+ fi
+ if ! getent passwd | grep -q ^dovecot
+ then
+ useradd -c dovecot -d /usr/libexec/dovecot -g dovecot \
+ -s /bin/false dovecot || die "problem adding user dovecot"
+ fi
+}
+
+src_compile() {
+ local myconf
+ use debug && myconf="--enable-debug"
+ use ldap && myconf="${myconf} --with-ldap"
+ use ipv6 || myconf="${myconf} --disable-ipv6"
+ use nopop3d && myconf="${myconf} --without-pop3d"
+ use pam || myconf="${myconf} --without-pam"
+ use postgres && myconf="${myconf} --with-pgsql"
+ use sasl && myconf="${myconf} --with-cyrus-sasl2"
+ use gnutls && myconf="${myconf} --with-ssl=gnutls"
+ use ssl && myconf="${myconf} --with-ssl=openssl"
+ ! use gnutls && ! use ssl && myconf="${myconf} --without-ssl"
+ use vpopmail || myconf="${myconf} --without-vpopmail"
+
+ ./configure \
+ --prefix=/usr \
+ --host=${CHOST} \
+ --mandir=/usr/share/man \
+ --infodir=/usr/share/info \
+ --datadir=/usr/share \
+ --sysconfdir=/etc \
+ --localstatedir=/var \
+ ${myconf} || die "configure failed"
+ emake || die
+}
+
+src_install () {
+ make DESTDIR=${D} install || die
+
+ # If /etc/dovecot.conf doesn't already exist, install a copy of
+ # dovecot-example.conf, changing the default mailbox locations to
+ # Gentoo's default ($HOME/.maildiir/ or /var/spool/mail/$USER)
+ if [ ! -e /etc/dovecot.conf ]; then
+ cd ${D}/etc
+ if [ "`use maildir`" ]; then
+ sed s/^#default_mail_env.*$/default_mail_env\ =\ maildir:%h\\/.maildir/ dovecot-example.conf > dovecot.conf
+ else
+ sed s/^#default_mail_env.*$/default_mail_env\ =\ mbox:\\/var\\/spool\\/mail\\/%u/ dovecot-example.conf > dovecot.conf
+ fi
+ cd -
+ fi
+ rm -f ${D}/etc/dovecot-example.conf
+
+ # Documentation
+ rm -fr ${D}/usr/share/doc/dovecot
+ cd ${S}
+ dodoc AUTHORS COPYING* NEWS README TODO dovecot-example.conf
+ dodoc doc/*.txt doc/*.conf doc/*.cnf
+
+ # per default dovecot wants it ssl cert called dovecot.pem
+ # fix this in mkcert.sh, which we use to generate the ssl certs
+ cd ${S}/doc
+ mv mkcert.sh mkcert.sh.tmp
+ sed s/imapd.pem/dovecot.pem/g mkcert.sh.tmp > mkcert.sh
+ dodoc mkcert.sh
+
+ # rc script
+ exeinto /etc/init.d
+ newexe ${FILESDIR}/dovecot.init dovecot
+
+ # PAM
+ if [ "`use pam`" ]; then
+ dodir /etc/pam.d
+ insinto /etc/pam.d
+ newins ${FILESDIR}/dovecot.pam dovecot
+ fi
+
+ # Create SSL certificates
+ if [ "`use ssl`" || "`use gnutls`" ]; then
+ cd ${S}/doc
+ dodir /etc/ssl/certs
+ dodir /etc/ssl/private
+ [ -e /etc/ssl/certs/dovecot.pem -a -e /etc/ssl/private/dovecot.pem ] \
+ || SSLDIR=${D}/etc/ssl sh mkcert.sh
+ fi
+
+ dodir /var/run/dovecot
+ fowners root:root /var/run/dovecot
+ fperms 0700 /var/run/dovecot
+ keepdir /var/run/dovecot/login
+ fowners root:dovecot /var/run/dovecot/login
+ fperms 0750 /var/run/dovecot/login
+}
+
+pkg_postinst() {
+ if [ "`use pam`" ]; then
+ ewarn "If you are upgrading from Dovecot prior to 0.99.10, be aware"
+ ewarn "that the PAM profile was changed from 'imap' to 'dovecot'."
+ einfo "Please review /etc/pam.d/dovecot."
+ fi
+ einfo "Please review /etc/dovecot.conf, particularly auth_userdb and auth_passdb."
+}
diff --git a/net-mail/dovecot/files/digest-dovecot-0.99.10.4 b/net-mail/dovecot/files/digest-dovecot-0.99.10.4
new file mode 100644
index 000000000000..877af0bbff55
--- /dev/null
+++ b/net-mail/dovecot/files/digest-dovecot-0.99.10.4
@@ -0,0 +1 @@
+MD5 81eda7985e99d28acd6d286aa0e13e07 dovecot-0.99.10.4.tar.gz 859856
diff --git a/net-mail/dovecot/files/dovecot.init b/net-mail/dovecot/files/dovecot.init
new file mode 100644
index 000000000000..0c4ee1cff9fb
--- /dev/null
+++ b/net-mail/dovecot/files/dovecot.init
@@ -0,0 +1,23 @@
+#!/sbin/runscript
+# Copyright 1999-2003 Gentoo Technologies, Inc.
+# Distributed under the terms of the GNU General Public License, v2 or later
+# $Header: /var/cvsroot/gentoo-x86/net-mail/dovecot/files/dovecot.init,v 1.1 2004/04/10 14:21:11 g2boojum Exp $
+
+depend() {
+ need net
+ after saslauthd
+ use logger
+}
+
+start() {
+ ebegin "Starting dovecot"
+ start-stop-daemon --start --quiet --exec /usr/sbin/dovecot
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping dovecot"
+ start-stop-daemon --stop --quiet --exec /usr/sbin/dovecot
+ eend $?
+}
+
diff --git a/net-mail/dovecot/files/dovecot.pam b/net-mail/dovecot/files/dovecot.pam
new file mode 100644
index 000000000000..20dff0203ace
--- /dev/null
+++ b/net-mail/dovecot/files/dovecot.pam
@@ -0,0 +1,5 @@
+#%PAM-1.0
+auth required pam_nologin.so
+auth required pam_stack.so service=system-auth
+account required pam_stack.so service=system-auth
+session required pam_stack.so service=system-auth
diff --git a/net-mail/dovecot/metadata.xml b/net-mail/dovecot/metadata.xml
new file mode 100644
index 000000000000..448192c72639
--- /dev/null
+++ b/net-mail/dovecot/metadata.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>mail</herd>
+<maintainer>
+ <email>g2boojum@gentoo.org</email>
+</maintainer>
+</pkgmetadata>