Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 5 Dec 2013 08:39:07 +0000 (UTC)
From:      Dirk Meyer <dinoex@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r335656 - in head/mail/spamilter: . files
Message-ID:  <201312050839.rB58d78W029516@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: dinoex
Date: Thu Dec  5 08:39:07 2013
New Revision: 335656
URL: http://svnweb.freebsd.org/changeset/ports/335656

Log:
  - use STAGEDIR
  - use OPT_* flags
  - use SHEBANG_FILES

Modified:
  head/mail/spamilter/Makefile
  head/mail/spamilter/files/patch-Makefile.tmpl

Modified: head/mail/spamilter/Makefile
==============================================================================
--- head/mail/spamilter/Makefile	Thu Dec  5 07:59:09 2013	(r335655)
+++ head/mail/spamilter/Makefile	Thu Dec  5 08:39:07 2013	(r335656)
@@ -14,8 +14,9 @@ COMMENT=	A Sendmail LibMilter filter to 
 LICENSE=	BSD
 LICENSE_FILE=	${WRKSRC}/LICENSE
 
-NO_STAGE=	yes
+NEED_ROOT=	yes
 
+USES=		shebangfix
 HAS_CONFIGURE=	yes
 CONFIGURE_ARGS=	--have-resn
 USE_RC_SUBR=	spamilter
@@ -25,6 +26,7 @@ LDFLAGS+=	${PTHREAD_LIBS}
 MAKE_ENV+=	__MAKE_CONF=/dev/null
 
 BINFILES=	spamilter-system-report spamilter-user-report
+SHEBANG_FILES=	${BINFILES}
 DOCSFILES=	Changelog INSTALL LICENSE docs/docs.html docs/docs.txt \
 		conf/db.rcpt conf/db.rdnsbl conf/db.sndr \
 		conf/policy.html conf/spamilter.rc
@@ -39,6 +41,13 @@ OPTIONS_DEFINE=	SMTP_AFTER_POP3 PAM LIBS
 SMTP_AFTER_POP3_DESC=	SMTP after POP3
 LIBSPF_DESC=	build with libspf
 
+SMTP_AFTER_POP3_CONFIGURE_ON=	--with-popauth
+PAM_CONFIGURE_ON=	--with-pam
+LIBSPF_BUILD_DEPENDS=	${LOCALBASE}/lib/libspf.a:${PORTSDIR}/mail/libspf
+LIBSPF_CONFIGURE_ON=	--with-libspf ${LOCALBASE}
+LIBSPF_CFLAGS=		-I${LOCALBASE}/include
+LIBSPF_LDFLAGS=		-L${LOCALBASE}/lib
+
 .include <bsd.port.options.mk>
 
 .include "${PORTSDIR}/mail/sendmail/bsd.milter.mk"
@@ -49,21 +58,6 @@ CONFIGURE_ARGS+=	--sendmail-dir "${LOCAL
 CONFIGURE_ARGS+=	--sendmail-dir "/usr"
 .endif
 
-.if ${PORT_OPTIONS:MSMTP_AFTER_POP3}
-CONFIGURE_ARGS+=	--with-popauth
-.endif
-
-.if ${PORT_OPTIONS:MPAM}
-CONFIGURE_ARGS+=	--with-pam
-.endif
-
-.if ${PORT_OPTIONS:MLIBSPF}
-BUILD_DEPENDS+=	${LOCALBASE}/lib/libspf.a:${PORTSDIR}/mail/libspf
-CONFIGURE_ARGS+=	--with-libspf ${LOCALBASE}
-CFLAGS+=	-I${LOCALBASE}/include
-LDFLAGS+=	-L${LOCALBASE}/lib
-.endif
-
 post-extract:
 	${MV} ${WRKDIR}/${PORTNAME} ${WRKSRC}
 
@@ -76,14 +70,9 @@ pre-configure:
 		-e "s=/usr/local/=${PREFIX}/=" \
 		${WRKSRC}/Makefile.tmpl
 
-xpost-configure:
-	${REINPLACE_CMD} \
-		-e "s| install-ipfwmtad | |" \
-		${WRKSRC}/Makefile
-
 post-install:
 .for i in ${BINFILES}
-	${INSTALL_SCRIPT} ${WRKSRC}/${i} ${PREFIX}/bin/
+	${INSTALL_SCRIPT} ${WRKSRC}/${i} ${STAGEDIR}${PREFIX}/bin/
 .endfor
 .if ${PORT_OPTIONS:MDOCS}
 	${MKDIR} ${STAGEDIR}${DOCSDIR}

