View | Details | Raw Unified | Return to bug 83279
Collapse All | Expand All

(-)libspf/Makefile (-84 / +56 lines)
Lines 6-106 Link Here
6
#
6
#
7
7
8
PORTNAME=	libspf
8
PORTNAME=	libspf
9
PORTVERSION=	0.25.b
9
PORTVERSION=	${DISTVERSION:S/-/./}
10
CATEGORIES=	mail
10
CATEGORIES=	mail
11
MASTER_SITES=	http://www.libspf.org/files/
11
MASTER_SITES=	http://www.libspf.org/files/src/
12
DISTNAME=	${PORTNAME}.${PORTVERSION}eta
13
12
14
DEPRECATED=	"stale, try mail/libspf2"
13
MAINTAINER=	marcus@corp.grupos.com.br
15
EXPIRATION_DATE=2005-07-31
16
17
MAINTAINER=	ports@FreeBSD.org
18
COMMENT=	Sender Policy Framework (SPF) library and client
14
COMMENT=	Sender Policy Framework (SPF) library and client
19
15
20
NOT_FOR_ARCHS=	amd64 alpha
16
DISTVERSION=	1.0.0-p3
21
17
22
USE_GETOPT_LONG=yes
23
USE_BZIP2=	yes
18
USE_BZIP2=	yes
24
WRKSRC=		${WRKDIR}/${PORTNAME}.25
19
USE_LIBTOOL_VER=	15
25
USE_GMAKE=	yes
20
HAS_CONFIGURE=	yes
26
USE_REINPLACE=	yes
21
CONFIGURE_ARGS=	--prefix=${PREFIX}
27
INSTALLS_SHLIB=	yes
22
28
LIBSPF_REV=	1
23
OPTIONS=	RFC_RECURSION	"Change SPF recursion to 20 (as per RFC)"	no \
29
PLIST_SUB=	PORTNAME=${PORTNAME} LIBSPF_REV=${LIBSPF_REV}
24
		LOGFILE_STATS	"Enables logfile stats"				no \
30
LDFLAGS+=	-L${WRKSRC}
25
		DEBUG		"Enables debug option"				no
31
26
32
# Supported tunables:
27
.include <bsd.port.pre.mk>
33
#
34
# WITH_SPF_LOG_FILE=/foo/bar	enable transaction logfile (if unset: no log)
35
# WITH_SPF_DEBUG=yes		enable debugging
36
# WITH_SPF_DEBUG_FILE=/foo/baz	enable debug logfile (if unset: stdout/stderr)
37
38
.if defined(WITH_SPF_LOG_FILE)
39
SPF_LOG_FILE=	${WITH_SPF_LOG_FILE}
40
.else
41
SPF_LOG_FILE=	/dev/null
42
.endif
43
28
44
.if defined(WITH_SPF_DEBUG)
29
.if !defined(WITHOUT_RFC_RECURSION)
45
SPF_CFLAGS=	-ggdb -DDEBUG -D_SPF_DEBUG
30
CONFIGURE_ARGS+=	--enable-rfc-recursion
46
.if defined(WITH_SPF_DEBUG_FILE)
47
SPF_CFLAGS+=	-D_SPF_DEBUG_LOGFILE
48
.endif
31
.endif
32
33
.if !defined(WITHOUT_LOGFILE_STATS)
34
CONFIGURE_ARGS+=	--enable-logfile-stats
49
.endif
35
.endif
50
36
51
.if defined(WITH_SPF_DEBUG_FILE)
37
.if !defined(WITHOUT_DEBUG)
52
SPF_DEBUG_FILE=	${WITH_SPF_DEBUG_FILE}
38
CONFIGURE_ARGS+=	--enable-debug
53
.else
54
SPF_DEBUG_FILE=	/dev/null
55
.endif
39
.endif
56
40
57
SPF_CFLAGS+=	-DDEBUG_LOG_FILE=\\\"${SPF_DEBUG_FILE}\\\" \
41
.if !defined(NOPORTDOCS)
58
		-DOUTPUT_LOG_FILE=\\\"${SPF_LOG_FILE}\\\"
