aboutsummaryrefslogtreecommitdiff
path: root/mail/lmtpd
diff options
context:
space:
mode:
authorPete Fritchman <petef@FreeBSD.org>2004-05-01 02:25:14 +0000
committerPete Fritchman <petef@FreeBSD.org>2004-05-01 02:25:14 +0000
commit5f92a3817bd6f0119de936f9398d011d66973bfd (patch)
treeb68fd2cb8d2520ceb6da6441137dee61f96ad1a1 /mail/lmtpd
parentce673392c8d0ac7f82233d093e7979dae8364c9f (diff)
downloadports-5f92a3817bd6f0119de936f9398d011d66973bfd.tar.gz
ports-5f92a3817bd6f0119de936f9398d011d66973bfd.zip
Notes
Diffstat (limited to 'mail/lmtpd')
-rw-r--r--mail/lmtpd/Makefile68
1 files changed, 61 insertions, 7 deletions
diff --git a/mail/lmtpd/Makefile b/mail/lmtpd/Makefile
index 31b650a81cbf..d8515ec555cd 100644
--- a/mail/lmtpd/Makefile
+++ b/mail/lmtpd/Makefile
@@ -7,6 +7,7 @@
PORTNAME= lmtpd
PORTVERSION= 0.9.16
+PORTREVISION= 1
CATEGORIES= mail
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= pll
@@ -14,16 +15,69 @@ MASTER_SITE_SUBDIR= pll
MAINTAINER= kiwi@oav.net
COMMENT= LMTP server compliant with RFC 2033 and Maildir++
-LIB_DEPENDS= mysqlclient:${PORTSDIR}/databases/mysql323-client \
- pcre:${PORTSDIR}/devel/pcre \
- iconv:${PORTSDIR}/converters/libiconv \
- db3.3:${PORTSDIR}/databases/db3
+LIB_DEPENDS= iconv:${PORTSDIR}/converters/libiconv
BUILD_DEPENDS= ${LOCALBASE}/lib/libhome.a:${PORTSDIR}/misc/libhome
+OPTIONS= PCRE "Support for PCRE" on
+
+.include <bsd.port.pre.mk>
+
+.if exists(${LOCALBASE}/lib/mysql/libmysqlclient.so)
+WITH_MYSQL= yes
+OPTIONS+= MYSQL "Support for MySQL Queries and Logs" on
+.else
+OPTIONS+= MYSQL "Support for MySQL Queries and Logs" off
+.endif
+
+.if exists(${LOCALBASE}/lib/libdb3.so)
+WITH_DB3= yes
+OPTIONS+= DB3 "Support for DB3" on
+.else
+OPTIONS+= DB3 "Support for DB3" off
+.endif
+
+.if exists(${LOCALBASE}/lib/libdb4.so)
+WITH_DB4= yes
+OPTIONS+= DB4 "Support for DB4" on
+.else
+OPTIONS+= DB4 "Support for DB4" off
+.endif
+
+.if defined(WITH_DB3) && defined(WITH_DB4)
+.error You cannot use DB3 and DB4 in the same time.
+.endif
+
+.if defined(WITH_PCRE)
+LIB_DEPENDS+= pcre:${PORTSDIR}/devel/pcre
+CONFIGURE_ARGS+= --with-pcre
+.else
+CONFIGURE_ARGS+= --without-pcre
+.endif
+
+.if defined(WITH_MYSQL)
+USE_MYSQL= yes
+CONFIGURE_ARGS+= --with-mysql=${LOCALBASE}/include/mysql --with-mysqllog
+.else
+CONFIGURE_ARGS+= --without-mysql --without-mysqllog
+.endif
+
+.if defined(WITH_DB3)
+LIB_DEPENDS+= db3.3:${PORTSDIR}/databases/db3
+CONFIGURE_ARGS+= --with-db3=${LOCALBASE}/include/db3 --without-db4
+.else
+CONFIGURE_ARGS+= --without-db3
+.endif
+
+.if defined(WITH_DB4)
+LIB_DEPENDS+= db4:${PORTSDIR}/databases/db4
+CONFIGURE_ARGS+= --with-db4=${LOCALBASE}/include/db4 --without-db3
+.else
+CONFIGURE_ARGS+= --without-db4
+.endif
+
GNU_CONFIGURE= YES
CONFIGURE_ENV= CFLAGS="${CFLAGS} -I${LOCALBASE}/include"
-CONFIGURE_ARGS= --with-mysqllog --with-db3 -without-db4 \
- --with-pcre --without-perl
+CONFIGURE_ARGS+= --without-perl
CONFIGURE_TARGET= --build=${MACHINE_ARCH}-portbld-freebsd${OSREL}
MAN8= lmtpd.8
@@ -42,4 +96,4 @@ post-install:
cd ${WRKSRC} && ${INSTALL_DATA} ${DOCS} ${DOCSDIR}
.endif
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>