summaryrefslogtreecommitdiffstats
path: root/dovecot/PKGBUILD
blob: 0421f9f8a2f1a06e02eab64ea7ce554f73fa9b36 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
# $Id$
#
# Contributor: Paul Mattal <paul@mattal.com>
# Contributor: Federico Quagliata (quaqo) <quaqo@despammed.com>
# Contributor: GARETTE Emmanuel <gnunux at laposte dot net>
# Maintainer: Andreas Radke <andyrtr@archlinux.org>

pkgname=dovecot-managesieve
_pkgname=dovecot
pkgver=1.2.1
_patchver=0.11.7
pkgrel=1
pkgdesc="An IMAP and POP3 server written with security primarily in mind"
arch=('i686' 'x86_64')
url="http://dovecot.org/"
license=("LGPL")
depends=("pam>=1.0.4" "libmysqlclient>=5.1.35-2" "postgresql-libs>=8.3.7" "sqlite3>=3.6.15-2" "db>=4.7.25.4"\
	 "heimdal>=1.2.1-5" 'libcap>=2.16-3' 'bzip2')
optdepends=('libldap: ldap plugin')
makedepends=('libldap>=2.3.43-3')
provides=('imap-server' 'pop3-server')
replaces=()
options=('!libtool')
install=$pkgname.install
source=(http://dovecot.org/releases/1.2/${_pkgname}-${pkgver}.tar.gz dovecot.sh "http://www.rename-it.nl/dovecot/1.2/${_pkgname}-${pkgver}-managesieve-${_patchver}.diff.gz")
md5sums=('c269cfe38fc40061e232dd28e5fe3721'
         'd020d43eab4ded6fb379dadc570a9490')

build() {
  cd ${srcdir}/${_pkgname}-$pkgver || return 1

  patch -p1 < $srcdir/${_pkgname}-${pkgver}-managesieve-${_patchver}.diff || return 1

  # configure with openssl, mysql, and postgresql support
  ./configure --prefix=/usr --sysconfdir=/etc/dovecot --localstatedir=/var \
  	--libexecdir=/usr/lib  --with-moduledir=/usr/lib/dovecot/modules \
	--with-db --with-mysql --with-pgsql --with-sqlite \
	--with-ssl=openssl --with-ssldir=/etc/dovecot/ssl \
	--with-gssapi --with-ldap=plugin --enable-header-install --with-docs || return 1

  make || return 1
  make DESTDIR=${pkgdir} install || return 1

  # install the launch script
  install -D -m755 ${srcdir}/${_pkgname}.sh ${pkgdir}/etc/rc.d/${_pkgname} || return 1

  # fix paths in the config example file where we have a different layout
  sed -i 's|/usr/lib/dovecot|/usr/lib/dovecot/modules|g;
	  s|libexec|lib|g;
	  s|lib/sendmail|sbin/sendmail|g' $pkgdir/etc/dovecot/dovecot-example.conf || return 1
}