Skip site navigation (1)Skip section navigation (2)
Date:      Thu,  9 Sep 2010 12:24:41 +0200 (CEST)
From:      Martin Matuska <mm@FreeBSD.org>
To:        FreeBSD-gnats-submit@FreeBSD.org
Cc:        sahil@FreeBSD.org
Subject:   ports/150428: [PATCH] mail/postfix: reintroduce SPF support
Message-ID:  <20100909102441.34376DDE5C@mail2.vx.sk>
Resent-Message-ID: <201009091030.o89AU118060773@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         150428
>Category:       ports
>Synopsis:       [PATCH] mail/postfix: reintroduce SPF support
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Thu Sep 09 10:30:01 UTC 2010
>Closed-Date:
>Last-Modified:
>Originator:     Martin Matuska
>Release:        FreeBSD 8.1-STABLE amd64
>Organization:
>Environment:
System: FreeBSD neo.vx.sk 8.1-STABLE FreeBSD 8.1-STABLE #0 r210674M: Sat Jul 31 12:28:28 CEST
>Description:
Reintroduce SPF support with updated patch for Postfix 2.7.1.

Original patch (old and outdated):
http://www.ipnet6.org/postfix/download/postfix-libspf2-2.2.0-5.patch

Updated patch for new postfix API changes and libspf2 1.2.x API:
http://www.linuxrulz.org/nkukard/postfix/postfix-2.3/postfix-2.3.2_libspf2-1.2.x-20060819.patch

Port maintainer (sahil@FreeBSD.org) is cc'd.

Generated with FreeBSD Port Tools 0.99
>How-To-Repeat:
>Fix:

--- postfix-2.7.1_1,1.patch begins here ---
Index: Makefile
===================================================================
RCS file: /home/pcvs/ports/mail/postfix/Makefile,v
retrieving revision 1.158
diff -u -r1.158 Makefile
--- Makefile	10 Jun 2010 02:25:30 -0000	1.158
+++ Makefile	9 Sep 2010 10:19:28 -0000
@@ -7,6 +7,7 @@
 
 PORTNAME=	postfix
 PORTVERSION=	2.7.1
+PORTREVISION=	1
 PORTEPOCH=	1
 CATEGORIES=	mail ipv6
 MASTER_SITES=	ftp://ftp.porcupine.org/mirrors/postfix-release/official/ \
@@ -32,7 +33,7 @@
 
 # back compat pull in settings from POSTFIX_OPTIONS for convenience when
 # make config is run (happens first time port is built, too)
-.for o in SASL2 SASLKRB5 SASLKRB5MIT TLS BDB MySQL PgSQL OpenLDAP CDB NIS VDA Test
+.for o in SASL2 SASLKRB5 SASLKRB5MIT TLS BDB MySQL PgSQL OpenLDAP CDB NIS VDA Test SPF
 STATUS_${o}=off
 .endfor
 .if defined(POSTFIX_OPTIONS)
@@ -55,6 +56,7 @@
 		NIS		"NIS maps lookups"					${STATUS_NIS} \
 		VDA		"VDA (Virtual Delivery Agent 32Bit)"			${STATUS_VDA} \
 		TEST		"SMTP/LMTP test server and generator"			${STATUS_Test} \
+		SPF		"SPF support (via libspf2 1.2.x)"			${STATUS_SPF} \
 		INST_BASE	"Install into /usr and /etc/postfix"			off
 
 .include <bsd.port.options.mk>
@@ -150,6 +152,19 @@
 POSTFIX_AUXLIBS+=	-L${OPENSSLLIB} ${LDFLAGS} -lssl -lcrypto
 .endif
 
