xnap works fine on macosx, it just need to have virtual/jre-1.3 in package-provided to be emerged. I've tried inserting dev-java/sun-jdk-1.4.2_05 but it wasn't working. Reproducible: Always Steps to Reproduce: 1. 2. 3.
I was forgetting, with the installer version of portage there was a problem in the installation (bug 57878), the script xnap wasn't installed. The masked portage-2.0.51-pre20 solve this problem. If you don't want to emerge the portage (maybe as devs will suggest), copy the script yourself after emerging xnap: cp /var/tmp/portage/xnap-2.5-r3/work/xnap /opt/bin/
*** Bug 61636 has been marked as a duplicate of this bug. ***
There is no $JAVA_HOME in profile (maybe for missing java-config?), so I've done this change at the ebuild: --- /usr/portage/net-p2p/xnap/xnap-2.5-r3.ebuild Wed Aug 11 20:43:54 2004 +++ xnap-2.5-r4.ebuild Thu Sep 9 14:26:57 2004 @@ -7,8 +7,8 @@ SRC_URI="mirror://sourceforge/xnap/${P}r3.jar" LICENSE="GPL-2" SLOT="0" -KEYWORDS="~x86 ~ppc ~sparc ~alpha" -IUSE="" +KEYWORDS="~macos ~x86 ~ppc ~sparc ~alpha" +IUSE="macos" RDEPEND=">=virtual/jre-1.3" S=${WORKDIR} @@ -24,7 +24,11 @@ echo "#!/bin/sh" > ${PN} echo "cd /opt/${PN}" >> ${PN} - echo '${JAVA_HOME}'/bin/java -jar lib/${PN}.jar '$*' >> ${PN} + if use macos ; then + echo /usr/bin/java -jar lib/${PN}.jar '$*' >> ${PN} + else + echo '${JAVA_HOME}'/bin/java -jar lib/${PN}.jar '$*' >> ${PN} + fi into /opt dobin ${PN}
Please move ~macos keyword to the last. Any new keyword is added to the last (And we plan to change the keyword name shortly.). Also, you shouldn't add arch keyword to IUSE. See Ebuild HOWTO http://www.gentoo.org/proj/en/devrel/handbook/handbook.xml?part=2&chap=1
look at this: --- /usr/portage/net-p2p/xnap/xnap-2.5-r3.ebuild Wed Aug 11 20:43:54 2004 +++ /usr/local/portage/net-p2p/xnap/xnap-2.5-r4.ebuild Fri Sep 10 00:04:03 2004 @@ -7,7 +7,7 @@ SRC_URI="mirror://sourceforge/xnap/${P}r3.jar" LICENSE="GPL-2" SLOT="0" -KEYWORDS="~x86 ~ppc ~sparc ~alpha" +KEYWORDS="~x86 ~ppc ~sparc ~alpha ~macos" IUSE="" RDEPEND=">=virtual/jre-1.3" @@ -24,7 +24,11 @@ echo "#!/bin/sh" > ${PN} echo "cd /opt/${PN}" >> ${PN} - echo '${JAVA_HOME}'/bin/java -jar lib/${PN}.jar '$*' >> ${PN} + if use macos ; then + echo /usr/bin/java -jar lib/${PN}.jar '$*' >> ${PN} + else + echo '${JAVA_HOME}'/bin/java -jar lib/${PN}.jar '$*' >> ${PN} + fi into /opt dobin ${PN}
killing the JAVA_HOME in the ebuild is not the best of workarounds (ciaranm would probably agree). This really depends on the baselayout virtual being satisfied on macos.
Sorry, won't "fix" this.