Ty Sarna
2009-09-20 19:53:49 UTC
I'd like to import Apple's mDNSResponder to the system. I think
zeroconf is becoming more basic functionality, and is desirable across
NetBSD's range of markets these days. Embedded devices and servers
want to advertise services this way, and desktops want to access them.
There seem to be three potential choices out there for mDNS these
days: Avahi, Apple's mDNSResponder, and the NetBSD SoC zeroconf.
Avahi is LGPL. mDNSResponder used to be APSL. Neither of those being
acceptable, I believe that led to the SoC project. That project is
still unfinished however, and in the meantime mDNSResponder has been
relicensed in a combination of Apache2 (server) and BSD 3-clause
(client library). As it is effectively the reference implementation,
is externally maintained, and used in at least two other OSes (OS X of
course, and it looks like OpenSolaris as well), it seems like the
clear choice to me.
So, I would like to proceed as follows. There are a number of open
questions or options.
1) Import mDNSResponder (currently 212.1, vs ancient 108 in pkgsrc) in
src/external/apache2/dist. It will need a prepare-import.sh script to
nuke the $Log$ lines in the sources (ugh!) and we can also prune out
the Windows, OS X, MacOS 9, vxWorks, etc. sources.
2) Add reachover makefile for mdnsd. (QUESTION: do we want to call it
mdnsd, which is how the supplied makefile builds it for "posix", or
mDNSResponder, which is what OS/X calls it? OpenSolaris went with mdnsd)
3) dnsetxd has yacc source that requires a feature not present in our
current yacc (YYPARSE_PARAM), so it will not be built for now.
4) OPTION: the pkg currently installs some debugging tools like
mDNSIdentify, mDNSClientPosix, etc. These don't ship in OS X. Do we
reachover these as well? My feeling is no -- get them from pkgsrc if
you need them.
5) Create a _mdnsd (_mdnsresponder?) user/group and get mdnsd to run
under it. The issue is writing the socket and pid file in /var/run,
which it doesn't have permissions to. Other than that it works fine.
My idea is to create /var/run/mdnsd, owned by _mdnsd, and change the
code to create the socket & pid file under there instead of in /var/run.
6) Create a rc.d script for it (QUESTION: does it default on or off?)
7) Supply client library functionality (QUESTION: separate libdns_sd,
or include in libc a'la OS X? OpenSolaris went separate.)
8) I would like to reachover for dns-sd(1) as well, but that one file
seems to still bear a APSL license. I will contact Apple about getting
that relicensed.
9) Write a new nss_mdns plugin. The current pkgsrc one is a wrapper
around one written for Linux, and it has issues. (OPTION: separate
nss_mdns.so plugin, or if we build the client functionality into libc,
do we build in the nss plugin too?) I have open questions about how
this integrates with regular DNS-SD (a'la PR 32373 -- see David
Young's message on tech-net from 20090303)
--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
zeroconf is becoming more basic functionality, and is desirable across
NetBSD's range of markets these days. Embedded devices and servers
want to advertise services this way, and desktops want to access them.
There seem to be three potential choices out there for mDNS these
days: Avahi, Apple's mDNSResponder, and the NetBSD SoC zeroconf.
Avahi is LGPL. mDNSResponder used to be APSL. Neither of those being
acceptable, I believe that led to the SoC project. That project is
still unfinished however, and in the meantime mDNSResponder has been
relicensed in a combination of Apache2 (server) and BSD 3-clause
(client library). As it is effectively the reference implementation,
is externally maintained, and used in at least two other OSes (OS X of
course, and it looks like OpenSolaris as well), it seems like the
clear choice to me.
So, I would like to proceed as follows. There are a number of open
questions or options.
1) Import mDNSResponder (currently 212.1, vs ancient 108 in pkgsrc) in
src/external/apache2/dist. It will need a prepare-import.sh script to
nuke the $Log$ lines in the sources (ugh!) and we can also prune out
the Windows, OS X, MacOS 9, vxWorks, etc. sources.
2) Add reachover makefile for mdnsd. (QUESTION: do we want to call it
mdnsd, which is how the supplied makefile builds it for "posix", or
mDNSResponder, which is what OS/X calls it? OpenSolaris went with mdnsd)
3) dnsetxd has yacc source that requires a feature not present in our
current yacc (YYPARSE_PARAM), so it will not be built for now.
4) OPTION: the pkg currently installs some debugging tools like
mDNSIdentify, mDNSClientPosix, etc. These don't ship in OS X. Do we
reachover these as well? My feeling is no -- get them from pkgsrc if
you need them.
5) Create a _mdnsd (_mdnsresponder?) user/group and get mdnsd to run
under it. The issue is writing the socket and pid file in /var/run,
which it doesn't have permissions to. Other than that it works fine.
My idea is to create /var/run/mdnsd, owned by _mdnsd, and change the
code to create the socket & pid file under there instead of in /var/run.
6) Create a rc.d script for it (QUESTION: does it default on or off?)
7) Supply client library functionality (QUESTION: separate libdns_sd,
or include in libc a'la OS X? OpenSolaris went separate.)
8) I would like to reachover for dns-sd(1) as well, but that one file
seems to still bear a APSL license. I will contact Apple about getting
that relicensed.
9) Write a new nss_mdns plugin. The current pkgsrc one is a wrapper
around one written for Linux, and it has issues. (OPTION: separate
nss_mdns.so plugin, or if we build the client functionality into libc,
do we build in the nss plugin too?) I have open questions about how
this integrates with regular DNS-SD (a'la PR 32373 -- see David
Young's message on tech-net from 20090303)
--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de