diff options
author | Volker Stolz <vs@FreeBSD.org> | 2004-05-22 07:52:58 +0000 |
---|---|---|
committer | Volker Stolz <vs@FreeBSD.org> | 2004-05-22 07:52:58 +0000 |
commit | 40b691474705c85a2ea32cc5f756f7d0b4e9912c (patch) | |
tree | e338c4133d120cf170b8ca6c302f9ddd1a1ec294 /mail/libspf | |
parent | 725ab6d62d18e4c59f8f31a563d729c0974ca182 (diff) | |
download | ports-40b691474705c85a2ea32cc5f756f7d0b4e9912c.tar.gz ports-40b691474705c85a2ea32cc5f756f7d0b4e9912c.zip |
Add libspf 0.25.b, sender Policy Framework (SPF) library and client.
PR: ports/64265
Submitted by: Daniel Roethlisberger <daniel@roe.ch>
Notes
Notes:
svn path=/head/; revision=109686
Diffstat (limited to 'mail/libspf')
-rw-r--r-- | mail/libspf/Makefile | 103 | ||||
-rw-r--r-- | mail/libspf/distinfo | 2 | ||||
-rw-r--r-- | mail/libspf/files/patch-spf.h | 10 | ||||
-rw-r--r-- | mail/libspf/pkg-descr | 8 | ||||
-rw-r--r-- | mail/libspf/pkg-message | 6 | ||||
-rw-r--r-- | mail/libspf/pkg-plist | 5 |
6 files changed, 134 insertions, 0 deletions
diff --git a/mail/libspf/Makefile b/mail/libspf/Makefile new file mode 100644 index 000000000000..2f6ae4dee298 --- /dev/null +++ b/mail/libspf/Makefile @@ -0,0 +1,103 @@ +# New ports collection makefile for: libspf +# Date created: 28 February 2004 +# Whom: Daniel Roethlisberger <daniel@roe.ch> +# +# $FreeBSD$ +# + +PORTNAME= libspf +PORTVERSION= 0.25.b +CATEGORIES= mail +MASTER_SITES= http://www.libspf.org/files/ +DISTNAME= ${PORTNAME}.${PORTVERSION}eta + +MAINTAINER= daniel@roe.ch +COMMENT= Sender Policy Framework (SPF) library and client + +# Require getopt_long_only - USE_GETOPT_LONG is *not* sufficient +LIB_DEPENDS= gnugetopt.1:${PORTSDIR}/devel/libgnugetopt + +USE_BZIP2= yes +WRKSRC= ${WRKDIR}/${PORTNAME}.25 +USE_GMAKE= yes +USE_REINPLACE= yes +INSTALLS_SHLIB= yes +LIBSPF_REV= 1 +PLIST_SUB= PORTNAME=${PORTNAME} LIBSPF_REV=${LIBSPF_REV} +MAKE_ENV= CPPFLAGS="${CPPFLAGS} -I${LOCALBASE}/include" \ + LDFLAGS="${LDFLAGS} -L${LOCALBASE}/lib -L${WRKSRC}" + +# Supported tunables: +# +# WITH_SPF_LOG_FILE=/foo/bar enable transaction logfile (if unset: no log) +# WITH_SPF_DEBUG=yes enable debugging +# WITH_SPF_DEBUG_FILE=/foo/baz enable debug logfile (if unset: stdout/stderr) + +.if defined(WITH_SPF_LOG_FILE) +SPF_LOG_FILE= ${WITH_SPF_LOG_FILE} +.else +SPF_LOG_FILE= /dev/null +.endif + +.if defined(WITH_SPF_DEBUG) +SPF_CFLAGS= -ggdb -DDEBUG -D_SPF_DEBUG +.if defined(WITH_SPF_DEBUG_FILE) +SPF_CFLAGS+= -D_SPF_DEBUG_LOGFILE +.endif +.endif + +.if defined(WITH_SPF_DEBUG_FILE) +SPF_DEBUG_FILE= ${WITH_SPF_DEBUG_FILE} +.else +SPF_DEBUG_FILE= /dev/null +.endif + +SPF_CFLAGS+= -DDEBUG_LOG_FILE=\\\"${SPF_DEBUG_FILE}\\\" \ + -DOUTPUT_LOG_FILE=\\\"${SPF_LOG_FILE}\\\" + +# This is all a bit messy, but given the inconvenient original Makefile, +# this seems to be the best way to make this port work in this version. +# The author of libspf is working on autotools support, so this ugliness +# should have an end soon. +post-patch: + @${REINPLACE_CMD} \ + -e 's,^CFLAGS:=.*,CFLAGS+=-Wall -D_BSD_SOURCE ${SPF_CFLAGS},' \ + -e 's/^CPPFLAGS:=/#CPPFLAGS:=/' \ + -e 's/^LDFLAGS:=/#LDFLAGS:=/' \ + -e 's/make/gmake/g' \ + -e 's/-lresolv//g' \ + -e 's/libspf.a : -lc/libspf.a :/g' \ + -e 's/libspf\.so\.1\.0\.1/libspf.so.${LIBSPF_REV}/g' \ + -e 's/-soname,libspf\.so\.1/-soname,libspf.so.${LIBSPF_REV}/g' \ + ${WRKSRC}/Makefile + @${REINPLACE_CMD} \ + -e 's/^CFLAGS:=/#CFLAGS:=/' \ + -e 's/^CPPFLAGS:=/#CPPFLAGS:=/' \ + -e 's/^LDFLAGS:=/#LDFLAGS:=/' \ + -e 's/make/gmake/g' \ + -e 's/\(-o spfquery ..\)/\1 -lgnugetopt/g' \ + -e 's/-o spfquery/-o spfquery-${PORTNAME}/g' \ + ${WRKSRC}/tools/Makefile + @${REINPLACE_CMD} \ + -e 's/#include "error.h"//' \ + ${WRKSRC}/main.c ${WRKSRC}/dns.c + @${REINPLACE_CMD} \ + -e 's,\(#define DEBUG_LOG_FILE.*\),/* \1 */,' \ + -e 's,\(#define OUTPUT_LOG_FILE.*\),/* \1 */,' \ + ${WRKSRC}/util.h + @${REINPLACE_CMD} \ + -e 's/spfquery /spfquery-${PORTNAME} /' \ + ${WRKSRC}/tools/spfquery.c + +post-build: + @(cd ${WRKSRC}/tools; ${SETENV} ${MAKE_ENV} ${GMAKE} shared ) + +do-install: + ${INSTALL_DATA} ${WRKSRC}/spf.h ${PREFIX}/include + ${INSTALL_DATA} ${WRKSRC}/libspf.a ${PREFIX}/lib + ${INSTALL_DATA} ${WRKSRC}/libspf.so.${LIBSPF_REV} ${PREFIX}/lib + (cd ${PREFIX}/lib ; ${LN} -sf libspf.so.${LIBSPF_REV} libspf.so) + ${INSTALL_PROGRAM} ${WRKSRC}/tools/spfquery-${PORTNAME} ${PREFIX}/bin + @${CAT} ${PKGMESSAGE} + +.include <bsd.port.mk> diff --git a/mail/libspf/distinfo b/mail/libspf/distinfo new file mode 100644 index 000000000000..c2ac8f32314f --- /dev/null +++ b/mail/libspf/distinfo @@ -0,0 +1,2 @@ +MD5 (libspf.0.25.beta.tar.bz2) = 79b3a37888082428ed86dfa0f612a6f2 +SIZE (libspf.0.25.beta.tar.bz2) = 61406 diff --git a/mail/libspf/files/patch-spf.h b/mail/libspf/files/patch-spf.h new file mode 100644 index 000000000000..1e2e1cf1c874 --- /dev/null +++ b/mail/libspf/files/patch-spf.h @@ -0,0 +1,10 @@ +--- spf.h.orig Fri May 14 18:49:30 2004 ++++ spf.h Fri May 21 17:13:30 2004 +@@ -47,6 +47,7 @@ + #define _SPF_H 1 + + #include <sys/types.h> /* typedefs */ ++#include <netinet/in.h> + #include <arpa/inet.h> /* in_addr struct */ + + __BEGIN_DECLS diff --git a/mail/libspf/pkg-descr b/mail/libspf/pkg-descr new file mode 100644 index 000000000000..a4c7151d388b --- /dev/null +++ b/mail/libspf/pkg-descr @@ -0,0 +1,8 @@ +Sender Policy Framework (SPF) library and client in C. +SPF is a standard under development for email envelope sender +verification. Domain owners can specify who is qualified to send +mail for the domain by publishing SPF TXT records in DNS. +Read all about SPF at http://spf.pobox.com/ + +Author: James Couzens <jcouzens@6o4.ca> +WWW: http://www.libspf.org/ diff --git a/mail/libspf/pkg-message b/mail/libspf/pkg-message new file mode 100644 index 000000000000..b416d4fcc601 --- /dev/null +++ b/mail/libspf/pkg-message @@ -0,0 +1,6 @@ +----------------------------------------------------------------------- +Note: This port installs the SPF userspace tools with a filename suffix + of -libspf in order to avoid conflicts with other SPF ports + providing tools of the same name. + Please create convenience symlinks manually, if desired. +----------------------------------------------------------------------- diff --git a/mail/libspf/pkg-plist b/mail/libspf/pkg-plist new file mode 100644 index 000000000000..00abd71a5108 --- /dev/null +++ b/mail/libspf/pkg-plist @@ -0,0 +1,5 @@ +include/spf.h +lib/libspf.a +lib/libspf.so +lib/libspf.so.%%LIBSPF_REV%% +bin/spfquery-%%PORTNAME%% |