42
PORTDOCS=	*
43
.endif
59
44
60
# This is all a bit messy, but given the inconvenient original Makefile,
45
post-install:
61
# this seems to be the best way to make this port work in this version.
46
.if !defined(NOPORTDOCS)
62
# The author of libspf is working on autotools support, so this ugliness
47
	@${MKDIR} ${DOCSDIR}
63
# should have an end soon.
48
	@${FIND} ${WRKSRC}/docs -type d -name CVS | ${XARGS} ${RM} -rf
64
post-patch:
49
.for i in docs docs/API docs/API/doxygen docs/API/doxygen/html docs/RFC docs/qmail \
65
	@${REINPLACE_CMD} \
50
	docs/qmail/1.03 docs/qmail/1.04 docs/qmail/1.05 docs/spfqtool docs/Postfix \
66
	    -e 's,^CFLAGS:=.*,CFLAGS+=-Wall -D_BSD_SOURCE ${SPF_CFLAGS},' \
51
	docs/Postfix/2.1.x docs/Sendmail docs/Sendmail/8.12.x docs/Sendmail/8.13.x \
67
	    -e 's/^CPPFLAGS:=/#CPPFLAGS:=/' \
52
	docs/Courier-MTA docs/history
68
	    -e 's/^LDFLAGS:=/#LDFLAGS:=/' \
53
	@${MKDIR} ${DOCSDIR}/${i}
69
	    -e 's/make /${GMAKE} /g' \
54
	@for f in `${FIND} ${WRKSRC}/${i} ! -type d -maxdepth 1`; do \
70
	    -e 's/-lresolv//g' \
55
		${INSTALL_DATA} $${f} ${DOCSDIR}/${i}; \
71
	    -e 's/libspf.a : -lc/libspf.a :/g' \
56
	done
72
	    -e 's/libspf\.so\.1\.0\.1/libspf.so.${LIBSPF_REV}/g' \
57
.endfor
73
	    -e 's/-soname,libspf\.so\.1/-soname,libspf.so.${LIBSPF_REV}/g' \
58
.endif
74
	    ${WRKSRC}/Makefile
59
	@${MKDIR} ${EXAMPLESDIR}
75
	@${REINPLACE_CMD} \
60
	@${FIND} ${WRKSRC}/examples -type d -name CVS | ${XARGS} ${RM} -rf
76
	    -e 's,^CFLAGS:=,CFLAGS:=${CFLAGS} ${CPPFLAGS},' \
61
.for i in examples/qmail examples/qmail/control examples/Sendmail
77
	    -e 's,^CPPFLAGS:=,CPPFLAGS:=${CPPFLAGS},' \
62
	@${MKDIR} ${EXAMPLESDIR}/${i}
78
	    -e 's,^LDFLAGS:=.*,LDFLAGS=${LDFLAGS},' \
63
	@for f in `${FIND} ${WRKSRC}/${i} ! -type d -maxdepth 1`; do \
79
	    -e 's/make /${GMAKE} /g' \
64
		${INSTALL_DATA} $${f} ${EXAMPLESDIR}/${i}; \
80
	    -e 's/-o spfquery/-o spfquery-${PORTNAME}/g' \
65
	done
81
	    ${WRKSRC}/tools/Makefile
66
.endfor
82
	@${REINPLACE_CMD} \
67
	@${MKDIR} ${DATADIR}
83
	    -e 's/#include "error.h"//' \
68
	@${FIND} ${WRKSRC}/patches -type d -name CVS | ${XARGS} ${RM} -rf
84
	    ${WRKSRC}/main.c ${WRKSRC}/dns.c
69
.for i in patches patches/qmail patches/qmail/1.03 patches/qmail/1.05 patches/Postfix \
85
	@${REINPLACE_CMD} \
70
	patches/Postfix/2.1.x patches/Sendmail patches/Sendmail/8.12.x patches/Sendmail/8.13.x \
