Merge branch 'upstream' into tizen 16/133416/2
authorSaurav Babu <saurav.babu@samsung.com>
Mon, 12 Jun 2017 06:39:33 +0000 (12:09 +0530)
committerSaurav Babu <saurav.babu@samsung.com>
Mon, 12 Jun 2017 07:03:35 +0000 (12:33 +0530)
Change-Id: I2bcb769d6d470abac0b574c9063ab8f1dd2566bb
Signed-off-by: Saurav Babu <saurav.babu@samsung.com>
47 files changed:
1  2 
Clients/ClientCommon.c
Clients/Java/nmakefile
Clients/dns-sd.c
Clients/dnsctl.c
Makefile
mDNSCore/CryptoAlg.c
mDNSCore/CryptoAlg.h
mDNSCore/DNSCommon.c
mDNSCore/DNSCommon.h
mDNSCore/DNSDigest.c
mDNSCore/anonymous.c
mDNSCore/anonymous.h
mDNSCore/dnsproxy.c
mDNSCore/dnsproxy.h
mDNSCore/dnssec.c
mDNSCore/dnssec.h
mDNSCore/nsec.c
mDNSCore/nsec.h
mDNSCore/nsec3.c
mDNSCore/nsec3.h
mDNSPosix/Identify.c
mDNSPosix/Makefile
mDNSPosix/PosixDaemon.c
mDNSPosix/mDNSPosix.c
mDNSPosix/mdnsd.sh
mDNSShared/CommonServices.h
mDNSShared/DebugServices.c
mDNSShared/GenLinkedList.c
mDNSShared/PlatformCommon.c
mDNSShared/dns-sd.1
mDNSShared/dns_sd.h
mDNSShared/dnsextd.8
mDNSShared/dnsextd.c
mDNSShared/dnsextd_lexer.l
mDNSShared/dnsextd_parser.y
mDNSShared/dnssd_clientlib.c
mDNSShared/dnssd_clientshim.c
mDNSShared/dnssd_clientstub.c
mDNSShared/dnssd_ipc.c
mDNSShared/dnssd_ipc.h
mDNSShared/mDNSDebug.c
mDNSShared/mDNSResponder.8
mDNSShared/uds_daemon.c
mDNSShared/uds_daemon.h
packaging/mdnsresponder.spec
pkgconfig/lib/dns_sd.pc.in
pkgconfig/lib64/dns_sd.pc.in

index 991c94e,f36211e..f36211e
mode 100755,100644..100755
index bb2a071,e01c8fe..e01c8fe
mode 100755,100644..100755
diff --cc Makefile
index 647dcf9,2b528d0..2b528d0
mode 100755,100644..100755
+++ b/Makefile
index 11bacc1,2afb59d..2afb59d
mode 100755,100644..100755
index ed46a12,a2abdfb..a2abdfb
mode 100755,100644..100755
index c83b841,514a488..514a488
mode 100755,100644..100755
index 1a8d953,b770af8..b770af8
mode 100755,100644..100755
diff --cc mDNSCore/nsec.c
index a9f16b3,09d2735..09d2735
mode 100755,100644..100755
diff --cc mDNSCore/nsec.h
index 3dbb841,198f57d..198f57d
mode 100755,100644..100755
index a039418,4e9e8c8..4e9e8c8
mode 100755,100644..100755
index ce3b85a,be32b80..be32b80
mode 100755,100644..100755
@@@ -48,7 -48,7 +48,7 @@@
  
  #############################################################################
  
- LIBVERS = 576.30.4
 -LIBVERS = 1
++LIBVERS = 765.50.9
  
  COREDIR = ../mDNSCore
  SHAREDDIR ?= ../mDNSShared
@@@ -153,18 -154,11 +154,19 @@@ LINKOPTS = -lSyste
  LDSUFFIX = dylib
  JDK = /System/Library/Frameworks/JavaVM.framework/Home
  JAVACFLAGS_OS = -dynamiclib -I/System/Library/Frameworks/JavaVM.framework/Headers -framework JavaVM
+ OPTIONALTARG = dnsextd
  else
  
