summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorschmonz <schmonz@pkgsrc.org>2007-04-11 14:50:37 +0000
committerschmonz <schmonz@pkgsrc.org>2007-04-11 14:50:37 +0000
commitc84d21987b814b027369eb17afb0283860ba0d06 (patch)
tree5fcf8779c1448970d64ad27fbbc87f7e53a191fd
parent202a7895b16bcb130d861d6ceaedef6295e381a1 (diff)
downloadpkgsrc-c84d21987b814b027369eb17afb0283860ba0d06.tar.gz
Update to 2.4.0. From the changelog:
Added search_ip_file() to search files for IP addresses and allow wildcards, network sizes (numbers of bits, e.g. 11.22.33.44/16) and netmasks (e.g. 11.22.33.0/255.255.255.0). Added new options to allow graylisting exclusions by IP address and rDNS name. Added new options to activate graylisting for only certain IP addresses and rDNS names. Updated the documentation. Added some explicit casting to printf("%.*s") arguments to make them ints instead of longs. gcc 3.3 on OpenBSD was complaining. Changed a datatype in log_write() from long to time_t. gcc 3.3 on OpenBSD was complaining. Changed all uses of sprintf() to snprintf(), even though they were already safe from buffer overruns. gcc 3.3 on OpenBSD was complaining. Added a new target to the Makefile in the spamdyke and utils folders named "openbsd" that compiles without the "-lresolv" flag. gcc 3.3 on OpenBSD includes the resolver library automatically and throws an error when it is explicitly specified. Added some additional #include directives in dnsmx.c, dnsptr.c and dnstxt.c because they're not included by resolv.h on OpenBSD. Gained a broader understanding of the resolver library and DNS packet structure, then rewrote most of dns_txt() and dns_ptr_lookup() to (more) correctly process DNS data. Added dns_mx() to perform MX record lookups. Changed process_command_line() to use getopt_long() and added long option equivalents to the existing command line flags. Added the option "reject-missing-sender-mx" to reject email from senders whose domains aren't local and don't have MX records and/or A records. AOL does this. Updated the usage statement to show the new (long) command line options. Updated the README.txt to show the new (long) command line options. Moved domain2path and domainsplit into a new folder named "utils". Created dnsmx, dnsptr and dnstxt in the utils folder by copying the dns_mx(), dns_ptr() and dns_txt() functions from spamdyke. They are simple command line utilities that no one will ever use except as examples of how to make MX, PTR and TXT DNS queries using libc. As far as Google knows, there are no such examples anywhere else on the internet. Changed the DNS RBL code to check for A records in addition to TXT records. Some RBLs are using A records, I don't know why. Fixed the DNS RBL code not to check 127.0.0.1 for RBL entries.
-rw-r--r--mail/spamdyke/Makefile21
-rw-r--r--mail/spamdyke/PLIST5
-rw-r--r--mail/spamdyke/distinfo12
-rw-r--r--mail/spamdyke/hacks.mk9
-rw-r--r--mail/spamdyke/patches/patch-aa10
-rw-r--r--mail/spamdyke/patches/patch-ab11
-rw-r--r--mail/spamdyke/patches/patch-ac11
7 files changed, 64 insertions, 15 deletions
diff --git a/mail/spamdyke/Makefile b/mail/spamdyke/Makefile
index 882701baf25..ae7dfd0e36a 100644
--- a/mail/spamdyke/Makefile
+++ b/mail/spamdyke/Makefile
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.1.1.1 2007/03/24 07:39:25 schmonz Exp $
+# $NetBSD: Makefile,v 1.2 2007/04/11 14:50:37 schmonz Exp $
#
-DISTNAME= spamdyke-2.2.1
+DISTNAME= spamdyke-2.4.0
CATEGORIES= mail
MASTER_SITES= http://freesoftware.silence.org/spamdyke/releases/
EXTRACT_SUFX= .tgz
@@ -10,7 +10,7 @@ MAINTAINER= schmonz@NetBSD.org
HOMEPAGE= http://freesoftware.silence.org/spamdyke/
COMMENT= Monitors and intercept incoming SMTP connections to qmail
-BUILD_DIRS= ${PKGBASE}
+BUILD_DIRS= ${PKGBASE} utils
SUBST_CLASSES+= paths
SUBST_FILES.paths= ${PKGBASE}/spamdyke.c
@@ -19,9 +19,22 @@ SUBST_STAGE.paths= do-configure
INSTALLATION_DIRS= bin share/doc/${PKGBASE}
+.include "../../mk/bsd.prefs.mk"
+
+.if ${OPSYS} == "OpenBSD"
+BUILD_TARGET= openbsd
+.endif
+
do-install:
cd ${WRKSRC}/${PKGBASE}; \
- for f in spamdyke domain2path domainsplit; do \
+ for f in spamdyke; do \
+ ${INSTALL_PROGRAM} $${f} ${PREFIX}/bin; \
+ done
+ cd ${WRKSRC}/utils; \
+ for f in dnsmx dnsptr dnstxt; do \
+ ${INSTALL_PROGRAM} $${f} ${PREFIX}/bin/spamdyke-$${f}; \
+ done; \
+ for f in domain2path domainsplit; do \
${INSTALL_PROGRAM} $${f} ${PREFIX}/bin; \
done
cd ${WRKSRC}/documentation; \
diff --git a/mail/spamdyke/PLIST b/mail/spamdyke/PLIST
index 450258e76da..8dd01fedc48 100644
--- a/mail/spamdyke/PLIST
+++ b/mail/spamdyke/PLIST
@@ -1,4 +1,7 @@
-@comment $NetBSD: PLIST,v 1.1.1.1 2007/03/24 07:39:25 schmonz Exp $
+@comment $NetBSD: PLIST,v 1.2 2007/04/11 14:50:37 schmonz Exp $
+bin/spamdyke-dnsmx
+bin/spamdyke-dnsptr
+bin/spamdyke-dnstxt
bin/domain2path
bin/domainsplit
bin/spamdyke
diff --git a/mail/spamdyke/distinfo b/mail/spamdyke/distinfo
index edffa8106d7..bc271498c06 100644
--- a/mail/spamdyke/distinfo
+++ b/mail/spamdyke/distinfo
@@ -1,6 +1,8 @@
-$NetBSD: distinfo,v 1.1.1.1 2007/03/24 07:39:25 schmonz Exp $
+$NetBSD: distinfo,v 1.2 2007/04/11 14:50:37 schmonz Exp $
-SHA1 (spamdyke-2.2.1.tgz) = 5ad8f0919d65244b8d141438274c8902ed7076f9
-RMD160 (spamdyke-2.2.1.tgz) = c5d410739808f97eff5d9c0a80ccc3d7bd73bbd9
-Size (spamdyke-2.2.1.tgz) = 37067 bytes
-SHA1 (patch-aa) = 6dfe19bbe45db372a97e9711f7ed4969a4497f2a
+SHA1 (spamdyke-2.4.0.tgz) = 7ee1dd0af63dd89ad414a57ae6f1a79274116941
+RMD160 (spamdyke-2.4.0.tgz) = c539437dfc73aac2a5f0741de3b6709a88affd95
+Size (spamdyke-2.4.0.tgz) = 48762 bytes
+SHA1 (patch-aa) = ebf0b5218858a442aa68dc5d29d2420008ed63d3
+SHA1 (patch-ab) = 042c267945fc5e84cffb93eca108019b0aa16460
+SHA1 (patch-ac) = 3a4abfab8db4f5c362bd1dd5bedd5fed1b3a57a4
diff --git a/mail/spamdyke/hacks.mk b/mail/spamdyke/hacks.mk
new file mode 100644
index 00000000000..fb5832ab17f
--- /dev/null
+++ b/mail/spamdyke/hacks.mk
@@ -0,0 +1,9 @@
+# $NetBSD: hacks.mk,v 1.1 2007/04/11 14:50:37 schmonz Exp $
+
+.include "../../mk/bsd.prefs.mk"
+
+# Fix build on OS X with BIND9 system resolver
+.if ${OPSYS} == "Darwin"
+PKG_HACKS+= macosx-bind9-bind8compat
+CFLAGS+= -DBIND_8_COMPAT=1
+.endif
diff --git a/mail/spamdyke/patches/patch-aa b/mail/spamdyke/patches/patch-aa
index ce1603bb98e..ac133a3144e 100644
--- a/mail/spamdyke/patches/patch-aa
+++ b/mail/spamdyke/patches/patch-aa
@@ -1,13 +1,13 @@
-$NetBSD: patch-aa,v 1.1.1.1 2007/03/24 07:39:25 schmonz Exp $
+$NetBSD: patch-aa,v 1.2 2007/04/11 14:50:38 schmonz Exp $
---- spamdyke/spamdyke.c.orig 2007-03-20 21:48:39.000000000 -0400
+--- spamdyke/spamdyke.c.orig 2007-04-02 15:16:20.000000000 -0400
+++ spamdyke/spamdyke.c
-@@ -37,7 +37,7 @@
+@@ -39,7 +39,7 @@ extern int opterr;
- #define VERSION_STRING "2.2.1"
+ #define VERSION_STRING "2.4.0"
-#define DEFAULT_PATH "/bin:/usr/bin:/usr/local/bin:/var/qmail/bin:/home/vpopmail/bin"
-+#define DEFAULT_PATH "/bin:/usr/bin:@PREFIX@/bin:/usr/local/bin:/home/vpopmail/bin"
++#define DEFAULT_PATH "/bin:/usr/bin:@PREFIX@/bin:/var/qmail/bin:/home/vpopmail/bin"
#define DEFAULT_TIMEOUT_COMMAND_SECS 60
#define DEFAULT_TIMEOUT_CONNECTION_SECS 0
diff --git a/mail/spamdyke/patches/patch-ab b/mail/spamdyke/patches/patch-ab
new file mode 100644
index 00000000000..72e1318cba8
--- /dev/null
+++ b/mail/spamdyke/patches/patch-ab
@@ -0,0 +1,11 @@
+$NetBSD: patch-ab,v 1.1 2007/04/11 14:50:38 schmonz Exp $
+
+--- spamdyke/Makefile.orig 2007-04-02 15:53:22.000000000 -0400
++++ spamdyke/Makefile
+@@ -1,5 +1,5 @@
+ #CFLAGS := -Wall -g -funsigned-char
+-CFLAGS := -Wall -O2 -funsigned-char
++CFLAGS += -Wall -O2 -funsigned-char
+ LFLAGS := -lresolv
+
+ all: spamdyke
diff --git a/mail/spamdyke/patches/patch-ac b/mail/spamdyke/patches/patch-ac
new file mode 100644
index 00000000000..6f5042672fd
--- /dev/null
+++ b/mail/spamdyke/patches/patch-ac
@@ -0,0 +1,11 @@
+$NetBSD: patch-ac,v 1.1 2007/04/11 14:50:38 schmonz Exp $
+
+--- utils/Makefile.orig 2007-04-02 15:46:57.000000000 -0400
++++ utils/Makefile
+@@ -1,5 +1,5 @@
+ #CFLAGS := -Wall -g -funsigned-char
+-CFLAGS := -Wall -O2 -funsigned-char
++CFLAGS += -Wall -O2 -funsigned-char
+ LFLAGS := -lresolv
+
+ all: domain2path domainsplit dnstxt dnsptr dnsmx