86
	    -e 's,\(#define DEBUG_LOG_FILE.*\),/* \1 */,' \
71
	patches/Courier-MTA
87
	    -e 's,\(#define OUTPUT_LOG_FILE.*\),/* \1 */,' \
72
	@${MKDIR} ${DATADIR}/${i}
88
	    ${WRKSRC}/util.h
73
	@for f in `${FIND} ${WRKSRC}/${i} ! -type d -maxdepth 1`; do \
89
	@${REINPLACE_CMD} \
74
		${INSTALL_DATA} $${f} ${DATADIR}/${i}; \
90
	    -e 's/spfquery /spfquery-${PORTNAME} /' \
75
	done
91
	    -e 's/getopt_long_only/getopt_long/g' \
76
.endfor
92
	    -E -e '/stderr/s/ -([a-z]{2,})/ --\1/g' \
93
	    ${WRKSRC}/tools/spfquery.c
94
95
post-build:
96
	@(cd ${WRKSRC}/tools; ${SETENV} ${MAKE_ENV} ${GMAKE} shared )
97
98
do-install:
99
	${INSTALL_DATA} ${WRKSRC}/spf.h ${PREFIX}/include
100
	${INSTALL_DATA} ${WRKSRC}/libspf.a ${PREFIX}/lib
101
	${INSTALL_DATA} ${WRKSRC}/libspf.so.${LIBSPF_REV} ${PREFIX}/lib
102
	(cd ${PREFIX}/lib ; ${LN} -sf libspf.so.${LIBSPF_REV} libspf.so)
103
	${INSTALL_PROGRAM} ${WRKSRC}/tools/spfquery-${PORTNAME} ${PREFIX}/bin
104
	@${CAT} ${PKGMESSAGE}
105
77
106
.include <bsd.port.mk>
78
.include <bsd.port.post.mk>
(-)libspf/distinfo (-2 / +2 lines)
Lines 1-2 Link Here
1
MD5 (libspf.0.25.beta.tar.bz2) = 79b3a37888082428ed86dfa0f612a6f2
1
MD5 (libspf-1.0.0-p3.tar.bz2) = 8cc31c6f3e79e350b941b04ca7bfb145
2
SIZE (libspf.0.25.beta.tar.bz2) = 61406
2
SIZE (libspf-1.0.0-p3.tar.bz2) = 1038651
(-)libspf/files/patch-spf.h (-10 lines)
Lines 1-10 Link Here
1
--- spf.h.orig	Fri May 14 18:49:30 2004
2
+++ spf.h	Fri May 21 17:13:30 2004
3
@@ -47,6 +47,7 @@
4
 #define	_SPF_H 1
5
 
6
 #include <sys/types.h>    /* typedefs */
7
+#include <netinet/in.h>
8
 #include <arpa/inet.h>    /* in_addr struct */
9
 
10
 __BEGIN_DECLS
(-)libspf/pkg-message (-6 lines)
Lines 1-6 Link Here
1
-----------------------------------------------------------------------
2
Note: This port installs the SPF userspace tools with a filename suffix
3
      of -libspf in order to avoid conflicts with other SPF ports
4
      providing tools of the same name.
5
      Please create convenience symlinks manually, if desired.
