diff options
author | Dirk Meyer <dinoex@FreeBSD.org> | 2005-11-20 16:03:43 +0000 |
---|---|---|
committer | Dirk Meyer <dinoex@FreeBSD.org> | 2005-11-20 16:03:43 +0000 |
commit | af3f41a6324a8dea8d8d15feafea26cb7aeaf3b3 (patch) | |
tree | bd9babcc74857a1b0f1a7d20b2c2fdfbf260f028 /mail/milter-regex/Makefile | |
parent | 92cbcb482f6bf5d0e4c8057b75d349599bc49ce7 (diff) |
Notes
Diffstat (limited to 'mail/milter-regex/Makefile')
-rw-r--r-- | mail/milter-regex/Makefile | 26 |
1 files changed, 21 insertions, 5 deletions
diff --git a/mail/milter-regex/Makefile b/mail/milter-regex/Makefile index 0e73bdaa282b..b0819ca2ae0e 100644 --- a/mail/milter-regex/Makefile +++ b/mail/milter-regex/Makefile @@ -7,7 +7,7 @@ # PORTNAME= milter_regex -PORTVERSION= 1.5 +PORTVERSION= 1.6 CATEGORIES= mail MASTER_SITES= http://www.benzedrine.cx/ DISTNAME= milter-regex-${PORTVERSION} @@ -15,26 +15,42 @@ DISTNAME= milter-regex-${PORTVERSION} MAINTAINER= dhartmei@FreeBSD.org COMMENT= Milter plugin to sendmail for regular expression filtering +WRKSRC= ${WRKDIR}/milter-regex USE_REINPLACE= yes MAILUSER?= mailnull MAN8= milter-regex.8 PLIST_FILES= libexec/milter-regex +MAKE_ENV+= LDFLAGS="${LDFLAGS}" +.include <bsd.port.pre.mk> + +.if defined(SENDMAIL_MILTER_PORT) +.if defined(SENDMAIL_WITH_SHARED_MILTER) +LIB_DEPENDS+= milter.3:${PORTSDIR}/mail/${SENDMAIL_MILTER_PORT} +.else +BUILD_DEPENDS+= ${LOCALBASE}/lib/libmilter.a:${PORTSDIR}/mail/${SENDMAIL_MILTER_PORT} +.endif +LDFLAGS+= -L${LOCALBASE}/lib +.endif + +.if !defined(SENDMAIL_MILTER_PORT) pre-everything:: .if !exists(/usr/lib/libmilter.a) ${ECHO_CMD} "Fatal: milter required, see instructions in DESCR" - exit 1 + ${FALSE} +.endif .endif post-patch: @${REINPLACE_CMD} -e \ - "s:/etc/milter-regex.conf:/usr/local/etc/milter-regex.conf:g; \ + "s:/etc/milter-regex.conf:${PREFIX}/etc/milter-regex.conf:g; \ s:_milter-regex:${MAILUSER}:g;" ${WRKSRC}/milter-regex.c @${REINPLACE_CMD} -e \ - "s:/etc/milter-regex.conf:/usr/local/etc/milter-regex.conf:g; \ + "s:/etc/milter-regex.conf:${PREFIX}/etc/milter-regex.conf:g; \ s:mailstats 1:mailstats 8:;" ${WRKSRC}/milter-regex.8 @${REINPLACE_CMD} -e "s:-lpthread:${PTHREAD_LIBS}:g; \ s:-I/usr/src/gnu/usr.sbin/sendmail/include:${PTHREAD_CFLAGS}:g; \ + s:-L/usr/local/lib:-L${LOCALBASE}/lib:g; \ s/-Werror//g" ${WRKSRC}/Makefile do-install: @@ -42,4 +58,4 @@ do-install: @${INSTALL_MAN} ${WRKSRC}/milter-regex.8 ${PREFIX}/man/man8 @${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL -.include <bsd.port.mk> +.include <bsd.port.post.mk> |