JNI library support for getenv. An ebuild will follow. Reproducible: Always Steps to Reproduce: 1. 2. 3.
Created attachment 66177 [details] tos-getenv-1.1.14.ebuild
no source code changes in tinyos 1.1.15, no version bump needed
Created attachment 78429 [details] update to 1.1.15, with ebuild enhancements
java team, please review this ebuild. I don't want to break anything, and maybe there are other jdk that support javacomm.
Just a little change to the submitted ebuild. --- Desktop/tos-getenv-1.1.15.ebuild 2006-01-29 21:08:02.000000000 +0100 +++ /mnt/gentoo32/usr/local/portage/dev-tinyos/tos-getenv/tos-getenv-1.1.15.ebuild 2006-01-29 17:44:17.000000000 +0100 @@ -6,7 +6,7 @@ CVS_YEAR="2005" MY_P="tinyos" -inherit java-utils toolchain-funcs +inherit eutils java-utils toolchain-funcs DESCRIPTION="TinyOS JNI getenv support library" HOMEPAGE="http://www.tinyos.net/" @@ -21,6 +21,12 @@ S="${WORKDIR}/${MY_P}-${PV}${CVS_MONTH}${CVS_YEAR}cvs/tools/java/jni" pkg_setup() { + if ! built_with_use dev-java/ibm-jdk-bin javacomm ; then + eerror "javacomm is required! Add javacomm to your use flag then re-emerge ibm-jdk-bin." + eerror "Then re-emerge this package." + die "setup failed due to missing prerequisite: javacomm" + fi + java-utils_setup-vm java-utils_ensure-vm-version-ge 1 4 0 @@ -31,12 +37,6 @@ eerror "Please use java-config -S to set your system vm to a ibm-jdk." die "setup failed due to missing prerequisite: ibm-jdk-bin" fi - - if ! useq javacomm ; then - eerror "javacomm is required! Add javacomm to your use flag then re-emerge ibm-jdk-bin." - eerror "Then re-emerge this package." - die "setup failed due to missing prerequisite: javacomm" - fi }
It looks like javacomm might be available independently from the JDK. It would be better to depend on that, than depending on using a particular JDK. http://java.sun.com/products/javacomm/ Will need to look into it a little more though.
ibm-jdk-bin has it's own jvacomm package, I don't know if ther's a more general way to require javacomm. What seems to require ibm instead of any other jdk is a comment in the make file shipped with tinyos. It says: # The install rules assume that JNI libraries should be placed in .../jre/bin # This seems to be true on Windows, and IBM's Linux Java # It's not true for Sun's Linux Java (but we don't have javax.comm for that, so...)
Now in portage, closing.