6
-----------------------------------------------------------------------
(-)libspf/pkg-plist (-2 / +54 lines)
Lines 1-5 Link Here
1
bin/spfqtool
2
bin/spfqtool_static
3
include/_stdint.h
1
include/spf.h
4
include/spf.h
5
lib/libspf-1.0.so
6
lib/libspf-1.0.so.0
2
lib/libspf.a
7
lib/libspf.a
3
lib/libspf.so
8
lib/libspf.so
4
lib/libspf.so.%%LIBSPF_REV%%
9
%%EXAMPLESDIR%%/examples/Sendmail/sendmail.cf
5
bin/spfquery-%%PORTNAME%%
10
%%EXAMPLESDIR%%/examples/Sendmail/sendmail.mc.example
11
%%EXAMPLESDIR%%/examples/Sendmail/spf.m4
12
%%EXAMPLESDIR%%/examples/qmail/control/spfaction
13
%%EXAMPLESDIR%%/examples/qmail/control/spfbestguess
14
%%EXAMPLESDIR%%/examples/qmail/control/spfdebugstate
15
%%EXAMPLESDIR%%/examples/qmail/control/spfexplainstate
16
%%EXAMPLESDIR%%/examples/qmail/control/spfexplanation
17
%%EXAMPLESDIR%%/examples/qmail/control/spfguessstate
18
%%EXAMPLESDIR%%/examples/qmail/control/spfheaderstate
19
%%EXAMPLESDIR%%/examples/qmail/control/spftarpit
20
%%EXAMPLESDIR%%/examples/qmail/control/spftarpittime
21
%%EXAMPLESDIR%%/examples/qmail/control/spftrustedforwarder
22
%%EXAMPLESDIR%%/examples/qmail/control/spftrustedstate
23
%%DATADIR%%/patches/Courier-MTA/courier-0.45.4-spf.diff
24
%%DATADIR%%/patches/Postfix/2.1.x/postfix-2.1.4-libspf-1.0-RC6.diff
25
%%DATADIR%%/patches/Postfix/README
26
%%DATADIR%%/patches/README
27
%%DATADIR%%/patches/Sendmail/8.12.x/sendmail-8.12.10-libspf.0.24.diff
28
%%DATADIR%%/patches/Sendmail/8.12.x/sendmail-8.12.11-libspf.0.25.diff
29
%%DATADIR%%/patches/Sendmail/8.12.x/sendmail-8.12.11-libspf.0.25.fixed.diff
30
%%DATADIR%%/patches/Sendmail/8.13.x/sendmail-8.13.0-libspf-1.0-RC3.diff
31
%%DATADIR%%/patches/Sendmail/8.13.x/sendmail-8.13.1-libspf-1.0-RC5.diff
32
%%DATADIR%%/patches/Sendmail/8.13.x/sendmail-8.13.1-libspf-1.0-RC6.diff
33
%%DATADIR%%/patches/Sendmail/8.13.x/sendmail-8.13.4-libspf-1.0.diff
34
%%DATADIR%%/patches/Sendmail/README
35
%%DATADIR%%/patches/qmail/1.03/qmail-1.03.solaris.patch
36
%%DATADIR%%/patches/qmail/1.05/Makefile-dynamic-1.05.diff
37
%%DATADIR%%/patches/qmail/1.05/Makefile-static-1.05.diff
38
%%DATADIR%%/patches/qmail/1.05/netqmail-1.05-libspf-0.25.diff
39
%%DATADIR%%/patches/qmail/1.05/netqmail-1.05-libspf-1.0.0-RC5.diff
40
%%DATADIR%%/patches/qmail/1.05/netqmail-1.05-libspf-1.0.0-RC6.diff
41
%%DATADIR%%/patches/qmail/README
42
@dirrm %%DATADIR%%/patches/qmail/1.05
43
@dirrm %%DATADIR%%/patches/qmail/1.03
44
@dirrm %%DATADIR%%/patches/qmail
45
@dirrm %%DATADIR%%/patches/Sendmail/8.13.x
46
@dirrm %%DATADIR%%/patches/Sendmail/8.12.x
47
@dirrm %%DATADIR%%/patches/Sendmail
48
@dirrm %%DATADIR%%/patches/Postfix/2.1.x
49
@dirrm %%DATADIR%%/patches/Postfix
50
@dirrm %%DATADIR%%/patches/Courier-MTA
51
@dirrm %%DATADIR%%/patches
52
@dirrm %%DATADIR%%
53
@dirrm %%EXAMPLESDIR%%/examples/qmail/control
54
@dirrm %%EXAMPLESDIR%%/examples/qmail
55
@dirrm %%EXAMPLESDIR%%/examples/Sendmail
56
@dirrm %%EXAMPLESDIR%%/examples
57
@dirrm %%EXAMPLESDIR%%

Return to bug 83279