diff options
author | Carsten Lohrke <carlo@gentoo.org> | 2007-04-28 15:12:04 +0000 |
---|---|---|
committer | Carsten Lohrke <carlo@gentoo.org> | 2007-04-28 15:12:04 +0000 |
commit | 0b21f6ef5a7a6dd3bdd82d0f1e2cdf92b43b8e2d (patch) | |
tree | a17d0c5574c3e9397ea53753d271801425f24b44 /net-misc/mDNSResponder | |
parent | Version bump. (diff) | |
download | gentoo-2-0b21f6ef5a7a6dd3bdd82d0f1e2cdf92b43b8e2d.tar.gz gentoo-2-0b21f6ef5a7a6dd3bdd82d0f1e2cdf92b43b8e2d.tar.bz2 gentoo-2-0b21f6ef5a7a6dd3bdd82d0f1e2cdf92b43b8e2d.zip |
Fix Java build, thanks to Krzysiek Pawlik, bug #176334.
(Portage version: 2.1.2.5)
Diffstat (limited to 'net-misc/mDNSResponder')
4 files changed, 165 insertions, 1 deletions
diff --git a/net-misc/mDNSResponder/ChangeLog b/net-misc/mDNSResponder/ChangeLog index 73da55c28cda..cc1f59e844a2 100644 --- a/net-misc/mDNSResponder/ChangeLog +++ b/net-misc/mDNSResponder/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for net-misc/mDNSResponder # Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-misc/mDNSResponder/ChangeLog,v 1.31 2007/04/28 12:43:13 carlo Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-misc/mDNSResponder/ChangeLog,v 1.32 2007/04/28 15:12:04 carlo Exp $ + +*mDNSResponder-107.6-r4 (28 Apr 2007) + + 28 Apr 2007; Carsten Lohrke <carlo@gentoo.org> + +files/mDNSResponder-107.6-java.patch, +mDNSResponder-107.6-r4.ebuild: + Fix Java build, thanks to Krzysiek Pawlik, bug #176334. *mDNSResponder-107.6-r3 (28 Apr 2007) diff --git a/net-misc/mDNSResponder/files/digest-mDNSResponder-107.6-r4 b/net-misc/mDNSResponder/files/digest-mDNSResponder-107.6-r4 new file mode 100644 index 000000000000..dc5573b1daf0 --- /dev/null +++ b/net-misc/mDNSResponder/files/digest-mDNSResponder-107.6-r4 @@ -0,0 +1,3 @@ +MD5 aa4e0e5c57f94489463ea6576591ce9d mDNSResponder-107.6.tar.gz 1441339 +RMD160 68d9ef5949839a950d673c66cc8d0e5bd0348fbb mDNSResponder-107.6.tar.gz 1441339 +SHA256 43d427d3d5c78aef57a49898def469cc4cae28190462205368be1f3a0fcc0165 mDNSResponder-107.6.tar.gz 1441339 diff --git a/net-misc/mDNSResponder/files/mDNSResponder-107.6-java.patch b/net-misc/mDNSResponder/files/mDNSResponder-107.6-java.patch new file mode 100644 index 000000000000..1a4fec6d93c9 --- /dev/null +++ b/net-misc/mDNSResponder/files/mDNSResponder-107.6-java.patch @@ -0,0 +1,38 @@ +diff -Nru mDNSResponder-107.6.vanilla/Clients/Java/nmakefile mDNSResponder-107.6/Clients/Java/nmakefile +--- mDNSResponder-107.6.vanilla/Clients/Java/nmakefile 2007-04-28 15:32:09.000000000 +0200 ++++ mDNSResponder-107.6/Clients/Java/nmakefile 2007-04-28 15:32:50.000000000 +0200 +@@ -94,7 +94,7 @@ + JAVASRC = . + .SUFFIXES : .java + {$(JAVASRC)}.java{$(BAOBJ)}.class: +- $(JAVAC) -d $(BAOBJ) -classpath $(BAOBJ);$(DNS_SD) $< ++ $(JAVAC) $(JAVACFLAGS) -d $(BAOBJ) -classpath $(BAOBJ);$(DNS_SD) $< + {$(JAVASRC)}.java{$(SCOBJ)}.class: +- $(JAVAC) -d $(SCOBJ) -classpath $(SCOBJ);$(DNS_SD) $< ++ $(JAVAC) $(JAVACFLAGS) -d $(SCOBJ) -classpath $(SCOBJ);$(DNS_SD) $< + +diff -Nru mDNSResponder-107.6.vanilla/mDNSPosix/Makefile mDNSResponder-107.6/mDNSPosix/Makefile +--- mDNSResponder-107.6.vanilla/mDNSPosix/Makefile 2007-04-28 15:32:09.000000000 +0200 ++++ mDNSResponder-107.6/mDNSPosix/Makefile 2007-04-28 15:33:34.000000000 +0200 +@@ -585,7 +585,7 @@ + JAVAH = $(JDK)/bin/javah + JAVADOC = $(JDK)/bin/javadoc + JAR = $(JDK)/bin/jar +-JAVACFLAGS = $(CFLAGS) $(JAVACFLAGS_OS) -I$(JDK)/include ++JAVACFLAGS_C = $(CFLAGS) $(JAVACFLAGS_OS) -I$(JDK)/include + + Java: setup $(BUILDDIR)/dns_sd.jar $(BUILDDIR)/libjdns_sd.$(LDSUFFIX) + @echo "Java wrappers done" +@@ -610,10 +610,10 @@ + $(JAR) -cf $@ -C $(OBJDIR) com + + $(BUILDDIR)/libjdns_sd.$(LDSUFFIX): $(JAVASRC)/JNISupport.c $(OBJDIR)/DNSSD.java.h setup libdns_sd +- $(CC) -o $@ $< $(JAVACFLAGS) -I$(OBJDIR) -L$(BUILDDIR) ++ $(CC) -o $@ $< $(JAVACFLAGS_C) -I$(OBJDIR) -L$(BUILDDIR) + + $(OBJDIR)/com/apple/dnssd/%.class: $(JAVASRC)/%.java +- $(JAVAC) -d $(OBJDIR) -classpath $(OBJDIR) $< ++ $(JAVAC) $(JAVACFLAGS) -d $(OBJDIR) -classpath $(OBJDIR) $< + + $(OBJDIR)/DNSSD.java.h: $(OBJDIR)/com/apple/dnssd/DNSSD.class + $(JAVAH) -force -classpath $(OBJDIR) -o $@ \ diff --git a/net-misc/mDNSResponder/mDNSResponder-107.6-r4.ebuild b/net-misc/mDNSResponder/mDNSResponder-107.6-r4.ebuild new file mode 100644 index 000000000000..42bd1eb3bad2 --- /dev/null +++ b/net-misc/mDNSResponder/mDNSResponder-107.6-r4.ebuild @@ -0,0 +1,117 @@ +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-misc/mDNSResponder/mDNSResponder-107.6-r4.ebuild,v 1.1 2007/04/28 15:12:04 carlo Exp $ + +inherit eutils base toolchain-funcs flag-o-matic java-pkg-opt-2 + +DESCRIPTION="The mDNSResponder project is a component of Bonjour, Apple's initiative for zero-configuration networking." +HOMEPAGE="http://developer.apple.com/networking/bonjour/index.html" +SRC_URI="http://www.opensource.apple.com/darwinsource/tarballs/other/${P}.tar.gz" +LICENSE="APSL-2 BSD" + +SLOT="0" +KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd" +IUSE="debug doc ipv6" + +DEPEND="!sys-auth/nss-mdns + java? ( >=virtual/jdk-1.5 )" +RDEPEND="!sys-auth/nss-mdns + java? ( >=virtual/jre-1.5 )" + +PATCHES="${FILESDIR}/mDNSResponder-107.6-Makefiles.diff ${FILESDIR}/mDNSResponder-107.6-java.patch" +pkg_setup() { + if use elibc_FreeBSD; then + os=freebsd + else + os=linux + fi +} + +mdnsmake() { + local debug jdk __ipv6 + use java && jdk="JDK=$(java-config -O)" + use debug && debug='DEBUG=1' + use ipv6 && __ipv6='HAVE_IPV6=1' || __ipv6='HAVE_IPV6=0' + einfo "Running emake " os="${os}" CC="$(tc-getCC)" LD="$(tc-getCC) -shared" \ + ${jdk} ${debug} OPT_CFLAGS="${CFLAGS}" LIBFLAGS="${LDFLAGS}" \ + LOCALBASE="/usr" JAVACFLAGS="$(java-pkg_javac-args)" "$@" + emake -j1 os="${os}" CC="$(tc-getCC)" LD="$(tc-getCC) -shared" \ + ${jdk} ${debug} OPT_CFLAGS="${CFLAGS}" LIBFLAGS="${LDFLAGS}" \ + LOCALBASE="/usr" JAVACFLAGS="$(java-pkg_javac-args)" ${__ipv6} "$@" +} + +src_compile() { + cd ${S}/mDNSPosix + mdnsmake || die "make failed" + + if use java; then + mdnsmake Java || die "make mDNSPosix java failed" + if use doc ; then + mdnsmake JavaDoc || die "make mDNSPosix java doc failed" + fi + fi +} + +src_install() { + cd "${S}/mDNSPosix" + + dodir /usr/sbin + dodir /usr/lib + dodir /usr/include + dodir /lib + dodir /etc + dodir /usr/share/man/man5 + dodir /usr/share/man/man8 + + local debug + local objdir="prod" + if use debug; then + debug="DEBUG=1" + objdir=debug + fi + + dosbin ${S}/mDNSPosix/build/${objdir}/dnsextd + dosbin ${S}/mDNSPosix/build/${objdir}/mDNSResponderPosix + dosbin ${S}/mDNSPosix/build/${objdir}/mDNSNetMonitor + dosbin ${S}/mDNSPosix/build/${objdir}/mdnsd + + dobin ${S}/Clients/build/dns-sd + dobin ${S}/mDNSPosix/build/${objdir}/mDNSProxyResponderPosix + dobin ${S}/mDNSPosix/build/${objdir}/mDNSIdentify + dobin ${S}/mDNSPosix/build/${objdir}/mDNSClientPosix + + dolib ${S}/mDNSPosix/build/${objdir}/libdns_sd.so + dolib ${S}/mDNSPosix/build/${objdir}/libnss_mdns-0.2.so + dosym libdns_sd.so /usr/$(get_libdir)/libdns_sd.so.1 + dosym libnss_mdns-0.2.so /usr/$(get_libdir)/libnss_mdns.so.2 + + newinitd ${FILESDIR}/mdnsd.init.d mdnsd + newinitd ${FILESDIR}/mDNSResponderPosix.init.d mDNSResponderPosix + newconfd ${FILESDIR}/mDNSResponderPosix.conf.d mDNSResponderPosix + newinitd ${FILESDIR}/dnsextd.init.d dnsextd + newconfd ${FILESDIR}/dnsextd.conf.d dnsextd + + insinto /etc + doins ${FILESDIR}/mDNSResponderPosix.conf + + insinto /usr/include + doins ${S}/mDNSShared/dns_sd.h + + dodoc ${S}/README.txt + + if use java; then + java-pkg_dojar ${S}/mDNSPosix/build/${objdir}/dns_sd.jar + java-pkg_doso ${S}/mDNSPosix/build/${objdir}/libjdns_sd.so + use doc && java-pkg_dojavadoc ${S}/mDNSPosix/build/${objdir} + fi + +} + +pkg_postinst() { + echo + elog "To enable multicast dns lookups for applications" + elog "that are not multicast dns aware, edit the 'hosts:'" + elog "line in /etc/nsswitch.conf to include 'mdns', e.g.:" + elog "hosts: files mdns dns" + echo +} |