octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[cygwin] enabling java support


From: CdeMills
Subject: [cygwin] enabling java support
Date: Mon, 10 Mar 2014 12:29:57 -0700 (PDT)

Hello,

there are a few modifications to bring under cygwin for java support. I have
non-cygwin openjdk installed under /cygdrive/c/Program
Files/Java/jdk1.7.0_45:

1) apply this patch:
--- a/libinterp/octave-value/ov-java.h  Thu Mar 06 14:40:35 2014 -0500
+++ b/libinterp/octave-value/ov-java.h  Mon Mar 10 20:13:45 2014 +0100
@@ -23,6 +23,12 @@
 #if !defined (octave_ov_java_h)
 #define octave_ov_java_h 1
 
+#if defined (__CYGWIN__)
+/* maps jni.h idea of 64-bit ints to gcc implementation */
+#include <stdint.h>
+typedef int64_t __int64 ; //Portable signed long integer 8 bytes
+#endif
+
 #include <jni.h>
 
 #include <oct-obj.h>

2) in "scripts/Makefile", use the following rule:
%.class : %.java
        $(MKDIR_P) java/$(org_octave_dir)
        ( cd $(srcdir)/java; "$(JAVAC)" -source 1.3 -target 1.3 -d
`$(CYGPATH_W) $(abs_builddir)/java` $(org_octave_dir)/$(<F) )

The idea is to call  "java" with Windows path convention

3) This compiles ... but does not run:
x = javaObject ("java.lang.StringBuffer", "Initial string")
error: javaObject: /libjvm.so: failed to load: No such file or directory

It seems the lib to call is "libjvm.dll" instead of libjvm.so ? Any clue on
how to force this ?

Regards

Pascal



--
View this message in context: 
http://octave.1599824.n4.nabble.com/cygwin-enabling-java-support-tp4662973.html
Sent from the Octave - Maintainers mailing list archive at Nabble.com.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]