From 48536dc6a7eee005a7dff1731a4d0587eebac6b1 Mon Sep 17 00:00:00 2001 From: adam Date: Wed, 12 Jan 2011 08:53:52 +0000 Subject: [PATCH] Changes 258.14: This is the version supplied with Mac OS X 10.6.6. --- net/mDNSResponder/Makefile | 26 ++++++++--------------- net/mDNSResponder/builtin.mk | 10 ++++----- net/mDNSResponder/distinfo | 19 +++++++++-------- net/mDNSResponder/patches/patch-aa | 34 ++++++++++++++++++++++++++---- net/mDNSResponder/patches/patch-ab | 16 +++++++------- net/mDNSResponder/patches/patch-ac | 8 +++---- net/mDNSResponder/patches/patch-ad | 4 ++-- net/mDNSResponder/patches/patch-ae | 12 +++++------ net/mDNSResponder/patches/patch-af | 17 +++++++++++++++ 9 files changed, 91 insertions(+), 55 deletions(-) create mode 100644 net/mDNSResponder/patches/patch-af diff --git a/net/mDNSResponder/Makefile b/net/mDNSResponder/Makefile index 137caa8404d0..4a44a3a8161c 100644 --- a/net/mDNSResponder/Makefile +++ b/net/mDNSResponder/Makefile @@ -1,20 +1,18 @@ -# $NetBSD: Makefile,v 1.33 2010/12/20 14:17:01 tez Exp $ +# $NetBSD: Makefile,v 1.34 2011/01/12 08:53:52 adam Exp $ -DISTNAME= mDNSResponder-214.3.2 -PKGREVISION= 1 +DISTNAME= mDNSResponder-258.14 CATEGORIES= net MASTER_SITES= http://www.opensource.apple.com/tarballs/mDNSResponder/ MAINTAINER= pkgsrc-users@NetBSD.org HOMEPAGE= http://developer.apple.com/bonjour/ COMMENT= Apple's mDNS responder +LICENSE= apache-2.0 AND modified-bsd -MAKE_JOBS_SAFE= no - -USE_TOOLS+= gmake flex bison -BUILD_DIRS= mDNSPosix -BUILDDIR= ${WRKSRC}/mDNSPosix/build/prod -AUTO_MKDIRS= yes +USE_TOOLS+= gmake flex bison +BUILD_DIRS= mDNSPosix +BUILDDIR= ${WRKSRC}/mDNSPosix/build/prod +AUTO_MKDIRS= yes PKG_DESTDIR_SUPPORT= user-destdir @@ -32,13 +30,7 @@ MAKE_ENV+= os=solaris .elif ${OPSYS} == "Linux" MAKE_ENV+= os=linux .elif ${OPSYS} == "Darwin" -. if !empty(OS_VERSION:M6*) -MAKE_ENV+= os=jaguar -. elif !empty(OS_VERSION:M7*) -MAKE_ENV+= os=panther -. elif !empty(OS_VERSION:M8*) -MAKE_ENV+= os=tiger -. endif +MAKE_ENV+= os=x SO_SUFFIX= dylib .else MAKE_ENV+= os=netbsd @@ -56,7 +48,7 @@ SBINARY= mdnsd dnsextd !empty(MACHINE_PLATFORM:MSunOS-5.[0-9]-*) .include "../../devel/librfuncs/buildlink3.mk" -MAKE_ENV+= EXTRA_LIBS=-Wl,-R${BUILDLINK_PREFIX.librfuncs:Q}/lib\ ${BUILDLINK_LDFLAGS.librfuncs:Q} +MAKE_ENV+= EXTRA_LIBS=-Wl,-R${BUILDLINK_PREFIX.librfuncs}/lib\ ${BUILDLINK_LDFLAGS.librfuncs:Q} .else MAKE_ENV+= EXTRA_LIBS= .endif diff --git a/net/mDNSResponder/builtin.mk b/net/mDNSResponder/builtin.mk index 49fa40f146a1..999bcf70d9ec 100644 --- a/net/mDNSResponder/builtin.mk +++ b/net/mDNSResponder/builtin.mk @@ -1,4 +1,4 @@ -# $NetBSD: builtin.mk,v 1.1 2010/07/14 17:45:30 drochner Exp $ +# $NetBSD: builtin.mk,v 1.2 2011/01/12 08:53:52 adam Exp $ BUILTIN_PKG:= mDNSResponder @@ -30,13 +30,13 @@ _BLTN_DNSSD_212_1!= \ ${GREP} -c 2120100 ${H_DNSSD} || ${TRUE} _BLTN_DNSSD_214_3_2!= \ ${GREP} -c 2140302 ${H_DNSSD} || ${TRUE} -. if ${_BLTN_DNSSD_214_3_2} == "1" +. if ${_BLTN_DNSSD_214_3_2} == "1" BUILTIN_VERSION.mDNSResponder= 214.3.2 -. elif ${_BLTN_DNSSD_212_1} == "1" +. elif ${_BLTN_DNSSD_212_1} == "1" BUILTIN_VERSION.mDNSResponder= 212.1 -. else +. else BUILTIN_VERSION.mDNSResponder= 0 #unknown -. endif +. endif BUILTIN_PKG.mDNSResponder= mDNSResponder-${BUILTIN_VERSION.mDNSResponder} .endif diff --git a/net/mDNSResponder/distinfo b/net/mDNSResponder/distinfo index 0408b1b53965..a9ebc7701d6e 100644 --- a/net/mDNSResponder/distinfo +++ b/net/mDNSResponder/distinfo @@ -1,10 +1,11 @@ -$NetBSD: distinfo,v 1.23 2010/12/15 22:33:41 jmcneill Exp $ +$NetBSD: distinfo,v 1.24 2011/01/12 08:53:52 adam Exp $ -SHA1 (mDNSResponder-214.3.2.tar.gz) = bd59e0e3008ba797a30360dd8e59beb7152d9872 -RMD160 (mDNSResponder-214.3.2.tar.gz) = f9670f661083dae5529422b19655ba9c473960c7 -Size (mDNSResponder-214.3.2.tar.gz) = 1633510 bytes -SHA1 (patch-aa) = 6a899e729b7ed1aa43497934a98e37b2fd9411d4 -SHA1 (patch-ab) = 712e3999854215b9ea14f6d444262beef8c545b1 -SHA1 (patch-ac) = f328cfed7da68b61dc1afa9908aade33cfd5ecc3 -SHA1 (patch-ad) = fa77b934a63bd07f9b0a4697a3c1a59d242fca19 -SHA1 (patch-ae) = f124201460929b86300664ff9ee31c0d845759c9 +SHA1 (mDNSResponder-258.14.tar.gz) = 2a34794ff9a5184ce1e57ccea4001b5af6635f7b +RMD160 (mDNSResponder-258.14.tar.gz) = fbd9dcfa84dbeb9de379066958a0b509af074dbc +Size (mDNSResponder-258.14.tar.gz) = 1833244 bytes +SHA1 (patch-aa) = 3f31f10ab6bf0d3ec72b56791cc4db5f24bfeb0b +SHA1 (patch-ab) = 8567d3a9849377fdfd1fd98f1b0dd164561bb6c9 +SHA1 (patch-ac) = 3fb065c49ed434f031ea29214ec4140b24f8da64 +SHA1 (patch-ad) = 612390897ad2f395ceb7394b644f977c4858d6cc +SHA1 (patch-ae) = b22eeebf70abb26f7b69374fb5a0dd9720c3957b +SHA1 (patch-af) = bce933daa008f081b72c5d509e84704be13360dc diff --git a/net/mDNSResponder/patches/patch-aa b/net/mDNSResponder/patches/patch-aa index a8cf22428e64..8e9300f1d908 100644 --- a/net/mDNSResponder/patches/patch-aa +++ b/net/mDNSResponder/patches/patch-aa @@ -1,10 +1,19 @@ -$NetBSD: patch-aa,v 1.10 2010/07/20 00:04:08 sbd Exp $ +$NetBSD: patch-aa,v 1.11 2011/01/12 08:53:52 adam Exp $ Find libpthread.so when not on the default rpath. +Allow custom CC and CFLAGS. --- mDNSPosix/Makefile.orig 2009-02-02 19:44:06.000000000 +0000 +++ mDNSPosix/Makefile -@@ -326,7 +326,7 @@ LN = ln -s -f +@@ -54,7 +54,6 @@ COREDIR = ../mDNSCore + SHAREDDIR ?= ../mDNSShared + JDK = /usr/jdk + +-CC = @cc + BISON = @bison + FLEX = @flex + LD = ld -shared +@@ -64,7 +64,7 @@ LN = ln -s -f CFLAGS_COMMON = -I$(COREDIR) -I$(SHAREDDIR) -I$(OBJDIR) -fwrapv -W -Wall -DPID_FILE=\"/var/run/mdnsd.pid\" -DMDNS_UDS_SERVERPATH=\"/var/run/mdnsd\" CFLAGS_PTHREAD = LINKOPTS = @@ -13,7 +22,7 @@ Find libpthread.so when not on the default rpath. LDSUFFIX = so JAVACFLAGS_OS = -fPIC -shared -ldns_sd -@@ -362,7 +362,7 @@ endif +@@ -100,7 +100,7 @@ endif else ifeq ($(os),linux) @@ -22,7 +31,7 @@ Find libpthread.so when not on the default rpath. FLEXFLAGS_OS = -l JAVACFLAGS_OS += -I$(JDK)/include/linux OPTIONALTARG = nss_mdns -@@ -388,7 +388,7 @@ CFLAGS_OS = +@@ -126,7 +126,7 @@ CFLAGS_OS = # -pthread # Link a user-threaded process against libc_r instead of libc. CFLAGS_PTHREAD = -pthread -D_THREAD_SAFE @@ -31,3 +40,20 @@ Find libpthread.so when not on the default rpath. JAVACFLAGS_OS += -I$(JDK)/include/freebsd LDCONFIG = ldconfig else +@@ -141,7 +140,6 @@ ifeq ($(os),x) + # we get build failures: ‘daemon’ is deprecated (declared at /usr/include/stdlib.h:283) + CFLAGS_OS = -DHAVE_IPV6 -no-cpp-precomp -Werror -Wdeclaration-after-statement \ + -D__MAC_OS_X_VERSION_MIN_REQUIRED=__MAC_OS_X_VERSION_10_4 #-Wunreachable-code +-CC = @gcc-4.0 + LD = $(CC) -dynamiclib + LINKOPTS = -lSystem + LDSUFFIX = dylib +@@ -205,7 +204,7 @@ endif + endif + endif + +-CFLAGS = $(CFLAGS_COMMON) $(CFLAGS_OS) $(CFLAGS_DEBUG) ++CFLAGS += $(CFLAGS_COMMON) $(CFLAGS_OS) -DMDNS_DEBUGMSGS=0 + + ############################################################################# + diff --git a/net/mDNSResponder/patches/patch-ab b/net/mDNSResponder/patches/patch-ab index dac0156ceb26..28d6ece0acba 100644 --- a/net/mDNSResponder/patches/patch-ab +++ b/net/mDNSResponder/patches/patch-ab @@ -1,4 +1,4 @@ -$NetBSD: patch-ab,v 1.7 2010/07/14 09:29:04 sbd Exp $ +$NetBSD: patch-ab,v 1.8 2011/01/12 08:53:52 adam Exp $ 1) add patch from http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/147007 @@ -6,9 +6,9 @@ $NetBSD: patch-ab,v 1.7 2010/07/14 09:29:04 sbd Exp $ -fix some RFC2292 vs 3542 confusion which made the former fail -on NetBSD, build a HINFO record from hw.model and kern.osrelease ---- mDNSPosix/mDNSPosix.c.orig 2009-01-25 03:16:46.000000000 +0000 +--- mDNSPosix/mDNSPosix.c.orig 2010-05-20 22:35:08.000000000 +0000 +++ mDNSPosix/mDNSPosix.c -@@ -581,7 +581,7 @@ mDNSexport int ParseDNSServers(mDNS *m, +@@ -467,7 +467,7 @@ mDNSexport int ParseDNSServers(mDNS *m, { char line[256]; char nameserver[16]; @@ -17,7 +17,7 @@ $NetBSD: patch-ab,v 1.7 2010/07/14 09:29:04 sbd Exp $ int numOfServers = 0; FILE *fp = fopen(filePath, "r"); if (fp == NULL) return -1; -@@ -600,6 +600,7 @@ mDNSexport int ParseDNSServers(mDNS *m, +@@ -486,6 +486,7 @@ mDNSexport int ParseDNSServers(mDNS *m, numOfServers++; } } @@ -25,7 +25,7 @@ $NetBSD: patch-ab,v 1.7 2010/07/14 09:29:04 sbd Exp $ return (numOfServers > 0) ? 0 : -1; } -@@ -802,7 +803,13 @@ mDNSlocal int SetupSocket(struct sockadd +@@ -690,7 +691,13 @@ mDNSlocal int SetupSocket(struct sockadd { struct ipv6_mreq imr6; struct sockaddr_in6 bindAddr6; @@ -40,7 +40,7 @@ $NetBSD: patch-ab,v 1.7 2010/07/14 09:29:04 sbd Exp $ if (err == 0) { err = setsockopt(*sktPtr, IPPROTO_IPV6, IPV6_PKTINFO, &kOn, sizeof(kOn)); -@@ -811,7 +818,13 @@ mDNSlocal int SetupSocket(struct sockadd +@@ -699,7 +706,13 @@ mDNSlocal int SetupSocket(struct sockadd #else #warning This platform has no way to get the destination interface information for IPv6 -- will only work for single-homed hosts #endif @@ -55,7 +55,7 @@ $NetBSD: patch-ab,v 1.7 2010/07/14 09:29:04 sbd Exp $ if (err == 0) { err = setsockopt(*sktPtr, IPPROTO_IPV6, IPV6_HOPLIMIT, &kOn, sizeof(kOn)); -@@ -1293,6 +1306,36 @@ mDNSlocal mDNSBool mDNSPlatformInit_CanR +@@ -1181,6 +1194,36 @@ mDNSlocal mDNSBool mDNSPlatformInit_CanR return(err == 0); } @@ -92,7 +92,7 @@ $NetBSD: patch-ab,v 1.7 2010/07/14 09:29:04 sbd Exp $ // mDNS core calls this routine to initialise the platform-specific data. mDNSexport mStatus mDNSPlatformInit(mDNS *const m) { -@@ -1314,6 +1357,10 @@ mDNSexport mStatus mDNSPlatformInit(mDNS +@@ -1202,6 +1245,10 @@ mDNSexport mStatus mDNSPlatformInit(mDNS GetUserSpecifiedRFC1034ComputerName(&m->hostlabel); if (m->hostlabel.c[0] == 0) MakeDomainLabelFromLiteralString(&m->hostlabel, "Computer"); diff --git a/net/mDNSResponder/patches/patch-ac b/net/mDNSResponder/patches/patch-ac index 31b172f151e8..8d9e92af23c2 100644 --- a/net/mDNSResponder/patches/patch-ac +++ b/net/mDNSResponder/patches/patch-ac @@ -1,4 +1,4 @@ -$NetBSD: patch-ac,v 1.8 2010/12/15 22:33:42 jmcneill Exp $ +$NetBSD: patch-ac,v 1.9 2011/01/12 08:53:52 adam Exp $ * Fix build on FreeBSD and DragonFly, as shown in recent bulk builds and PR 34022. @@ -7,7 +7,7 @@ $NetBSD: patch-ac,v 1.8 2010/12/15 22:33:42 jmcneill Exp $ --- mDNSPosix/mDNSUNP.c.orig 2009-01-13 00:31:35.000000000 -0500 +++ mDNSPosix/mDNSUNP.c 2010-12-04 19:25:49.000000000 -0500 -@@ -188,8 +188,10 @@ First checkin +@@ -54,8 +54,10 @@ First checkin #include #endif @@ -19,7 +19,7 @@ $NetBSD: patch-ac,v 1.8 2010/12/15 22:33:42 jmcneill Exp $ #include // Note: netinet/in_var.h implicitly includes netinet6/in6_var.h for us #endif -@@ -239,6 +241,8 @@ struct ifi_info *get_ifi_info_linuxv6(in +@@ -105,6 +107,8 @@ struct ifi_info *get_ifi_info_linuxv6(in addr[4],addr[5],addr[6],addr[7], &index, &plen, &scope, &flags, ifname) != EOF) { @@ -28,7 +28,7 @@ $NetBSD: patch-ac,v 1.8 2010/12/15 22:33:42 jmcneill Exp $ myflags = 0; if (strncmp(lastname, ifname, IFNAMSIZ) == 0) { if (doaliases == 0) -@@ -273,7 +277,6 @@ struct ifi_info *get_ifi_info_linuxv6(in +@@ -139,7 +143,6 @@ struct ifi_info *get_ifi_info_linuxv6(in memcpy(ifi->ifi_addr, res0->ai_addr, sizeof(struct sockaddr_in6)); /* Add netmask of the interface */ diff --git a/net/mDNSResponder/patches/patch-ad b/net/mDNSResponder/patches/patch-ad index 5d900d161a40..7dd0b98e6a24 100644 --- a/net/mDNSResponder/patches/patch-ad +++ b/net/mDNSResponder/patches/patch-ad @@ -1,8 +1,8 @@ -$NetBSD: patch-ad,v 1.1 2010/07/14 10:14:43 sbd Exp $ +$NetBSD: patch-ad,v 1.2 2011/01/12 08:53:52 adam Exp $ --- Clients/Makefile.orig 2008-09-05 17:37:08.000000000 +0000 +++ Clients/Makefile -@@ -81,7 +81,7 @@ build: +@@ -42,7 +42,7 @@ build: mkdir build build/dns-sd: build dns-sd.c ClientCommon.c diff --git a/net/mDNSResponder/patches/patch-ae b/net/mDNSResponder/patches/patch-ae index 5511f0689ea1..a1a7572d18dd 100644 --- a/net/mDNSResponder/patches/patch-ae +++ b/net/mDNSResponder/patches/patch-ae @@ -1,8 +1,8 @@ -$NetBSD: patch-ae,v 1.2 2010/07/19 14:14:14 tnn Exp $ +$NetBSD: patch-ae,v 1.3 2011/01/12 08:53:52 adam Exp $ ---- mDNSShared/CommonServices.h.orig 2009-03-30 19:51:29.000000000 +0000 +--- mDNSShared/CommonServices.h.orig 2009-08-11 01:13:47.000000000 +0000 +++ mDNSShared/CommonServices.h -@@ -102,6 +102,24 @@ Common Services and portability support +@@ -64,6 +64,24 @@ #endif #endif @@ -27,7 +27,7 @@ $NetBSD: patch-ae,v 1.2 2010/07/19 14:14:14 tnn Exp $ // Solaris #if( !defined( TARGET_OS_SOLARIS ) ) -@@ -128,7 +146,7 @@ Common Services and portability support +@@ -90,7 +108,7 @@ // No predefined macro for VxWorks so just assume VxWorks if nothing else is set. @@ -36,7 +36,7 @@ $NetBSD: patch-ae,v 1.2 2010/07/19 14:14:14 tnn Exp $ #define TARGET_OS_VXWORKS 1 #else #define TARGET_OS_VXWORKS 0 -@@ -224,6 +242,19 @@ Common Services and portability support +@@ -186,6 +204,19 @@ #include #include @@ -56,7 +56,7 @@ $NetBSD: patch-ae,v 1.2 2010/07/19 14:14:14 tnn Exp $ #elif( TARGET_OS_SOLARIS ) // Solaris -@@ -493,7 +524,7 @@ Common Services and portability support +@@ -455,7 +486,7 @@ // - Windows #if( TARGET_LANGUAGE_C_LIKE ) diff --git a/net/mDNSResponder/patches/patch-af b/net/mDNSResponder/patches/patch-af new file mode 100644 index 000000000000..6b429aeeebd7 --- /dev/null +++ b/net/mDNSResponder/patches/patch-af @@ -0,0 +1,17 @@ +$NetBSD: patch-af,v 1.1 2011/01/12 08:53:52 adam Exp $ + +mDNSPlatformSetAllowSleep only defined for Mac OS X. + +--- mDNSCore/mDNS.c.orig 2010-10-08 23:05:00.000000000 +0000 ++++ mDNSCore/mDNS.c +@@ -4011,8 +4011,10 @@ mDNSexport void mDNS_UpdateAllowSleep(mD + #endif /* !defined(IDLESLEEPCONTROL_DISABLED) */ + } + ++#if 0 + // Call the platform code to enable/disable sleep + mDNSPlatformSetAllowSleep(m, allowSleep); ++#endif + } + + mDNSlocal void SendSPSRegistration(mDNS *const m, NetworkInterfaceInfo *intf, const mDNSOpaque16 id)