+.if defined(WITH_SPF)
+LIB_DEPENDS+=		spf2.3:${PORTSDIR}/mail/libspf2
+PATCH_SITES+=		${MASTER_SITE_LOCAL}
+PATCH_SITE_SUBDIR=	mm
+PATCHFILES+=		postfix-2.7.1-libspf2-1.2.x.patch.gz
+PATCH_DIST_STRIP=	-p1
+POSTFIX_CCARGS+=	-DHAVE_NS_TYPE -I${LOCALBASE}/include
+POSTFIX_AUXLIBS+=	-L${LOCALBASE}/lib -lspf2
+PLIST_SUB+=	SPF=""
+.else
+PLIST_SUB+=	SPF="@comment "
+.endif
+
 .if defined(WITH_BDB)
 USE_BDB=		yes
 POSTFIX_CCARGS+=	-I${BDB_INCLUDE_DIR}
@@ -295,6 +310,12 @@
 	@${ECHO} '$$html_directory/$f:f:root:-:644' \
 		>> ${WRKSRC}/conf/postfix-files
 .endfor
+.if defined(WITH_SPF)
+	@${ECHO} '$$readme_directory/SPF_README:f:root:-:644' \
+		>> ${WRKSRC}/conf/postfix-files
+	@${REINPLACE_CMD} -E -e '${REINPLACE}' \
+		${WRKSRC}/README_FILES/SPF_README
+.endif
 .if defined(WITH_VDA)
 	@${ECHO} '$$readme_directory/VDA_README:f:root:-:644' \
 		>> ${WRKSRC}/conf/postfix-files
Index: distinfo
===================================================================
RCS file: /home/pcvs/ports/mail/postfix/distinfo,v
retrieving revision 1.107
diff -u -r1.107 distinfo
--- distinfo	10 Jun 2010 02:25:30 -0000	1.107
+++ distinfo	9 Sep 2010 10:19:28 -0000
@@ -1,6 +1,9 @@
 MD5 (postfix/postfix-2.7.1.tar.gz) = b7a5c3ccd309156a65d6f8d2683d4fa1
 SHA256 (postfix/postfix-2.7.1.tar.gz) = 12301aa8dae18d333c8c96dbf7673f8f05139f10406e7afe278cfd4a1f132df0
 SIZE (postfix/postfix-2.7.1.tar.gz) = 3418747
+MD5 (postfix/postfix-2.7.1-libspf2-1.2.x.patch.gz) = 28261fa4db230433cade2ebbee629a18
+SHA256 (postfix/postfix-2.7.1-libspf2-1.2.x.patch.gz) = 98e39c8494bb20a2e790ca3e1452eec94446eb858c628e33bf4d3730fb31150d
+SIZE (postfix/postfix-2.7.1-libspf2-1.2.x.patch.gz) = 7074
 MD5 (postfix/postfix-2.6.5-vda-ng.patch.gz) = 43e54d0a1a016b90d15a1bd231e6fa38
 SHA256 (postfix/postfix-2.6.5-vda-ng.patch.gz) = e1c04e9d268dc84832334997e1f593af9877dbd5030708280427a0dc4452e797
 SIZE (postfix/postfix-2.6.5-vda-ng.patch.gz) = 12435
Index: pkg-plist
===================================================================
RCS file: /home/pcvs/ports/mail/postfix/pkg-plist,v
retrieving revision 1.32
diff -u -r1.32 pkg-plist
--- pkg-plist	28 Mar 2010 18:41:40 -0000	1.32
+++ pkg-plist	9 Sep 2010 10:19:28 -0000
@@ -132,6 +132,7 @@
 %%PORTDOCS%%%%DOCSDIR%%/SMTPD_PROXY_README.html
 %%PORTDOCS%%%%DOCSDIR%%/SOHO_README
 %%PORTDOCS%%%%DOCSDIR%%/SOHO_README.html
+%%SPF%%%%PORTDOCS%%%%DOCSDIR%%/SPF_README
 %%PORTDOCS%%%%DOCSDIR%%/STANDARD_CONFIGURATION_README
 %%PORTDOCS%%%%DOCSDIR%%/STANDARD_CONFIGURATION_README.html
 %%PORTDOCS%%%%DOCSDIR%%/STRESS_README
--- postfix-2.7.1_1,1.patch ends here ---

>Release-Note:
>Audit-Trail:
>Unformatted:



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