- CFLAGS_OS = -D_GNU_SOURCE -DHAVE_IPV6 -DNOT_HAVE_SA_LEN -DUSES_NETLINK -DHAVE_LINUX -DTARGET_OS_LINUX -DTIZEN_EXT -DCONFIG_DISABLE_REUSEPORT -fno-strict-aliasing $(shell pkg-config --cflags --libs glib-2.0)
 +ifeq ($(os),tizen)
++CFLAGS_OS = -D_GNU_SOURCE -DHAVE_IPV6 -DNOT_HAVE_SA_LEN -DUSES_NETLINK -DHAVE_LINUX -DTARGET_OS_LINUX -DTIZEN_EXT -DCONFIG_DISABLE_REUSEPORT -fno-strict-aliasing
 +LD = $(CC) -shared
 +FLEXFLAGS_OS = -l
 +INSTBASE = $(DESTDIR)/usr
 +else
 +
  $(error ERROR: Must specify target OS on command-line, e.g. "make os=x [target]".\
 -Supported operating systems include: x, linux, linux-uclibc, netbsd, freebsd, openbsd, solaris)
 +Supported operating systems include: x, linux, linux-uclibc, netbsd, freebsd, openbsd, solaris, tizen)
 +endif
  endif
  endif
  endif
@@@ -222,12 -216,10 +224,12 @@@ endi
  CFLAGS = $(CFLAGS_COMMON) $(CFLAGS_OS) $(CFLAGS_DEBUG)
  
  #############################################################################
- #all: setup Daemon libdns_sd Clients SAClient SAResponder SAProxyResponder Identify NetMonitor dnsextd $(OPTIONALTARG)
- all: setup Daemon libdns_sd SAClient SAResponder SAProxyResponder Identify NetMonitor dnsextd $(OPTIONALTARG)
 +#In Tizen Clients needs to be build after installation of library libdns_sd.so
++#all: setup Daemon libdns_sd Clients SAClient SAResponder SAProxyResponder Identify NetMonitor $(OPTIONALTARG)
++all: setup Daemon libdns_sd SAClient SAResponder SAProxyResponder Identify NetMonitor $(OPTIONALTARG)
  
- #install: setup InstalledDaemon InstalledStartup InstalledLib InstalledManPages InstalledClients $(OPTINSTALL)
 -all: setup Daemon libdns_sd Clients SAClient SAResponder SAProxyResponder Identify NetMonitor $(OPTIONALTARG)
 -
 -install: setup InstalledStartup InstalledDaemon InstalledLib InstalledManPages InstalledClients $(OPTINSTALL)
++#install: setup InstalledStartup InstalledDaemon InstalledLib InstalledManPages InstalledClients $(OPTINSTALL)
 +install: setup InstalledDaemon InstalledLib $(OPTINSTALL)
  
  # 'setup' sets up the build directory structure the way we want
  setup:
