git: de5e3b65d949 - main - net/openmdns: update 0.7 -> 0.9 and take maintenership
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Thu, 19 Mar 2026 23:19:34 UTC
The branch main has been updated by rodrigo:
URL: https://cgit.FreeBSD.org/ports/commit/?id=de5e3b65d949a8b95b29c4381216a4524c434943
commit de5e3b65d949a8b95b29c4381216a4524c434943
Author: Rodrigo Osorio <rodrigo@FreeBSD.org>
AuthorDate: 2026-03-19 23:04:50 +0000
Commit: Rodrigo Osorio <rodrigo@FreeBSD.org>
CommitDate: 2026-03-19 23:17:45 +0000
net/openmdns: update 0.7 -> 0.9 and take maintenership
Changelog:
https://github.com/haesbaert/mdnsd/releases/tag/0.8
https://github.com/haesbaert/mdnsd/releases/tag/0.9
Major changes:
* Move mdnsl into a static libmdns library
* Silently ignore T_NULL RR records generated by legacy Airdrop on macOS
* Update rr_type_name to produce "NULL" as the name of type T_NULL(10)
* Allow us to reflect PTR packets between two interfaces/networks in the daemon.
* Fix RR leaks from cache_process()
Port changes:
* Reorder Makefile to make portlint happy
* Take port maintenership
---
net/openmdns/Makefile | 25 ++++++++--------
net/openmdns/distinfo | 6 ++--
net/openmdns/files/patch-libmdns_Makefile | 18 +++++++++++
net/openmdns/files/patch-mdnsd_mdns.c | 50 ++-----------------------------
net/openmdns/files/patch-mdnsd_mdnsd.c | 16 +++++-----
5 files changed, 44 insertions(+), 71 deletions(-)
diff --git a/net/openmdns/Makefile b/net/openmdns/Makefile
index 86f2c45b0352..bc203bb9d191 100644
--- a/net/openmdns/Makefile
+++ b/net/openmdns/Makefile
@@ -1,45 +1,46 @@
PORTNAME= openmdns
-DISTVERSION= 0.7
-PORTREVISION= 3
+DISTVERSION= 0.9
CATEGORIES= net
-MAINTAINER= ports@FreeBSD.org
+MAINTAINER= rodrigo@FreeBSD.org
COMMENT= Multicast DNS and Service Discovery daemon
WWW= http://www.haesbaert.org/openmdns/
LICENSE= ISCL
+USES= localbase uidfix
USE_GITHUB= yes
GH_ACCOUNT= haesbaert
GH_PROJECT= mdnsd
-CONFLICTS_INSTALL= mDNSResponder # sbin/mdnsd
-
-USES= localbase uidfix
USE_RC_SUBR= mdnsd
-MAKE_ENV= LDADD="${LIBS}"
MAKE_ARGS= BINDIR="${PREFIX}/sbin" \
MANDIR="${PREFIX}/share/man/man"
+MAKE_ENV= LDADD="${LIBS}"
CFLAGS+= -D__dead=__dead2
LDFLAGS+= -Wl,--as-needed # -lutil
LIBS+= -lopenbsd
+
+CONFLICTS_INSTALL= mDNSResponder # sbin/mdnsd
+
SUB_LIST= COMMENT="${COMMENT}"
+
+USERS= _mdnsd
+GROUPS= _mdnsd
+
PLIST_FILES= sbin/mdnsctl \
sbin/mdnsd \
share/man/man8/mdnsctl.8.gz \
share/man/man8/mdnsd.8.gz
PORTDOCS= *
-USERS= _mdnsd
-GROUPS= _mdnsd
-
OPTIONS_DEFINE= DOCS STATIC
STATIC_BUILD_DEPENDS= ${LOCALBASE}/lib/libevent.a:devel/libevent \
${LOCALBASE}/lib/libopenbsd.a:devel/libopenbsd
-STATIC_MAKE_ENV= NO_SHARED=1
STATIC_LIB_DEPENDS_OFF= libevent.so:devel/libevent \
libopenbsd.so:devel/libopenbsd
+STATIC_MAKE_ENV= NO_SHARED=1
post-patch:
# warning: duplicate script for target "maninstall" ignored
@@ -47,6 +48,6 @@ post-patch:
post-install-DOCS-on:
(cd ${WRKSRC}/docs && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR})
- ${INSTALL_DATA} ${WRKSRC}/README ${STAGEDIR}${DOCSDIR}
+ ${INSTALL_DATA} ${WRKSRC}/README.md ${STAGEDIR}${DOCSDIR}
.include <bsd.port.mk>
diff --git a/net/openmdns/distinfo b/net/openmdns/distinfo
index 20a11c6c0c63..33a3ec2ee98f 100644
--- a/net/openmdns/distinfo
+++ b/net/openmdns/distinfo
@@ -1,3 +1,3 @@
-TIMESTAMP = 1489137852
-SHA256 (haesbaert-mdnsd-0.7_GH0.tar.gz) = cb552f3431e57a3ad09b011f91ebdb8cc100a5c38978fcdb0fea27fc5ebd2880
-SIZE (haesbaert-mdnsd-0.7_GH0.tar.gz) = 2935140
+TIMESTAMP = 1773758709
+SHA256 (haesbaert-mdnsd-0.9_GH0.tar.gz) = 70e068512fc92648a3a10e948653278396deabb2a5fb04e215b77d1ac64f0545
+SIZE (haesbaert-mdnsd-0.9_GH0.tar.gz) = 2946500
diff --git a/net/openmdns/files/patch-libmdns_Makefile b/net/openmdns/files/patch-libmdns_Makefile
new file mode 100644
index 000000000000..5dfdda229bea
--- /dev/null
+++ b/net/openmdns/files/patch-libmdns_Makefile
@@ -0,0 +1,18 @@
+--- libmdns/Makefile.orig 2025-12-01 15:56:40 UTC
++++ libmdns/Makefile
+@@ -1,11 +1,14 @@
+ LIB= mdns
+ SRCS+= mdnsl.c
+
+-CFLAGS+= -g -Wall
++CFLAGS+= -g -Wall -fPIC
+ CFLAGS+= -Wstrict-prototypes -Wmissing-prototypes
+ CFLAGS+= -Wmissing-declarations
+ CFLAGS+= -Wshadow -Wpointer-arith -Wcast-qual
+ CFLAGS+= -Wsign-compare
+ CFLAGS+= -I${.CURDIR} -I${.CURDIR}/../mdnsd
+
++install:
++ @:
++
+ .include <bsd.lib.mk>
diff --git a/net/openmdns/files/patch-mdnsd_mdns.c b/net/openmdns/files/patch-mdnsd_mdns.c
index a01c1ab456cd..c656d2f27c2f 100644
--- a/net/openmdns/files/patch-mdnsd_mdns.c
+++ b/net/openmdns/files/patch-mdnsd_mdns.c
@@ -1,6 +1,6 @@
---- mdnsd/mdns.c.orig 2017-03-10 09:24:12 UTC
+--- mdnsd/mdns.c.orig 2026-03-19 21:39:49 UTC
+++ mdnsd/mdns.c
-@@ -45,6 +45,9 @@ extern struct mdnsd_conf *conf;
+@@ -45,6 +45,9 @@
struct question_tree question_tree;
struct cache_tree cache_tree;
@@ -10,49 +10,3 @@
/*
* RR cache
*/
-@@ -155,8 +158,10 @@ cache_process(struct rr *rr)
- /* TODO Cancel possible deletion */
- log_warnx("cache_process: recover %s",
- rrs_str(&rr->rrs));
-+ free(rr);
- return (0);
- }
-+ free(rr);
- return (0);
- }
- /*
-@@ -167,6 +172,7 @@ cache_process(struct rr *rr)
- log_warnx("cache_process: conflict for %s",
- rrs_str(&rr->rrs));
- conflict_resolve_by_rr(rr_aux);
-+ free(rr);
- return (-1);
- }
- }
-@@ -178,6 +184,7 @@ cache_process(struct rr *rr)
- log_warnx("cache_process: goodbye %s",
- rrs_str(&rr->rrs));
- cache_delete(rr_aux);
-+ free(rr);
- return (0);
- }
- /* Cache refresh */
-@@ -186,14 +193,17 @@ cache_process(struct rr *rr)
- rr_aux->ttl = rr->ttl;
- rr_aux->revision = 0;
- cache_schedrev(rr_aux);
-+ free(rr);
-
- return (0);
- }
- }
- }
- /* Got a goodbye for a record we don't have */
-- if (rr->ttl == 0)
-+ if (rr->ttl == 0) {
-+ free(rr);
- return (0);
-+ }
-
- return (cache_insert(rr));
- }
diff --git a/net/openmdns/files/patch-mdnsd_mdnsd.c b/net/openmdns/files/patch-mdnsd_mdnsd.c
index afb138cae4b0..5ab2334e4f8a 100644
--- a/net/openmdns/files/patch-mdnsd_mdnsd.c
+++ b/net/openmdns/files/patch-mdnsd_mdnsd.c
@@ -1,8 +1,8 @@
---- mdnsd/mdnsd.c.orig 2017-03-10 09:24:12 UTC
+--- mdnsd/mdnsd.c.orig 2026-03-19 21:46:02 UTC
+++ mdnsd/mdnsd.c
-@@ -45,8 +45,12 @@ int mdns_sock(void);
- void fetchmyname(char [MAXHOSTNAMELEN]);
- void fetchhinfo(struct hinfo *);
+@@ -51,8 +51,12 @@
+ void fetchhinfo(struct hinfo *);
+ struct reflect_rule *parse_reflect_rule(char *);
+ctl_conns_t ctl_conns;
+
@@ -13,13 +13,13 @@
__dead void
usage(void)
-@@ -230,7 +234,9 @@ main(int argc, char *argv[])
+@@ -307,7 +311,9 @@
switch (ch) {
case 'd':
debug = 1;
+#ifdef __OpenBSD__
- malloc_options = "AFGJPX";
+ malloc_options = "CFGJ";
+#endif
break;
- case 'v':
- display_version();
+ default:
+ break;