mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-18 22:54:00 +00:00
67 lines
2.7 KiB
Bash
67 lines
2.7 KiB
Bash
# $Id: PKGBUILD 53185 2009-09-26 10:44:12Z allan $
|
|
# Maintainer: tobias <tobias@archlinux.org>
|
|
# Committer: Manolis Tzanidakis <manolis@archlinux.org>
|
|
|
|
pkgname=courier-imap
|
|
pkgver=4.4.1
|
|
pkgrel=2
|
|
pkgdesc="IMAP(s)/POP3(s) Server"
|
|
arch=('i686' 'x86_64')
|
|
license=('GPL2')
|
|
url="http://www.courier-mta.org/imap/"
|
|
depends=('courier-maildrop>=2.0.4-4' 'gcc-libs' 'fam' 'db>=4.8' 'openssl')
|
|
backup=('etc/courier-imap/imapd.cnf' 'etc/courier-imap/pop3d.cnf' \
|
|
'etc/courier-imap/imapd' 'etc/courier-imap/imapd-ssl' \
|
|
'etc/courier-imap/pop3d' 'etc/courier-imap/pop3d-ssl'\
|
|
'etc/conf.d/courier-imap')
|
|
conflicts=('courier-mta')
|
|
provides=('imap-server' 'pop3-server')
|
|
options=('!libtool')
|
|
source=(http://downloads.sourceforge.net/project/courier/imap/${pkgver}/${pkgname}-${pkgver}.tar.bz2
|
|
courier-imap.conf.d courier-imap.rc.d)
|
|
md5sums=('71482dff367e5161a3c0f9c61bbfd2b1' 'f00a0756ae41d9e993d141f24de8bf64' \
|
|
'e01be01a11654ce437f53d92ebc696c0')
|
|
|
|
build() {
|
|
cd ${srcdir}/${pkgname}-${pkgver}
|
|
# fix a tiny bug
|
|
sed -i -e \
|
|
's|--with-authchangepwdir=/var/tmp/dev/null|--with-authchangepwdir=$libexecdir/authlib|' \
|
|
configure && chmod 755 configure
|
|
./configure --prefix=/usr \
|
|
--sysconfdir=/etc/courier-imap \
|
|
--libexecdir=/usr/lib/courier-imap \
|
|
--localstatedir=/var/spool/courier-imap \
|
|
--disable-root-check \
|
|
--enable-unicode \
|
|
--enable-workarounds-for-imap-client-bugs \
|
|
--with-piddir=/var/run/courier \
|
|
--with-trashquota \
|
|
--with-db=db \
|
|
--with-trashquota \
|
|
--with-mailuser=courier --with-mailgroup=courier
|
|
make || return 1
|
|
make DESTDIR=${pkgdir} install
|
|
# cleanup - provided by courier-maildrop
|
|
rm ${pkgdir}/usr/bin/{deliverquota,maildirmake} || return 1
|
|
rm ${pkgdir}/usr/share/man/man1/maildirmake* || return 1
|
|
rm ${pkgdir}/usr/share/man/man8/deliverquota* || return 1
|
|
find ${pkgdir} -name '*\.a' -exec -rm -f {} \;
|
|
###############################################################################
|
|
# this is what usually "make install-configure" does
|
|
# *.dist files get rid of "dist"
|
|
for distfile in ${pkgdir}/etc/courier-imap/*.dist; do
|
|
mv ${distfile} ${pkgdir}/etc/courier-imap/$(basename ${distfile} .dist)
|
|
done
|
|
sed -i 's|TLS_CERTFILE=/usr/share/|TLS_CERTFILE=/etc/courier-imap/|' \
|
|
${pkgdir}/etc/courier-imap/*-ssl
|
|
for pamfile in imap/*.pam; do
|
|
sed -i "s|/lib/security/||;s|pam_pwdb|pam_unix|" ${pamfile}
|
|
install -Dm 644 ${pamfile} \
|
|
${pkgdir}/etc/pam.d/$(basename ${pamfile} .pam | sed "s/d$//")
|
|
done
|
|
# install thingies
|
|
install -D -m 755 ${srcdir}/courier-imap.rc.d ${pkgdir}/etc/rc.d/courier-imap
|
|
install -D -m 644 ${srcdir}/courier-imap.conf.d ${pkgdir}/etc/conf.d/courier-imap
|
|
install -dm755 -g courier -o courier ${pkgdir}/var/run/courier
|
|
}
|