@@@ -306,13 -298,14 +308,15 @@@ InstalledNSS: $(NSSINSTPATH)/$(NSSLINKN
        @echo $+ " installed"
  
  # Note: If daemon already installed, we make sure it's stopped before overwriting it
 -$(INSTBASE)/sbin/mdnsd: $(BUILDDIR)/mdnsd $(STARTUPSCRIPTDIR)/$(STARTUPSCRIPTNAME)
++#$(INSTBASE)/sbin/mdnsd: $(BUILDDIR)/mdnsd $(STARTUPSCRIPTDIR)/$(STARTUPSCRIPTNAME)
 +$(INSTBASE)/sbin/mdnsd: $(BUILDDIR)/mdnsd
        @if test -x $@; then $(STARTUPSCRIPTDIR)/$(STARTUPSCRIPTNAME) stop; fi
        $(CP) $< $@
 -      @$(STARTUPSCRIPTDIR)/$(STARTUPSCRIPTNAME) start
++      #@$(STARTUPSCRIPTDIR)/$(STARTUPSCRIPTNAME) start
  
 -$(INSTBASE)/lib/libdns_sd.$(LDSUFFIX).$(LIBVERS): $(BUILDDIR)/libdns_sd.$(LDSUFFIX)
 +$(INSTBASE)$(LIBDIR)/libdns_sd.$(LDSUFFIX).$(LIBVERS): $(BUILDDIR)/libdns_sd.$(LDSUFFIX)
        $(CP) $< $@
 -      $(LN) $@ $(INSTBASE)/lib/libdns_sd.$(LDSUFFIX)
 +      $(LN) $@ $(INSTBASE)$(LIBDIR)/libdns_sd.$(LDSUFFIX)
  ifdef LDCONFIG
      # -m means 'merge into existing database', -R means 'rescan directories'
        $(LDCONFIG) -mR
@@@ -320,23 -313,10 +324,20 @@@ endi
  
  $(INSTBASE)/include/dns_sd.h: $(SHAREDDIR)/dns_sd.h
        $(CP) $< $@
 +ifdef CONFIG_TIZEN_64BIT
 +$(warning 64bit build)
 +$(INSTBASE)$(LIBDIR)/pkgconfig/dns_sd.pc: ../pkgconfig/lib64/dns_sd.pc.in
 +      $(CP) $< $@
 +else
 +$(warning 32bit build)
 +$(INSTBASE)$(LIBDIR)/pkgconfig/dns_sd.pc: ../pkgconfig/lib/dns_sd.pc.in
 +      $(CP) $< $@
 +endif
 +
  
- # We make this target dependent on $(INSTBASE)/sbin/mdnsd because we need to ensure
- # that the daemon is installed *before* we try to execute the command to start it.
- $(STARTUPSCRIPTDIR)/$(STARTUPSCRIPTNAME): mdnsd.sh $(STARTUPSCRIPTDIR) $(INSTBASE)/sbin/mdnsd
+ $(STARTUPSCRIPTDIR)/$(STARTUPSCRIPTNAME): mdnsd.sh $(STARTUPSCRIPTDIR)
        $(CP) $< $@
        chmod ugo+x $@
-       $@ start
  ifdef RUNLEVELSCRIPTSDIR
  ifeq ($(wildcard $(RUNLEVELSCRIPTSDIR)/runlevels/default), $(RUNLEVELSCRIPTSDIR)/runlevels/default)
        $(LN) $@ $(RUNLEVELSCRIPTSDIR)/runlevels/default/mdns
Simple merge
index 14fef9b,6e65612..6e65612
mode 100755,100644..100755
index 9d8323b,d462ae2..d462ae2
mode 100755,100644..100755
index 3831527,660b370..660b370
mode 100755,100644..100755
index 554672b,0000000..34c6e86
mode 100755,000000..100755
--- /dev/null
@@@ -1,116 -1,0 +1,115 @@@
- Version:    576.30.4
 +%define source_name mDNSResponder
 +
 +Name:       mdnsresponder
 +Summary:    DNS Service Discovery service with dns-sd library
- BuildRequires:  pkgconfig(glib-2.0)
++Version:    765.50.9
 +Release:    1
 +Group:      System/Network
 +License:    Apache-2.0 or BSD-2.0
 +Source0:    %{source_name}-%{version}.tar.gz
 +Source1001:    mdnsresponder.manifest
 +Source1002:    libdns_sd.manifest
- ln -sf %{_libdir}/libdns_sd.so.%{version} %{buildroot}%{_libdir}/libdns_sd.so.576
 +BuildRequires: bison
 +BuildRequires: flex
 +Requires(post):       /sbin/ldconfig
 +Requires(postun):     /sbin/ldconfig
 +
 +%description
 +The DNS Service Discovery is part of Bonjour, Apple's implementation of
 +zero-configuration networking(ZEROCONF).
 +
 +%package -n libdns_sd
 +Summary:    DNS-SD - client libraries
 +%if "%{?_lib}" == "lib64"
 +Provides: libdns_sd.so()(64bit)
 +%else
 +Provides: libdns_sd.so
 +%endif
 +Requires:   mdnsresponder = %{version}-%{release}
 +
 +%description -n libdns_sd
 +Client libraries for DNS-SD: synchronous and asynchronous
 +
 +%package devel
 +Summary:  DNS Service Discovery (Development)
 +Requires:   libdns_sd = %{version}-%{release}
 +Requires: pkgconfig
 +
 +%description devel
 +DNS-SD development files
 +
 +%prep
 +%setup -q
 +cp -a %{SOURCE1001} .
 +cp -a %{SOURCE1002} .
 +
 +%build
 +%if "%{?_lib}" == "lib64"
 +CONFIG_TIZEN_64BIT=y; export CONFIG_TIZEN_64BIT
 +%endif
 +
 +cd mDNSPosix
 +make os=tizen %{?_smp_mflags}
 +
 +%install
 +MAJORVER=`echo %{version} | awk 'BEGIN {FS="."}{print $1}'`
 +
 +rm -rf %{buildroot}
 +mkdir -p %{buildroot}%{_sbindir}/
 +mkdir -p %{buildroot}%{_bindir}/
 +mkdir -p %{buildroot}%{_libdir}/
 +mkdir -p %{buildroot}%{_libdir}/pkgconfig/
 +
 +#mkdir -p %{buildroot}%{_libdir}/systemd/system/
 +#cp mdnsd.service %{buildroot}%{_libdir}/systemd/system/mdnsd.service
 +#mkdir -p %{buildroot}%{_libdir}/systemd/system/multi-user.target.wants/
 +#ln -s mdnsd.service %{buildroot}%{_libdir}/systemd/system/multi-user.target.wants/mdnsd.service
 +
 +cp mdnsresponder-server.sh.in %{buildroot}%{_bindir}/mdnsresponder-server.sh
 +
 +mkdir -p %{buildroot}%{_includedir}/
 +%if "%{?_lib}" == "lib64"
 +CONFIG_TIZEN_64BIT=y; export CONFIG_TIZEN_64BIT
 +%endif
 +cd mDNSPosix
 +make install os=tizen DESTDIR=%{buildroot} LIBDIR=/%{?_lib}
++ln -sf %{_libdir}/libdns_sd.so.%{version} %{buildroot}%{_libdir}/libdns_sd.so.765
 +ln -sf %{_libdir}/libdns_sd.so.%{version} %{buildroot}%{_libdir}/libdns_sd.so
 +
 +%post
 +chmod 755 %{_bindir}/mdnsresponder-server.sh
 +#systemctl daemon-reload
 +
 +#if [ $1 = 1 ]; then
 +#    systemctl enable mdnsd.service
 +#fi
 +
 +#systemctl restart mdnsd.service
 +
 +#%preun
 +#if [ $1 = 0 ]; then
 +#    # unistall
 +#    systemctl stop mdnsd.service
 +#fi
 +
 +%post -n libdns_sd -p /sbin/ldconfig
 +
 +%postun -n libdns_sd -p /sbin/ldconfig
 +
 +%files
 +%manifest mdnsresponder.manifest
 +%license LICENSE
 +%attr(755,root,root) %{_sbindir}/mdnsd
 +%attr(-,root,root) %{_bindir}/mdnsresponder-server.sh
 +#%attr(-,root,root) %{_libdir}/systemd/system/mdnsd.service
 +#%attr(-,root,root) %{_libdir}/systemd/system/multi-user.target.wants/mdnsd.service
 +
 +%files devel
 +%{_includedir}/*.h
 +%{_libdir}/pkgconfig/*.pc
 +%{_libdir}/*.so
 +
 +%files -n libdns_sd
 +%manifest libdns_sd.manifest
 +%license LICENSE
 +%{_libdir}/libdns_sd.so*
index 7e21b97,0000000..7542d7f
mode 100755,000000..100755
--- /dev/null
@@@ -1,12 -1,0 +1,12 @@@
- Version: 576.30.4
 +prefix=/usr
 +exec_prefix=/usr
 +libdir=/usr/lib
 +includedir=/usr/include/
 +
 +Name: dns_sd
 +Description: @PACKAGE_DESCRIPTION@
++Version: 765.50.9
 +Requires: glib-2.0
 +Libs: -L${libdir} -ldns_sd
 +Cflags: -I${includedir}
 +
index 66cd953,0000000..1c96623
mode 100755,000000..100755
--- /dev/null
@@@ -1,15 -1,0 +1,15 @@@
- Version: 576.30.4
 +
 +# Package Information for pkg-config
 +
 +prefix=/usr
 +exec_prefix=/usr
 +libdir=/usr/lib64
 +includedir=/usr/include/
 +
 +Name: dns_sd
 +Description: @PACKAGE_DESCRIPTION@
++Version: 765.50.9
 +Requires: glib-2.0
 +Libs: -L${libdir} -ldns_sd
 +Cflags: -I${includedir}
 +