git: ce3abd742eb8 - main - mail/opendkim-devel: Update to latest snapshot and enable Lua flavors
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 15 Jun 2026 15:16:52 UTC
The branch main has been updated by nork:
URL: https://cgit.FreeBSD.org/ports/commit/?id=ce3abd742eb87de1c9fe7e54ec26492063ca03eb
commit ce3abd742eb87de1c9fe7e54ec26492063ca03eb
Author: Yasuhito FUTATSUKI <freebsd-bug-report-yf@yf.bsdclub.org>
AuthorDate: 2026-06-15 15:15:41 +0000
Commit: Norikatsu Shigemura <nork@FreeBSD.org>
CommitDate: 2026-06-15 15:15:41 +0000
mail/opendkim-devel: Update to latest snapshot and enable Lua flavors
- Update to 2.11.0-Beta2-49 (commit 1c7a9f47c6)
- Enable Lua flavors support
- Remove obsolete or unsupported options: ADSP_LISTS, LDNS and LUA_ONLY_SIGNING
- Remove patches that have been merged upstream
PR: 295791
Approved by: hrs (mentor, blanket)
---
mail/opendkim-devel/Makefile | 55 ++++++--------
mail/opendkim-devel/distinfo | 6 +-
mail/opendkim-devel/files/patch-lua_pop | 86 ----------------------
.../files/patch-opendkim_opendkim-crypto.c | 20 -----
.../opendkim-devel/files/patch-opendkim_opendkim.c | 36 ---------
5 files changed, 27 insertions(+), 176 deletions(-)
diff --git a/mail/opendkim-devel/Makefile b/mail/opendkim-devel/Makefile
index 98e4dabd7050..5d79a28edb39 100644
--- a/mail/opendkim-devel/Makefile
+++ b/mail/opendkim-devel/Makefile
@@ -1,8 +1,7 @@
PORTNAME= opendkim
DISTVERSIONPREFIX= rel-opendkim-
-DISTVERSION= 2.11.0-Beta2-48
-DISTVERSIONSUFFIX= -g551ab382
-PORTREVISION= 3
+DISTVERSION= 2.11.0-Beta2-49
+DISTVERSIONSUFFIX= -g1c7a9f47c
CATEGORIES= mail security
PKGNAMESUFFIX= -devel
@@ -22,39 +21,40 @@ USES= autoreconf cpe libtool perl5 pkgconfig shebangfix ssl
USE_GITHUB= yes
GH_ACCOUNT= trusteddomainproject
GH_PROJECT= OpenDKIM
+GH_TAGNAME= 1c7a9f47c658a2e2ff7f2211b9800c44f4ec046d
USE_LDCONFIG= yes
USE_PERL5= run
SHEBANG_FILES= opendkim/opendkim-genkey* reprrd/opendkim-reprrdimport* \
reputation/opendkim-* stats/opendkim-*
-GNU_CONFIGURE= yes
+GNU_CONFIGURE= yes
+CONFIGURE_ARGS+= --with-test-socket=./test.sock
MAKE_ARGS= pkgconfigdir="${PREFIX}/libdata/pkgconfig"
MAKE_ENV= INSTALL_STRIP_FLAG=${STRIP}
TEST_TARGET= check
-CONFLICTS_INSTALL= opendkim
+CONFLICTS_INSTALL= ${PORTNAME} ${PORTNAME}-devel*
PORTDOCS= *
-OPTIONS_DEFINE= BDB_BASE CURL DOCS FILTER GNUTLS JANSSON LDNS \
- LMDB LUA MEMCACHED OPENDBX OPENLDAP POPAUTH \
+OPTIONS_DEFINE= BDB_BASE CURL DOCS FILTER GNUTLS JANSSON LMDB \
+ LUA MEMCACHED OPENDBX OPENLDAP POPAUTH \
QUERY_CACHE SASL
OPTIONS_DEFAULT= FILTER LUA UNBOUND
OPTIONS_GROUP= DEVELOPER FFR
OPTIONS_GROUP_DEVELOPER= ALLSYMBOLS CODECOVERAGE DEBUG
-OPTIONS_GROUP_FFR= ADSP_LISTS ATPS DB_HANDLE_POOLS DEFAULT_SENDER \
- DIFFHEADERS IDENTITY_HEADER LDAP_CACHING \
- LUA_ONLY_SIGNING POSTGRES_RECONNECT_HACK \
- RATE_LIMIT RBL REPLACE_RULES REPRRD REPUTATION \
- RESIGN SENDER_MACRO SOCKETDB STATS STATSEXT VBR
+OPTIONS_GROUP_FFR= ATPS DB_HANDLE_POOLS DEFAULT_SENDER DIFFHEADERS \
+ IDENTITY_HEADER LDAP_CACHING \
+ POSTGRES_RECONNECT_HACK RATE_LIMIT RBL \
+ REPLACE_RULES REPRRD REPUTATION RESIGN \
+ SENDER_MACRO SOCKETDB STATS STATSEXT VBR
OPTIONS_SINGLE= RESOLV
OPTIONS_SINGLE_RESOLV= STOCK_RESOLVER UNBOUND
NO_OPTIONS_SORT= yes
OPTIONS_SUB= yes
-ADSP_LISTS_DESC= ADSP filtering for lists (experimental)
ALLSYMBOLS_DESC= Export all internal symbols for better test coverage
ATPS_DESC= Authorized Third Party Sign check
BDB_BASE_DESC= Use Berkeley DB from base
@@ -71,10 +71,8 @@ GNUTLS_DESC= Use GnuTLS instead of OpenSSL
IDENTITY_HEADER_DESC= Special header to set identity
JANSSON_DESC= Statistics and other output as JSON data
LDAP_CACHING_DESC= LDAP query piggybacking and caching
-LDNS_DESC= Use LDNS library for DNS queries
LMDB_DESC= Use Lightning Memory-Mapped DB key-value store
LUA_DESC= Describe filter policy with lua
-LUA_ONLY_SIGNING_DESC= Message signing by Lua only
MEMCACHED_DESC= Use memcached as a data set
OPENDBX_DESC= Store filter policies via OpenDBX
OPENLDAP_DESC= Store filter policies in LDAP
@@ -96,8 +94,6 @@ STOCK_RESOLVER_DESC= Use the stock resolver library
UNBOUND_DESC= Use unbound DNS library
VBR_DESC= Vouch-By-Reference support
-ADSP_LISTS_CONFIGURE_ENABLE= adsp_lists
-
ALLSYMBOLS_CONFIGURE_ENABLE= allsymbols
ATPS_CONFIGURE_ENABLE= atps
@@ -131,17 +127,13 @@ JANSSON_CONFIGURE_WITH= libjansson
LDAP_CACHING_USES= ldap
LDAP_CACHING_CONFIGURE_ENABLE= ldap_caching
-LDNS_LIB_DEPENDS= libldns.so:dns/ldns
-LDNS_CONFIGURE_WITH= ldns
-
LMDB_LIB_DEPENDS= liblmdb.so:databases/lmdb
LMDB_CONFIGURE_WITH= lmdb
-LUA_USES= lua
-LUA_CONFIGURE_WITH= lua
-
-LUA_ONLY_SIGNING_IMPLIES= LUA
-LUA_ONLY_SIGNING_CONFIGURE_ENABLE= lua_only_signing
+LUA_USES= lua:flavors
+LUA_CONFIGURE_ENABLE= lua
+LUA_CONFIGURE_ENV= LUA_CFLAGS=-I"${LUA_INCDIR}" \
+ LUA_LIBS=-L"${LUA_LIBDIR} -llua-${LUA_VER} -lm"
MEMCACHED_LIB_DEPENDS= libmemcached.so:databases/libmemcached
MEMCACHED_CONFIGURE_WITH= libmemcached
@@ -217,14 +209,15 @@ USES+= bdb
LDFLAGS+= -lpthread
.endif
-pre-configure:
- ${REINPLACE_CMD} -e '/PKG_CHECK_MODULES/s/lua5\.[0-9]/lua-${LUA_VER}/' \
- -e '/PKG_CHECK_MODULES/s/cyrussasl/libsasl2/' \
- ${WRKSRC}/configure.ac
-
post-install:
@${MKDIR} ${STAGEDIR}${PREFIX}/etc/mail
${INSTALL_DATA} ${WRKSRC}/opendkim/opendkim.conf.sample \
${STAGEDIR}${PREFIX}/etc/mail/
-.include <bsd.port.mk>
+.include <bsd.port.pre.mk>
+
+.if ${FLAVOR:Mlua*}
+PKGNAMESUFFIX= -devel-${FLAVOR}
+.endif
+
+.include <bsd.port.post.mk>
diff --git a/mail/opendkim-devel/distinfo b/mail/opendkim-devel/distinfo
index e18ae8bf8208..9f77087c7259 100644
--- a/mail/opendkim-devel/distinfo
+++ b/mail/opendkim-devel/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1717994186
-SHA256 (trusteddomainproject-OpenDKIM-rel-opendkim-2.11.0-Beta2-48-g551ab382_GH0.tar.gz) = 216dd1dcd4cbcd68e6524c1cabe071b9a25356d3ea135c3509d689c2085f3678
-SIZE (trusteddomainproject-OpenDKIM-rel-opendkim-2.11.0-Beta2-48-g551ab382_GH0.tar.gz) = 803244
+TIMESTAMP = 1780398220
+SHA256 (trusteddomainproject-OpenDKIM-rel-opendkim-2.11.0-Beta2-49-g1c7a9f47c-1c7a9f47c658a2e2ff7f2211b9800c44f4ec046d_GH0.tar.gz) = 3caca6f24a81cb9cec4770f85a8576df71ead6366311d4e01cc4c375dde62543
+SIZE (trusteddomainproject-OpenDKIM-rel-opendkim-2.11.0-Beta2-49-g1c7a9f47c-1c7a9f47c658a2e2ff7f2211b9800c44f4ec046d_GH0.tar.gz) = 843392
diff --git a/mail/opendkim-devel/files/patch-lua_pop b/mail/opendkim-devel/files/patch-lua_pop
deleted file mode 100644
index 129d05d62e6d..000000000000
--- a/mail/opendkim-devel/files/patch-lua_pop
+++ /dev/null
@@ -1,86 +0,0 @@
-From 57b86d35381ed9bfb7e4be4e6512fb64163dd725 Mon Sep 17 00:00:00 2001
-From: FUTATSUKI Yasuhito <futatuki@yf.bsdclub.org>
-Date: Tue, 27 Feb 2024 14:41:59 +0900
-Subject: [PATCH] Lua: Fix stack level after register odkim functions.
-
-When luaL_setfuncs() is replaced by luaL_newlib() + lua_setglobal()
-in commit 74b3374feee34fba14a0e15f89f049cbe4a3dafd, the commit did
-not take account that lua_setglobal() pops a value from the stack.
-
-Thus, following lua pop(l, 1) tries to pop from empty stack in
-Lua >= 5.2, especially in Lua 5.4, it causes abort().
-
-This fix it.
-
-* miltertest/miltertest.c (main):
- Don't pop after lua_setglobal() in Lua >= 5.2
-
-* opendkim/opendkim-lua.c
- (dkimf_lua_setup_hook, dkimf_lua_screen_hook,
- dkimf_lua_stats_hook, dkimf_lua_final_hook): As above.
----
- miltertest/miltertest.c | 2 +-
- opendkim/opendkim-lua.c | 8 ++++----
- 2 files changed, 5 insertions(+), 5 deletions(-)
-
-diff --git miltertest/miltertest.c miltertest/miltertest.c
-index b4a345f7..339cfa91 100644
---- miltertest/miltertest.c
-+++ miltertest/miltertest.c
-@@ -4014,8 +4014,8 @@ main(int argc, char **argv)
- lua_setglobal(l, "mt");
- #else /* LUA_VERSION_NUM >= 502 */
- luaL_register(l, "mt", mt_library);
--#endif /* LUA_VERSION_NUM >= 502 */
- lua_pop(l, 1);
-+#endif /* LUA_VERSION_NUM >= 502 */
-
- /* register constants */
- lua_pushnumber(l, MT_HDRINSERT);
-diff --git opendkim/opendkim-lua.c opendkim/opendkim-lua.c
-index 3786aa4b..c1a67f90 100644
---- opendkim/opendkim-lua.c
-+++ opendkim/opendkim-lua.c
-@@ -490,8 +490,8 @@ dkimf_lua_setup_hook(void *ctx, const char *script, size_t scriptlen,
- lua_setglobal(l, "odkim");
- # else /* LUA_VERSION_NUM >= 502 */
- luaL_register(l, "odkim", dkimf_lua_lib_setup);
--# endif /* LUA_VERSION_NUM >= 502 */
- lua_pop(l, 1);
-+# endif /* LUA_VERSION_NUM >= 502 */
-
- /*
- ** Register constants.
-@@ -649,8 +649,8 @@ dkimf_lua_screen_hook(void *ctx, const char *script, size_t scriptlen,
- lua_setglobal(l, "odkim");
- # else /* LUA_VERSION_NUM >= 502 */
- luaL_register(l, "odkim", dkimf_lua_lib_screen);
--# endif /* LUA_VERSION_NUM >= 502 */
- lua_pop(l, 1);
-+# endif /* LUA_VERSION_NUM >= 502 */
-
- /*
- ** Register constants.
-@@ -798,8 +798,8 @@ dkimf_lua_stats_hook(void *ctx, const char *script, size_t scriptlen,
- lua_setglobal(l, "odkim");
- # else /* LUA_VERSION_NUM >= 502 */
- luaL_register(l, "odkim", dkimf_lua_lib_stats);
--# endif /* LUA_VERSION_NUM >= 502 */
- lua_pop(l, 1);
-+# endif /* LUA_VERSION_NUM >= 502 */
-
- /*
- ** Register constants.
-@@ -1039,8 +1039,8 @@ dkimf_lua_final_hook(void *ctx, const char *script, size_t scriptlen,
- lua_setglobal(l, "odkim");
- # else /* LUA_VERSION_NUM >= 502 */
- luaL_register(l, "odkim", dkimf_lua_lib_final);
--# endif /* LUA_VERSION_NUM >= 502 */
- lua_pop(l, 1);
-+# endif /* LUA_VERSION_NUM >= 502 */
-
- /*
- ** Register constants.
---
-2.45.2
-
diff --git a/mail/opendkim-devel/files/patch-opendkim_opendkim-crypto.c b/mail/opendkim-devel/files/patch-opendkim_opendkim-crypto.c
deleted file mode 100644
index b0c9326a78a5..000000000000
--- a/mail/opendkim-devel/files/patch-opendkim_opendkim-crypto.c
+++ /dev/null
@@ -1,20 +0,0 @@
---- opendkim/opendkim-crypto.c.orig 2022-12-30 01:52:49 UTC
-+++ opendkim/opendkim-crypto.c
-@@ -221,7 +221,7 @@ dkimf_crypto_free_id(void *ptr)
- {
- assert(pthread_setspecific(id_key, ptr) == 0);
-
--#if OPENSSL_VERSION_NUMBER >= 0x10100000
-+#if (OPENSSL_VERSION_NUMBER >= 0x10100000 && !defined(LIBRESSL_VERSION_NUMBER))
- OPENSSL_thread_stop();
- #else
- ERR_remove_state(0);
-@@ -399,7 +399,7 @@ dkimf_crypto_free(void)
- {
- if (crypto_init_done)
- {
--#if OPENSSL_VERSION_NUMBER >= 0x10100000
-+#if (OPENSSL_VERSION_NUMBER >= 0x10100000 && !defined(LIBRESSL_VERSION_NUMBER))
- OPENSSL_thread_stop();
- #else
- CRYPTO_cleanup_all_ex_data();
diff --git a/mail/opendkim-devel/files/patch-opendkim_opendkim.c b/mail/opendkim-devel/files/patch-opendkim_opendkim.c
deleted file mode 100644
index 8ec336794477..000000000000
--- a/mail/opendkim-devel/files/patch-opendkim_opendkim.c
+++ /dev/null
@@ -1,36 +0,0 @@
-commit 7c70ee7c86da1cecc621182355cc950d3b193314
-Author: David Bürgin <dbuergin@gluet.ch>
-Date: Sat Oct 14 09:19:37 2023 +0200
-
- Delete Authentication-Results headers in reverse
-
-diff --git opendkim/opendkim.c opendkim/opendkim.c
-index 803f37b0..cfa5f018 100644
---- opendkim/opendkim.c
-+++ opendkim/opendkim.c
-@@ -13653,8 +13653,15 @@ mlfi_eom(SMFICTX *ctx)
- return SMFIS_TEMPFAIL;
- }
-
-- c = 0;
-+ c = 1;
-+
- for (hdr = dfc->mctx_hqhead; hdr != NULL; hdr = hdr->hdr_next)
-+ {
-+ if (strcasecmp(hdr->hdr_hdr, AUTHRESULTSHDR) == 0)
-+ c++;
-+ }
-+
-+ for (hdr = dfc->mctx_hqtail; hdr != NULL; hdr = hdr->hdr_prev)
- {
- memset(ares, '\0', sizeof(struct authres));
-
-@@ -13666,7 +13673,7 @@ mlfi_eom(SMFICTX *ctx)
- char *slash;
-
- /* remember index */
-- c++;
-+ c--;
-
- /* parse the header */
- arstat = ares_parse((u_char *) hdr->hdr_val,