Modified: head/mail/spamilter/files/patch-Makefile.tmpl
==============================================================================
--- head/mail/spamilter/files/patch-Makefile.tmpl	Thu Dec  5 07:59:09 2013	(r335655)
+++ head/mail/spamilter/files/patch-Makefile.tmpl	Thu Dec  5 08:39:07 2013	(r335656)
@@ -1,5 +1,5 @@
---- Makefile.tmpl.orig	Sun Nov 27 21:52:05 2005
-+++ Makefile.tmpl	Sat Dec 17 09:14:03 2005
+--- Makefile.tmpl.orig	2005-11-27 21:52:05.000000000 +0100
++++ Makefile.tmpl	2013-12-05 09:24:17.000000000 +0100
 @@ -26,17 +26,17 @@
  <ALL>INCLUDEDIR =	-I. -I${SMDIR}/include <WITH_LIBSPF -I${LIBSPFINC}>
  <INCDIRS>INCLUDEDIR +=		<X>
@@ -22,16 +22,36 @@
  <OpenBSD>LIBDIRS =	-L${SMDIR}/libmilter
  <SunOS>LIBDIRS =	-L${SMOBJDIR}/libmilter -L${SMOBJDIR}/libsmutil -L/usr/lib
  <Linux>LIBDIRS =	-L${SMOBJDIR}/libmilter -L${SMOBJDIR}/libsmutil -L/usr/lib
-@@ -62,7 +62,7 @@
+@@ -62,45 +62,45 @@
  <ALL>clean:
  <ALL>	rm -f *.o *core spamilter dnsblchk dnsblupd mxlookup iflookup <INC_FreeBSD ipfwmtad>
  <ALL>
 -<ALL>install: spamilter install-dnsblchk install-dnsblupd install-mxlookup <INC_FreeBSD install-ipfwmtad install-startup>
+-<ALL>	install -c -m ${BINMODE} -g ${BINGRP} -o ${BINOWN} spamilter ${BINDIR}
 +<ALL>install: spamilter install-dnsblchk install-dnsblupd install-mxlookup <INC_FreeBSD install-ipfwmtad>
- <ALL>	install -c -m ${BINMODE} -g ${BINGRP} -o ${BINOWN} spamilter ${BINDIR}
++<ALL>	install -c -m ${BINMODE} -g ${BINGRP} -o ${BINOWN} spamilter ${DESTDIR}${BINDIR}
  <ALL>
  <ALL>install-dnsblchk: dnsblchk
-@@ -84,23 +84,23 @@
+-<ALL>	install -c -m ${BINMODE} -g ${BINGRP} -o ${BINOWN} dnsblchk ${BINDIR}
++<ALL>	install -c -m ${BINMODE} -g ${BINGRP} -o ${BINOWN} dnsblchk ${DESTDIR}${BINDIR}
+ <ALL>
+ <ALL>install-dnsblupd: dnsblupd
+-<ALL>	install -c -m ${BINMODE} -g ${BINGRP} -o ${BINOWN} dnsblupd ${BINDIR}
++<ALL>	install -c -m ${BINMODE} -g ${BINGRP} -o ${BINOWN} dnsblupd ${DESTDIR}${BINDIR}
+ <ALL>
+ <ALL>install-mxlookup: mxlookup
+-<ALL>	install -c -m ${BINMODE} -g ${BINGRP} -o ${BINOWN} mxlookup ${BINDIR}
++<ALL>	install -c -m ${BINMODE} -g ${BINGRP} -o ${BINOWN} mxlookup ${DESTDIR}${BINDIR}
+ <ALL>
+ <FreeBSD>install-ipfwmtad: ipfwmtad
+-<FreeBSD>	install -c -m 0500 -g ${BINGRP} -o ${BINOWN} ipfwmtad ${BINDIR}
++<FreeBSD>	install -c -m 0500 -g ${BINGRP} -o ${BINOWN} ipfwmtad ${DESTDIR}${BINDIR}
+ <FreeBSD>
+ <FreeBSD>install-startup:
+-<FreeBSD>	if [ ! -e ${RCDIR}/${RCSHELL} ]; then install -c -m ${RCMODE} -g ${BINGRP} -o ${BINOWN} ${RCSHELL} ${RCDIR}; fi
++<FreeBSD>	if [ ! -e ${RCDIR}/${RCSHELL} ]; then install -c -m ${RCMODE} -g ${BINGRP} -o ${BINOWN} ${RCSHELL} ${DESTDIR}${RCDIR}; fi
+ <FreeBSD>
+ <ALL>tar: clean
  <ALL>	cd ..; tar --exclude CVS -cfvz spamilter.tgz spamilter/*
  <ALL>
  <ALL>spamilter: Makefile ${SRCS} <NOT_FreeBSD ${NRSRCS}> spamilter.o ${OBJS} <NOT_FreeBSD ${NROBJS}> <WITH_LIBSPF ${LIBSPFDIR}/libspf.a> ${INCLUDES}



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201312050839.rB58d78W029516>