aboutsummaryrefslogtreecommitdiff
path: root/databases/courier-authlib-userdb
diff options
context:
space:
mode:
authorOliver Lehmann <oliver@FreeBSD.org>2005-04-02 14:28:05 +0000
committerOliver Lehmann <oliver@FreeBSD.org>2005-04-02 14:28:05 +0000
commitcebfae0aa0896aeee50d6b8e36d9a6c091a5ce9d (patch)
tree7851baf9422e00bb01e17921866f491c5b4393be /databases/courier-authlib-userdb
parent86ed44ce3167a924cf27a6411f66a0ee3dcdf69e (diff)
downloadports-cebfae0aa0896aeee50d6b8e36d9a6c091a5ce9d.tar.gz
ports-cebfae0aa0896aeee50d6b8e36d9a6c091a5ce9d.zip
Notes
Diffstat (limited to 'databases/courier-authlib-userdb')
-rw-r--r--databases/courier-authlib-userdb/Makefile17
-rw-r--r--databases/courier-authlib-userdb/pkg-plist12
2 files changed, 20 insertions, 9 deletions
diff --git a/databases/courier-authlib-userdb/Makefile b/databases/courier-authlib-userdb/Makefile
index 8be4fa9cad28..902b25be6031 100644
--- a/databases/courier-authlib-userdb/Makefile
+++ b/databases/courier-authlib-userdb/Makefile
@@ -15,6 +15,8 @@ MASTER_SITE_SUBDIR= courier
MAINTAINER= oliver@FreeBSD.org
COMMENT= Authentication library used by courier ports
+CONFLICTS= courier-0.*
+
USE_BZIP2= yes
USE_REINPLACE= yes
USE_PERL5= yes
@@ -38,18 +40,24 @@ OPTIONS= PAM "Build with PAM support" on \
POSTGRESQL "Build in postgresql support" off \
LDAP "Build in ldap support with openldap" off \
GDBM "Use gdbm files instead of bdb" off \
- AUTHUSERDB "Build with authuserdb" on
+ AUTHUSERDB "Build with authuserdb" on \
+ MERGECFGS "Merge new Options into old auth-rc files" on
VPOPMAILDIR?= ${LOCALBASE}/vpopmail
WITH_MAILUSER?= daemon
WITH_MAILGROUP?=daemon
+CONFDIR?= ${PREFIX}/etc
+USERDB?= ${PREFIX}/etc/userdb
+
+PLIST_SUB= CONFDIR=${CONFDIR:S,^${PREFIX}/,,} \
CONFIGURE_ENV= CFLAGS="${CFLAGS} -I${LOCALBASE}/include" \
CXXFLAGS="${CPPFLAGS} -I${LOCALBASE}/include" \
LIBS="${LDFLAGS} -L${LOCALBASE}/lib"
CONFIGURE_TARGET= --build=${MACHINE_ARCH}-portbld-freebsd${OSREL}
-CONFIGURE_ARGS= --without-authshadow \
+CONFIGURE_ARGS= --sysconfdir=${CONFDIR} \
+ --without-authshadow \
--without-authcustom \
--enable-unicode \
--enable-ltdl-install=no \
@@ -119,10 +127,11 @@ PLIST_SUB+= PAMFLAG="@comment "
CONFIGURE_ARGS+=--without-authuserdb
PLIST_SUB+= AUTHUSERDBFLAG="@comment "
.else
+CONFIGURE_ARGS+=--with-userdb=${USERDB}
PLIST_SUB+= AUTHUSERDBFLAG=""
.endif
-RC_SCRIPTS_SUB=PREFIX=${PREFIX} RC_SUBR=${RC_SUBR} MAILUSER=${WITH_MAILUSER} MAILGROUP=${WITH_MAILGROUP}
+RC_SCRIPTS_SUB= PREFIX=${PREFIX} RC_SUBR=${RC_SUBR} MAILUSER=${WITH_MAILUSER} MAILGROUP=${WITH_MAILGROUP}
MAN1= courierlogger.1
@@ -154,7 +163,9 @@ post-install:
${SED} ${RC_SCRIPTS_SUB:S/$/!g/:S/^/ -e s!%%/:S/=/%%!/} \
${FILESDIR}/courier-authdaemond.sh > ${WRKDIR}/courier-authdaemond.sh
${INSTALL_SCRIPT} ${WRKDIR}/courier-authdaemond.sh ${PREFIX}/etc/rc.d/courier-authdaemond.sh
+.if defined(WITH_MERGECFGS)
cd ${WRKSRC} && ( ${GMAKE} install-configure ; cd - )
+.endif
.if !defined(NOPORTDOCS)
@${MKDIR} ${DOCSDIR}
diff --git a/databases/courier-authlib-userdb/pkg-plist b/databases/courier-authlib-userdb/pkg-plist
index d3e729fba8d2..e9626f569ca8 100644
--- a/databases/courier-authlib-userdb/pkg-plist
+++ b/databases/courier-authlib-userdb/pkg-plist
@@ -1,11 +1,11 @@
@unexec [ ! -f /var/run/authdaemond/pid ] || %D/etc/rc.d/courier-authdaemond.sh stop || true
bin/courierauthconfig
etc/rc.d/courier-authdaemond.sh
-%%MYSQLFLAG%%etc/authlib/authmysqlrc.dist
-%%PGSQLFLAG%%etc/authlib/authpgsqlrc.dist
-%%LDAPFLAG%%etc/authlib/authldaprc.dist
-@unexec if cmp -s %D/etc/authlib/authdaemonrc.dist %D/etc/authlib/authdaemonrc; then rm -f %D/etc/authlib/authdaemonrc; fi
-etc/authlib/authdaemonrc.dist
+%%MYSQLFLAG%%@unexec if cmp -s %D/%%CONFDIR%%/authlib/authmysqlrc.dist %D/%%CONFDIR%%/authlib/authmysqlrc; then rm -f %D/%%CONFDIR%%/authlib/authmysqlrc; fi
+%%PGSQLFLAG%%@unexec if cmp -s %D/%%CONFDIR%%/authlib/authpgsqlrc.dist %D/%%CONFDIR%%/authlib/authpgsqlrc; then rm -f %D/%%CONFDIR%%/authlib/authpgsqlrc; fi
+%%LDAPFLAG%%@unexec if cmp -s %D/%%CONFDIR%%/authlib/authldaprc.dist %D/%%CONFDIR%%/authlib/authldaprc; then rm -f %D/%%CONFDIR%%/authlib/authldaprc; fi
+@unexec if cmp -s %D/%%CONFDIR%%/authlib/authdaemonrc.dist %D/%%CONFDIR%%/authlib/authdaemonrc; then rm -f %D/%%CONFDIR%%/authlib/authdaemonrc; fi
+%%CONFDIR%%/authlib/authdaemonrc.dist
include/courier_auth_config.h
include/courierauth.h
include/courierauthsasl.h
@@ -62,6 +62,6 @@ sbin/courierlogger
%%PORTDOCS%%%%DOCSDIR%%/README_authlib.html
%%PORTDOCS%%@dirrm %%DOCSDIR%%
@unexec rmdir /var/run/authdaemond 2>/dev/null || true
-@unexec rmdir %D/etc/authlib 2>/dev/null || true
+@unexec rmdir %D/%%CONFDIR%%/authlib 2>/dev/null || true
@dirrm lib/courier-authlib
@dirrm libexec/courier-authlib