summaryrefslogtreecommitdiff
path: root/mail
diff options
context:
space:
mode:
authormef <mef@pkgsrc.org>2015-03-15 15:28:57 +0000
committermef <mef@pkgsrc.org>2015-03-15 15:28:57 +0000
commit15b78ffce84a8ea0a975f4587d35589bd0bbca92 (patch)
treed3af0815e9ce7e744a15b0e77cfe300ac95ba15c /mail
parent305dafbfbfafe33633d06f993dfcca3a4f8a1983 (diff)
downloadpkgsrc-15b78ffce84a8ea0a975f4587d35589bd0bbca92.tar.gz
Update 0.3 to 1.02
------------------ DK-MILTER RELEASE NOTES This listing shows the versions of the dk-milter package, the date of release, and a summary of the changes in that release. Bug and feature request (RFE) numbers that start with "SF" were logged via Sourceforge (http://www.sourceforge.net) trackers. Those not so labelled were logged internally at Sendmail, Inc. 1.0.2 2009/02/04 LIBDK: Fix bug in error message generation which could cause crashes with very large error messages. Code copied from dkim-milter. 1.0.1 2008/09/04 Set up required callbacks for OpenSSL thread-safety. Code copied from dkim-milter. LIBDK: Fix bug in relaxed canonicalization mode when dealing with very large input lines with cached blank lines. Problem reported by Mark Martinec. 1.0.0 2008/03/13 Use the current Authentication-Results: format (the -13 draft). Patch from S. Moonesamy of Eland Systems. Add improved mlfi_negotiate() function code, copied from dkim-milter, which does things like symbol requesting and more intelligent option negotiation. Patch from S. Moonesamy of Eland Systems. Add hash buffering, copied from libdkim. Patch from S. Moonesamy of Eland Systems. Fix bug #SF1736559: in_addr_t is not universal. Problem reported by Terry White. Fix bug #SF1763715: Fix string management in mlfi_eoh() with respect to mctx_domain, which could be left pointing to garbage when using domain wildcarding. Problem noted by Ronald Huizer. Activate _FFR_MULTIPLE_KEYS. LIBDK: Copy the library options structure from libdkim. LIBDK: Add dk_close(). LIBDK: Feature request #SF1872270: Rename parameters called "new" in dk.h so that C++ compilers don't complain. Requested by Paul Macintosh. LIBAR: Eliminate a possible race condition in ar_dispatcher(). LIBAR: Timeouts passed to select() can't be bigger than 10^8. Problem noted by S. Moonesamy of Eland Systems. LIBAR: Fix bug #SF1852618: Handle default case of no "nameserver" lines in /etc/resolv.conf. Problem noted by Mike Markley of Bank of America. LIBAR: Plug descriptor and memory leaks in ar_shutdown(). BUILD: Copy the unit test structure from libdkim and add a few basic unit tests. 0.6.0 2007/05/31 Fix bug #SF1728696: Repair message corruption occurring when a message body spams multiple milter writes. Reported by Eric Singer. Patch #SF1705006: Fix X-header malformation. LIBAR: Fix bug #SF1537457: Add proper support for IPv6 nameservers. Reported by Mark Martinec. BUILD: Copy the consolidated build system from the dkim-milter package. Activate the following FFRs: _FFR_LOG_SSL_ERRORS _FFR_QUARANTINE _FFR_REPORTINFO 0.5.0 2007/04/10 Copy several enhancements from the latest dkim-milter update: o Support for 8.14 (milter v2) and the leading space patch from dkim-milter. o Fixes/enhancements under POPAUTH. o Pass the correct length variable to RSA_sign() so that the value returned is sane on 64-bit platforms. o _FFR_ANTICIPATE_SENDMAIL_MUNGE o Feature request #SF1497801: _FFR_QUARANTINE Fix bug #SF1541450: Correct header selection in dk_hdrsigned(). Reported by Mark Martinec. LIBDK: Fix bug #SF1537918: Add dk_geterror() to retrieve additional diagnostic data from the API when a function call returns DK_STAT_INTERNAL or something else whose cause isn't readily apparent. Copied from libdkim. LIBAR: Block signals that should be caught and handled elsewhere, such as in libmilter. 0.4.2 2007/03/13 Fix bug #SF1509093, SF1611082: Set group ID as well as user ID when "-u" is used on the command line. Patch from Vincent Rivellino. Fix bug #SF1514447: Re-query for the job ID in mlfi_eom() to accomodate postfix's milter implementation. Copied from dkim-filter; requested by Jakob Schlyter. Fix bug #SF1541439: Fix mis-canonicalization of skipped headers in "nofws" mode. Reported by Mark Martinec. Fix bug #SF1541789: Stop spurious syntax errors on unsigned messages. Problem reported by S. Moonesamy of Eland Systems. 0.4.1 2006/06/14 LIBDK: Properly handle key and policy records that don't have whitespace after semicolons. LIBDK: In dk_eom(), return DK_STAT_SYNTAX if dk_skipbody is set. Failing to do so means a message with a signature header below which there is no sender header will report a bogus success status. Problem noted by Lennert Buytenhek. 0.4.0 2006/05/19 Remove spurious CRLFs injected into canonicalization when multiple body chunks arrive from the MTA. Patch from Suzuki Takahiko of Internet Initiative Japan, Inc. If _FFR_REPORTINFO is enabled, don't call dkf_report() if no DomainKeys context was ever created for a message. Simplify dk_sterilize() a little, and handle failures from it. Problem reported by Fredrik Pettai. RFC2822 doesn't require any recipient headers, so remove those checks inside _FFR_REQUIRED_HEADERS. Fix bug #SF1485119: Canonicalize in the correct order when not using "-H" on the command line. Problem noted by S. Moonesamy of Eland Systems. Activate _FFR_MACRO_LIST and _FFR_EXTERNAL_IGNORE_LIST. LIBDK: New flag DK_OPTS_HDRLIST for dk_options(). 0.3.4 2006/05/02 If _FFR_REPORTINFO is enabled, send reports on all failures, not just those which aren't in test mode. Ignore unknown tags in keys and policies, rather than returning an error. LIBDK: Return an error if the signing function returned success but also reported a zero-length signature. Reported by S. Moonesamy of Eland Systems. LIBAR: Add a timeout to the I/O wait so that retransmissions actually get done while waiting for activity. 0.3.3 2006/03/13 Fix test mode check at the end of mlfi_eom(), which was overriding any configuration settings from the command line. Reported by Arkadi Poliakevitch of Invidi Technologies. Copy the value of -C before parsing it so the output of "ps" doesn't get munged. Reported by Arkadi Poliakevitch of Invidi Technologies. Fix "-o", which wasn't actually working at all. Reported by Ben Lentz. Add _FFR_LOG_SSL_ERRORS which sends to syslog errors reported by the OpenSSL libraries. 0.3.2 2005/12/12 Patch a small but definite memory leak. Reported by Ray Krebs of eBay. 0.3.1 2005/12/02 Tolerate "b=" in signature headers at places other than the end of the signature (and, in fact, other things at the end of the signature). Reported by Jason Long. (Bug SF1234164) Don't reject or report about messages which fail verification when the sending domain advertises that it's in test mode. Patch from Adrian Havill. Fixes to POPAUTH compilation from S. Moonesamy of Eland Systems. Allow "-d" to specify a list from which domains should be read, and allow wildcarding in domain names. Requested by Ray Krebs of eBay. (Feature request SF1312453) Add "-o" command line option to allow certain headers to be omitted from signing operations. Suggested by Ben Lentz. (Feature request SF1314350) LIBAR: Fix a build issue introduced in the last release.
Diffstat (limited to 'mail')
-rw-r--r--mail/dk-milter/DESCR13
-rw-r--r--mail/dk-milter/Makefile82
-rw-r--r--mail/dk-milter/PLIST34
-rw-r--r--mail/dk-milter/distinfo16
-rw-r--r--mail/dk-milter/files/dk-milter.sh2
-rw-r--r--mail/dk-milter/options.mk21
-rw-r--r--mail/dk-milter/patches/patch-aa55
-rw-r--r--mail/dk-milter/patches/patch-ab20
-rw-r--r--mail/dk-milter/patches/patch-ac44
-rw-r--r--mail/dk-milter/patches/patch-ad25
-rw-r--r--mail/dk-milter/patches/patch-ae29
11 files changed, 211 insertions, 130 deletions
diff --git a/mail/dk-milter/DESCR b/mail/dk-milter/DESCR
index a0bf6dfb6c6..b6b46c711b0 100644
--- a/mail/dk-milter/DESCR
+++ b/mail/dk-milter/DESCR
@@ -1,9 +1,4 @@
-The dk-milter package is an open source implementation of the DomainKeys
-sender authentication system proposed by Yahoo!, Inc. It consists of a
-library that implements the DomainKeys service, and a milter-based filter
-application that can plug in to the sendmail MTA to provide that service
-to sufficiently recent sendmail MTAs.
-
-An optional asynchronous resolver library is also provided to work around
-limitations of the basic BIND resolver which comes installed on most
-systems.
+dk-milter consists of two parts: A milter-based application
+(dk-filter) which plugs in to Sendmail to provide DomainKeys
+service, and a library (libdk) which can be used to build
+DomainKeys-compliant applications or MTAs.
diff --git a/mail/dk-milter/Makefile b/mail/dk-milter/Makefile
index da53acc80a5..e172eb43081 100644
--- a/mail/dk-milter/Makefile
+++ b/mail/dk-milter/Makefile
@@ -1,67 +1,73 @@
-# $NetBSD: Makefile,v 1.25 2014/02/12 23:18:06 tron Exp $
+# $NetBSD: Makefile,v 1.26 2015/03/15 15:28:57 mef Exp $
-DISTNAME= dk-milter-0.3.0
-PKGREVISION= 7
+DISTNAME= dk-milter-1.0.2
CATEGORIES= mail
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=dk-milter/}
MAINTAINER= pkgsrc-users@NetBSD.org
HOMEPAGE= http://sourceforge.net/projects/dk-milter/
-COMMENT= Open source implementation of DomainKeys for sendmail
+COMMENT= Open source DomainKeys filter software from Sendmail, Inc
LICENSE= sendmail-open-source-license
MAKE_ENV+= M4=${M4:Q}
RCD_SCRIPTS= dk-milter
USE_BUILTIN.libmilter= no
-USE_TOOLS+= gm4 csh:run
+USE_TOOLS+= gm4
-REPLACE_CSH= dk-filter/gentxt.csh
+.include "../../mk/bsd.prefs.mk"
SUBST_CLASSES+= libs
-SUBST_STAGE.libs= pre-configure
-SUBST_FILES.libs= dk-filter/Makefile.m4 libdk/Makefile.m4
+SUBST_STAGE.libs= post-patch
+SUBST_FILES.libs= site.config.m4.dist dk-filter/Makefile.m4 \
+ devtools/M4/header.m4
SUBST_SED.libs= -e 's|@SSLBASE@|${BUILDLINK_PREFIX.openssl}|g'
SUBST_SED.libs+= -e 's|@LMBASE@|${BUILDLINK_PREFIX.libmilter}|g'
SUBST_SED.libs+= -e 's|@PTHREAD@|${BUILDLINK_PREFIX.pthread}|g'
-SUBST_SED.libs+= -e 's|@PTHREAD_LDFLAGS@|${PTHREAD_LDFLAGS} ${PTHREAD_LIBS}|g'
+SUBST_SED.libs+= -e 's|@PTHREAD_LDFLAGS@|${PTHREAD_LDFLAGS:Q} ${PTHREAD_LIBS:Q}|g'
+.if ${OPSYS} == SunOS
+SUBST_SED.libs+= -e 's|-lrt|-lrt -lresolv|g'
+.endif
SUBST_MESSAGE.libs= Fixing makefile references.
-INSTALLATION_DIRS= ${PKGMANDIR}/man8 sbin share/doc/dk-milter
+# Rename dk-filter to dk-milter.
+# tv@ has done this when importing the original dk-milter package from
+# pkgsrc-wip to pkgsrc, hence we continue this tradition.
+SUBST_CLASSES+= rename
+SUBST_STAGE.rename= post-build
+SUBST_FILES.rename= dk-filter/dk-filter.8
+SUBST_SED.rename= -e 's|dk-filter|dk-milter|g'
+SUBST_MESSAGE.rename= Renaming dk-filter to dk-milter
-.include "../../mk/bsd.prefs.mk"
+SUBST_CLASSES+= gentxt
+SUBST_STAGE.gentxt= post-build
+SUBST_FILES.gentxt= INSTALL
+SUBST_SED.gentxt= -e '/Run the script/s,gentxt.csh,dk-milter-gentxt.csh,'
+SUBST_SED.gentxt+= -e '/DNS system/s,published.,published (dk-milter-gentxt.csh is in ${PREFIX}/sbin).,'
+SUBST_SED.gentxt+= -e 's/dk-filter/dk-milter/g'
+SUBST_MESSAGE.gentxt= Modify PATH and name of gentxt.csh
-.if ${OPSYS} == "NetBSD"
-CPPFLAGS+= -DSM_CONF_STDBOOL_H=1
-.endif
+INSTALLATION_DIRS= lib ${PKGMANDIR}/man8 sbin share/doc/dk-milter/libdk
-post-extract:
- ${LN} -s FreeBSD ${WRKSRC}/devtools/OS/DragonFly
+pre-configure:
+ mv ${WRKSRC}/site.config.m4.dist ${WRKSRC}/devtools/Site/site.config.m4
do-build:
- @(cd ${WRKSRC}; ${SETENV} ${MAKE_ENV} ./Build)
-
-post-build:
- ${SED} -e 's|dk-filter|dk-milter|g' \
- ${WRKSRC}/dk-filter/dk-filter.8 \
- >${WRKSRC}/dk-filter/dk-milter.8
+ (cd ${WRKSRC}; ${SETENV} ${MAKE_ENV} ./Build)
do-install:
- cd ${WRKSRC}/obj.`${UNAME} -srm | ${TR} \ . | ${TR} \/ -` && \
- ${INSTALL_PROGRAM} dk-filter/dk-filter \
- ${DESTDIR}${PREFIX}/sbin/dk-milter
- ${INSTALL_SCRIPT} ${WRKSRC}/dk-filter/gentxt.csh ${DESTDIR}${PREFIX}/sbin/gentxt.csh
- ${INSTALL_MAN} ${WRKSRC}/dk-filter/dk-milter.8 \
- ${DESTDIR}${PREFIX}/${PKGMANDIR}/man8/
- ${INSTALL_DATA} ${WRKSRC}/FEATURES \
- ${DESTDIR}${PREFIX}/share/doc/dk-milter
- ${INSTALL_DATA} ${WRKSRC}/INSTALL \
- ${DESTDIR}${PREFIX}/share/doc/dk-milter
- ${INSTALL_DATA} ${WRKSRC}/KNOWNBUGS \
- ${DESTDIR}${PREFIX}/share/doc/dk-milter
- ${INSTALL_DATA} ${WRKSRC}/README \
- ${DESTDIR}${PREFIX}/share/doc/dk-milter
- ${INSTALL_DATA} ${WRKSRC}/RELEASE_NOTES \
- ${DESTDIR}${PREFIX}/share/doc/dk-milter
+ cd ${WRKSRC}/obj.`uname -s`.`uname -r`.`uname -m`; \
+ ${INSTALL_PROGRAM} dk-filter/dk-filter ${DESTDIR}${PREFIX}/sbin/dk-milter; \
+ ${INSTALL_SCRIPT} ${WRKSRC}/dk-filter/gentxt.csh ${DESTDIR}${PREFIX}/sbin/dk-milter-gentxt.csh; \
+ ${INSTALL_LIB} libdk/libdk.a ${DESTDIR}${PREFIX}/lib
+# man pages
+ ${INSTALL_MAN} ${WRKSRC}/dk-filter/dk-filter.8 ${DESTDIR}${PREFIX}/${PKGMANDIR}/man8/dk-milter.8
+# documents in source
+ cd ${WRKSRC} ;\
+ for f in FEATURES INSTALL KNOWNBUGS LICENSE README RELEASE_NOTES rfc4870.txt; do\
+ ${INSTALL_DATA} $${f} ${DESTDIR}${PREFIX}/share/doc/dk-milter ;\
+ done
+ cd ${WRKSRC}/libdk/docs; for file in *.html; do \
+ ${INSTALL_DATA} $$file ${DESTDIR}${PREFIX}/share/doc/dk-milter/libdk; done
.include "options.mk"
.include "../../security/openssl/buildlink3.mk"
diff --git a/mail/dk-milter/PLIST b/mail/dk-milter/PLIST
index d6b5738c193..f9ebcfa8b6e 100644
--- a/mail/dk-milter/PLIST
+++ b/mail/dk-milter/PLIST
@@ -1,9 +1,39 @@
-@comment $NetBSD: PLIST,v 1.4 2014/03/11 14:05:03 jperkin Exp $
+@comment $NetBSD: PLIST,v 1.5 2015/03/15 15:28:57 mef Exp $
+lib/libdk.a
man/man8/dk-milter.8
sbin/dk-milter
-sbin/gentxt.csh
+sbin/dk-milter-gentxt.csh
share/doc/dk-milter/FEATURES
share/doc/dk-milter/INSTALL
share/doc/dk-milter/KNOWNBUGS
+share/doc/dk-milter/LICENSE
share/doc/dk-milter/README
share/doc/dk-milter/RELEASE_NOTES
+share/doc/dk-milter/libdk/dk.html
+share/doc/dk-milter/libdk/dk_alg_t.html
+share/doc/dk-milter/libdk/dk_body.html
+share/doc/dk-milter/libdk/dk_canon_t.html
+share/doc/dk-milter/libdk/dk_close.html
+share/doc/dk-milter/libdk/dk_eoh.html
+share/doc/dk-milter/libdk/dk_eom.html
+share/doc/dk-milter/libdk/dk_flags.html
+share/doc/dk-milter/libdk/dk_free.html
+share/doc/dk-milter/libdk/dk_geterror.html
+share/doc/dk-milter/libdk/dk_gethdrs.html
+share/doc/dk-milter/libdk/dk_getidentity.html
+share/doc/dk-milter/libdk/dk_getsig.html
+share/doc/dk-milter/libdk/dk_header.html
+share/doc/dk-milter/libdk/dk_init.html
+share/doc/dk-milter/libdk/dk_lib.html
+share/doc/dk-milter/libdk/dk_options.html
+share/doc/dk-milter/libdk/dk_query_t.html
+share/doc/dk-milter/libdk/dk_sigkey_t.html
+share/doc/dk-milter/libdk/dk_sign.html
+share/doc/dk-milter/libdk/dk_stat.html
+share/doc/dk-milter/libdk/dk_timeout.html
+share/doc/dk-milter/libdk/dk_verify.html
+share/doc/dk-milter/libdk/index.html
+share/doc/dk-milter/libdk/overview.html
+share/doc/dk-milter/libdk/rfc2822_mailbox_split.html
+share/doc/dk-milter/rfc4870.txt
+share/examples/rc.d/dk-milter
diff --git a/mail/dk-milter/distinfo b/mail/dk-milter/distinfo
index 760e27f0547..2c9ba9ddfe0 100644
--- a/mail/dk-milter/distinfo
+++ b/mail/dk-milter/distinfo
@@ -1,8 +1,10 @@
-$NetBSD: distinfo,v 1.2 2006/01/08 18:13:08 joerg Exp $
+$NetBSD: distinfo,v 1.3 2015/03/15 15:28:57 mef Exp $
-SHA1 (dk-milter-0.3.0.tar.gz) = bc7a4f9e1a3d9d751bf84e261e4cbe45198671b9
-RMD160 (dk-milter-0.3.0.tar.gz) = 1b1de285dab602bdc0b21e55080f2964924ab646
-Size (dk-milter-0.3.0.tar.gz) = 304023 bytes
-SHA1 (patch-aa) = 9f74c271c1f9eb60080864c9ed386f450a40596a
-SHA1 (patch-ab) = 357e250bb17fd9680c033ac392cea17957b71997
-SHA1 (patch-ac) = 403e565640e3a67f26f04d9df5bb0833305d308a
+SHA1 (dk-milter-1.0.2.tar.gz) = 95b60ebb9d28c8213ce36c3fcf383faeaa3f0e6a
+RMD160 (dk-milter-1.0.2.tar.gz) = 24c1b3f023257937f212e38e15b151b9a5e81caf
+Size (dk-milter-1.0.2.tar.gz) = 362255 bytes
+SHA1 (patch-aa) = b5d55642518f6ee4653ce97e7aa46b99043280b3
+SHA1 (patch-ab) = 43ecaeda136b9267a4a2164e7125946d47e3685b
+SHA1 (patch-ac) = 4a65218ffa02f998a6e697f622ea765446cb43cb
+SHA1 (patch-ad) = 790602661bc34767c22e80a1e12e23ddf323c291
+SHA1 (patch-ae) = 8b0b9fb00b99960e1394af50f27f7e92b6f56cba
diff --git a/mail/dk-milter/files/dk-milter.sh b/mail/dk-milter/files/dk-milter.sh
index 96c9c3bf193..793cf3a61ab 100644
--- a/mail/dk-milter/files/dk-milter.sh
+++ b/mail/dk-milter/files/dk-milter.sh
@@ -1,6 +1,6 @@
#!@RCD_SCRIPTS_SHELL@
#
-# $NetBSD: dk-milter.sh,v 1.5 2005/07/21 16:22:04 tv Exp $
+# $NetBSD: dk-milter.sh,v 1.6 2015/03/15 15:28:58 mef Exp $
#
# PROVIDE: dkmilter
# REQUIRE: DAEMON
diff --git a/mail/dk-milter/options.mk b/mail/dk-milter/options.mk
index a467c9294aa..74a7845522f 100644
--- a/mail/dk-milter/options.mk
+++ b/mail/dk-milter/options.mk
@@ -1,8 +1,8 @@
-# $NetBSD: options.mk,v 1.2 2012/06/12 15:45:57 wiz Exp $
+# $NetBSD: options.mk,v 1.3 2015/03/15 15:28:57 mef Exp $
PKG_OPTIONS_VAR= PKG_OPTIONS.dk-milter
-PKG_SUPPORTED_OPTIONS= inet6
-PKG_SUGGESTED_OPTIONS= inet6
+PKG_SUPPORTED_OPTIONS= arlib inet6
+PKG_SUGGESTED_OPTIONS= arlib inet6
.include "../../mk/bsd.options.mk"
@@ -10,7 +10,18 @@ PKG_SUGGESTED_OPTIONS= inet6
### IPv6 support.
###
.if !empty(PKG_OPTIONS:Minet6)
-SUBST_SED.libs+= -e 's|@INET6@||'
+SUBST_SED.libs+= -e 's|@INET6@||g'
.else
-SUBST_SED.libs+= -e 's|@INET6@|dnl|'
+SUBST_SED.libs+= -e 's|@INET6@|dnl|g'
+.endif
+
+###
+### Use asynchronous DNS resolver library shipping with dk-milter.
+###
+.if !empty(PKG_OPTIONS:Marlib)
+SUBST_SED.libs+= -e 's|@RESOLVLIB@||g'
+SUBST_SED.libs+= -e 's|@ARLIB@||g'
+.else
+SUBST_SED.libs+= -e 's|@RESOLVLIB@|resolv bind|g'
+SUBST_SED.libs+= -e 's|@ARLIB@|dnl|g'
.endif
diff --git a/mail/dk-milter/patches/patch-aa b/mail/dk-milter/patches/patch-aa
index d5bcf5a5ef5..51f84e26f30 100644
--- a/mail/dk-milter/patches/patch-aa
+++ b/mail/dk-milter/patches/patch-aa
@@ -1,34 +1,35 @@
-$NetBSD: patch-aa,v 1.1.1.1 2005/07/20 19:42:50 tv Exp $
+$NetBSD: patch-aa,v 1.2 2015/03/15 15:28:58 mef Exp $
---- dk-filter/Makefile.m4.orig 2005-07-20 14:55:01.000000000 -0400
-+++ dk-filter/Makefile.m4
-@@ -4,10 +4,10 @@ include(confBUILDTOOLSDIR`/M4/switch.m4'
- define(`confMT', `TRUE')
- define(`confREQUIRE_LIBSM', `true')
-
--APPENDDEF(`confLIBS', `-lssl -lcrypto')
-+APPENDDEF(`confLIBS', `-lssl -lcrypto @PTHREAD_LDFLAGS@ ')
- dnl Enable and edit these paths as needed:
+--- site.config.m4.dist.orig 2007-05-31 20:57:51.000000000 +0200
++++ site.config.m4.dist 2007-08-06 21:27:46.000000000 +0200
+@@ -17,7 +17,7 @@ dnl libar -- asynchronous resolver libra
+ dnl
+ dnl If you want to use the asynchronous resolver library, enable this
+ dnl next line by deleting the "dnl" at the front of it.
+-dnl define(`bld_USE_ARLIB', `true')
++@ARLIB@ define(`bld_USE_ARLIB', `true')
+ dnl
+ dnl libar normally uses res_init() or res_ninit() to load the contents
+ dnl of resolv.conf for its use. If neither of these work on your system
+@@ -53,8 +53,8 @@ dnl
+ dnl DK requires several algorithms provided by this library. If necessary,
+ dnl enable these lines by deleting "dnl" from the front of them and edit
+ dnl paths as needed.
-dnl APPENDDEF(`confINCDIRS', `-I/usr/local/ssl/include ')
-dnl APPENDDEF(`confLIBDIRS', `-L/usr/local/ssl/lib ')
+APPENDDEF(`confINCDIRS', `-I@SSLBASE@/include -I@PTHREAD@/include ')
+APPENDDEF(`confLIBDIRS', `-L@SSLBASE@/lib -L@PTHREAD@/lib ')
- dnl To use the asynchronous resolver library provided, enable this line:
- dnl bldPUSH_SMLIB(`ar')
-@@ -19,12 +19,12 @@ bldPUSH_SMLIB(`sm')
-
- dnl Enable these next line if needed to specify the locations of libmilter.a
- dnl and the libmilter include files:
--dnl APPENDDEF(`confINCDIRS', `-I/usr/local/sendmail/include')
--dnl APPENDDEF(`confLIBDIRS', `-L/usr/local/sendmail/lib')
-+APPENDDEF(`confINCDIRS', `-I@LMBASE@/include ')
-+APPENDDEF(`confLIBDIRS', `-L@LMBASE@/lib')
-
-
- dnl Enable for IPv6 support:
--dnl APPENDDEF(`confENVDEF', `-DNETINET6 ')
-+@INET6@ APPENDDEF(`confENVDEF', `-DNETINET6 ')
+ dnl Code For Future Release (FFRs):
+ dnl
+@@ -74,8 +74,8 @@ dnl
+ dnl This must be in the search rules for your compile. If necessary,
+ dnl adjust the paths below and enable the lines by deleting "dnl" from the
+ dnl front of them.
+-dnl APPENDDEF(`bld_dk_filter_INCDIRS', `-I/usr/local/sendmail/include')
+-dnl APPENDDEF(`bld_dk_filter_LIBDIRS', `-L/usr/local/sendmail/lib')
++APPENDDEF(`bld_dk_filter_INCDIRS', `-I@LMBASE@/include')
++APPENDDEF(`bld_dk_filter_LIBDIRS', `-L@LMBASE@/lib')
- dnl Compile time options, especially FFRs:
- dnl APPENDDEF(`confENVDEF', `-D_FFR_EXTERNAL_IGNORE_LIST ')
+ dnl smfi_addheader() -- older versions of libmilter
+ dnl
diff --git a/mail/dk-milter/patches/patch-ab b/mail/dk-milter/patches/patch-ab
index 88b11aefae0..d8040cc3cbb 100644
--- a/mail/dk-milter/patches/patch-ab
+++ b/mail/dk-milter/patches/patch-ab
@@ -1,13 +1,15 @@
-$NetBSD: patch-ab,v 1.1.1.1 2005/07/20 19:42:50 tv Exp $
+$NetBSD: patch-ab,v 1.2 2015/03/15 15:28:58 mef Exp $
---- libdk/Makefile.m4.orig 2004-09-03 16:39:01.000000000 -0400
-+++ libdk/Makefile.m4
-@@ -9,7 +9,7 @@ dnl APPENDDEF(`confENVDEF', `-DUSE_ARLIB
- dnl APPENDDEF(`confINCDIRS', `-I../libar/ ')
+--- dk-filter/Makefile.m4.orig 2007-05-31 22:31:01.000000000 +0200
++++ dk-filter/Makefile.m4 2007-08-01 10:37:46.000000000 +0200
+@@ -9,7 +9,9 @@
+ define(`confMT', `TRUE')
+ define(`confREQUIRE_LIBSM', `true')
- dnl Enable and edit this as appropriate for your system:
--dnl APPENDDEF(`confINCDIRS', `-I/usr/local/ssl/include ')
-+APPENDDEF(`confINCDIRS', `-I@SSLBASE@/include ')
+-APPENDDEF(`confLIBS', `-lssl -lcrypto')
++APPENDDEF(`confLIBS', `-lssl -lcrypto @PTHREAD_LDFLAGS@ ')
++define(`confLDOPTS', `${LDFLAGS}')
++@INET6@ APPENDDEF(`confENVDEF', `-DNETINET6 ')
+ ifdef(`bld_USE_ARLIB', `bldPUSH_SMLIB(`ar')', `')
- define(`confMT', `true')
diff --git a/mail/dk-milter/patches/patch-ac b/mail/dk-milter/patches/patch-ac
index 9a6b4b625e8..11db3904ba4 100644
--- a/mail/dk-milter/patches/patch-ac
+++ b/mail/dk-milter/patches/patch-ac
@@ -1,33 +1,13 @@
-$NetBSD: patch-ac,v 1.1 2006/01/08 18:13:08 joerg Exp $
+$NetBSD: patch-ac,v 1.2 2015/03/15 15:28:58 mef Exp $
---- include/sm/os/sm_os_freebsd.h.orig 2006-01-08 18:09:08.000000000 +0000
-+++ include/sm/os/sm_os_freebsd.h
-@@ -13,10 +13,18 @@
- ** Platform definitions for FreeBSD
- */
-
--#define SM_OS_NAME "freebsd"
--
- #define SM_CONF_SYS_CDEFS_H 1
-
-+#ifdef __DragonFly__)
-+#define SM_OS_NAME "dragonfly"
-+#define MI_SOMAXCONN -1
-+#ifndef SM_CONF_STRL
-+# define SM_CONF_STRL 1
-+#endif
-+
-+#else
-+#define SM_OS_NAME "freebsd"
-+
- #if __FreeBSD__ >= 2
- # include <osreldate.h> /* defines __FreeBSD_version */
- # if __FreeBSD_version >= 199512 /* 2.2-current when it appeared */
-@@ -29,6 +37,7 @@
- # endif
- # endif
- #endif
-+#endif
-
- #ifndef SM_CONF_SHM
- # define SM_CONF_SHM 1
+--- devtools/M4/header.m4.orig 2002-08-01 23:58:26.000000000 +0200
++++ devtools/M4/header.m4 2007-08-06 21:27:02.000000000 +0200
+@@ -25,7 +25,7 @@ define(`confSHELL', `/bin/sh')
+ define(`confBEFORE', `')
+ define(`confLIBDIRS', `')
+ define(`confINCDIRS', `')
+-define(`confLIBSEARCH', `db bind resolv 44bsd')
++define(`confLIBSEARCH', `@RESOLVLIB@')
+ define(`confLIBSEARCHPATH', `/lib /usr/lib /usr/shlib')
+ define(`confSITECONFIG', `site.config')
+ define(`confBUILDBIN', `${SRCDIR}/devtools/bin')
diff --git a/mail/dk-milter/patches/patch-ad b/mail/dk-milter/patches/patch-ad
new file mode 100644
index 00000000000..f5fbc3a37b8
--- /dev/null
+++ b/mail/dk-milter/patches/patch-ad
@@ -0,0 +1,25 @@
+$NetBSD: patch-ad,v 1.1 2015/03/15 15:28:58 mef Exp $
+--- devtools/OS/NetBSD.orig Sun Jun 27 00:19:35 2004
++++ devtools/OS/NetBSD Sun Jun 27 00:24:11 2004
+@@ -6,14 +6,16 @@
+ define(`confMAPDEF', `-DNEWDB -DNIS -DMAP_REGEX')
+ define(`confLIBS', `-lutil')
+ define(`confENVDEF', ` -DNETISO')
++define(`confSM_OS_HEADER', `sm_os_netbsd')
+ define(`confDEPEND_TYPE', `CC-M')
+-define(`confSBINGRP', `wheel')
+-define(`confUBINOWN', `root')
+-define(`confUBINGRP', `wheel')
+-define(`confMANOWN', `root')
+-define(`confMANGRP', `wheel')
++define(`confSBINGRP', `${BSD_BINGRP}')
++define(`confUBINOWN', `${BSD_BINOWN}')
++define(`confUBINGRP', `${BSD_BINGRP}')
++define(`confMANOWN', `${BSD_MANOWN}')
++define(`confMANGRP', `${BSD_MANGRP}')
+ define(`confMAN1EXT', `0')
+ define(`confMAN3EXT', `0')
+ define(`confMAN4EXT', `0')
+ define(`confMAN5EXT', `0')
+ define(`confMAN8EXT', `0')
++define(`confLDOPTS', `${LDFLAGS}')
diff --git a/mail/dk-milter/patches/patch-ae b/mail/dk-milter/patches/patch-ae
new file mode 100644
index 00000000000..8a9489670c6
--- /dev/null
+++ b/mail/dk-milter/patches/patch-ae
@@ -0,0 +1,29 @@
+$NetBSD: patch-ae,v 1.1 2015/03/15 15:28:58 mef Exp $
+
+
+--- /dev/null 2008-10-16 17:49:30.000000000 +1300
++++ include/sm/os/sm_os_netbsd.h
+@@ -0,0 +1,23 @@
++/*
++ */
++
++/*
++** sm_os_netbsd.h -- platform definitions for NetBSD
++*/
++
++#define SM_OS_NAME "netbsd"
++
++#define SM_CONF_SYS_CDEFS_H 1
++
++#if defined(__NetBSD__)
++# include <sys/param.h> /* defines __NetBSD_Version__ */
++# if __NetBSD_Version__ >= 104030000
++ /* 1.4.3 and later have strlcpy()/strlcat() */
++# ifndef SM_CONF_STRL
++# define SM_CONF_STRL 1
++# endif
++# endif
++# if __NetBSD_Version__ >= 499006500
++# define SM_CONF_STDBOOL_H 1
++# endif
++#endif