From af20e6e2b13dd5c1e4cbb94b2634820f9a02c1f1 Mon Sep 17 00:00:00 2001
From: Christian McDonald <me@rcm.sh>
Date: Fri, 13 Jan 2023 11:07:44 -0500
Subject: [PATCH] add dynlib module port option

---
 dns/unbound/Makefile | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/dns/unbound/Makefile b/dns/unbound/Makefile
index 99733d2cd3c6..537f239caf91 100644
--- a/dns/unbound/Makefile
+++ b/dns/unbound/Makefile
@@ -1,5 +1,6 @@
 PORTNAME=	unbound
 DISTVERSION=	1.17.0
+PORTREVISION=	1
 CATEGORIES=	dns
 MASTER_SITES=	https://www.nlnetlabs.nl/downloads/unbound/

@@ -32,8 +33,8 @@ PORTDOCS=	CNAME-basedRedirectionDesignNotes.pdf CREDITS Changelog \
 		ietf67-design-02.pdf requirements.txt

 OPTIONS_DEFINE=		DEP-RSA1024 DNSCRYPT DNSTAP DOCS DOH ECDSA EVAPI \
-			FILTER_AAAA GOST HIREDIS LIBEVENT MUNIN_PLUGIN PYTHON \
-			SUBNET TFOCL TFOSE THREADS
+			DYNLIB FILTER_AAAA GOST HIREDIS LIBEVENT MUNIN_PLUGIN \
+			PYTHON SUBNET TFOCL TFOSE THREADS
 OPTIONS_DEFAULT=	DNSCRYPT DOH ECDSA GOST LIBEVENT THREADS
 OPTIONS_SUB=		yes

@@ -41,6 +42,7 @@ DEP-RSA1024_DESC=	Deprecate the use of RSA 1024 keys
 DNSCRYPT_DESC=		Enable dnscrypt support
 DNSTAP_DESC=		Enable dnstap logging support
 DOH_DESC=		Enable DNS-over-HTTPS support
+DYNLIB_DESC=		Enable dynamic (shared) library support
 ECDSA_DESC=		Enable ECDSA (elliptic curve) support (OpenSSL >= 1.0)
 EVAPI_DESC=		(Experimental) pluggable event based libunbound API support
 FILTER_AAAA_DESC=	Build with AAAA filter functionality (contrib)
@@ -63,6 +65,7 @@ DNSTAP_LIB_DEPENDS=		libfstrm.so:devel/fstrm \
 DNSTAP_CONFIGURE_ENABLE=	dnstap
 DOH_LIB_DEPENDS=		libnghttp2.so:www/libnghttp2
 DOH_CONFIGURE_ON=		--with-libnghttp2
+DYNLIB_CONFIGURE_ON=		--with-dynlibmodule
 ECDSA_CONFIGURE_ENABLE=		ecdsa
 ECDSA_VARS=			DEPENDS_ARGS+=WITH_ECDSA=yes
 EVAPI_CONFIGURE_ENABLE=		event-api
--
2.39.0