Strange problem with Oracle JDK7 b147 (Release Candidate)

[EDIT:] I first wrote it would affect OpenJDK 7, but I realized I have Oracle’s JDK 7 b 147 (Release Candidate) from http://jdk7.java.net/download.html installed [/EDIT]



Hi

I can run Mythruna from OpenJDK6’s JRE without problems. Console output starts with

/usr/lib/jvm/java-6-openjdk/bin/java -XX:MaxDirectMemorySize=892m -Xmx892m -jar Mythruna-20110705.jar

Reading log configuration…

07.07.2011 00:54:38 com.jme3.system.Natives extractNativeLib

WARNUNG: Cannot locate native library: linux/libbulletjme.so


bind:de.lessvoid.nifty.screen.Screen@63713b42
Render time (>100 ms):151.438359 ms.
onStartScreen:start
go(singlePlayer)
[...]

Starting from Oracle JDK7's JRE:

java -XX:MaxDirectMemorySize=2048m -Xmx2048m -jar Mythruna-20110705.jarReading log configuration...
Jul 07, 2011 12:58:20 AM com.jme3.system.Natives extractNativeLib
Warnung: Cannot locate native library: linux/libbulletjme.so

then Mythruna aborts with generating an error file named "-error.log containing

Uncaught exception from thread:Thread[LWJGL Renderer Thread,5,main]
java.lang.UnsatisfiedLinkError: Can't load library: /opt/Mythruna/liblwjgl.so
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1828)
at java.lang.Runtime.load0(Runtime.java:792)
at java.lang.System.load(System.java:1059)
at org.lwjgl.Sys$1.run(Sys.java:70)
at java.security.AccessController.doPrivileged(Native Method)
at org.lwjgl.Sys.doLoadLibrary(Sys.java:66)
at org.lwjgl.Sys.loadLibrary(Sys.java:82)
at org.lwjgl.Sys.(Sys.java:99)
at com.jme3.system.lwjgl.LwjglAbstractDisplay.run(LwjglAbstractDisplay.java:198)
at java.lang.Thread.run(Thread.java:722)

(Warnung = warning, translated from german ;) )
Other Java-based applications (Eclipse, RSSOwl, JDownloader and others) run without problems.
// EDIT:
Using Ubuntu Linux 2.6.38 on x86-64 on Core i5 with iGPU
The file "/opt/Mythruna/liblwjgl.so" does not exist.

I prefer to use SunJdk 7 instead OpeJdk 7 in linux :). But anyway that file doesn’t exist or Mythruna can’t find it?

File does not exist.

Mythruna has no problems with OpenJDK6 but crashes with OracleJDK7

Hmm. Then @pspeed have to see it…

Did you already try to copy the Mythruna/liblwjgl.so file to /opt by hand in command-line?

This is entirely a JME issue. I don’t do anything with that file. It’s supposed to be extracted from the jme jars when they run, I guess… maybe it isn’t being done in this case or somehow incompatible with the platform.



I’m not sure how to fix it.



Do other JME test apps work?

Actually, that path looks bizarre to me in general… but it’s still nothing I do directly. :slight_smile: It’s somewhere in the JME internals.

Maybe it’s a permission problem :roll:? Anyway another strange behavior the output showed :“WARNUNG: Cannot locate native library: linux/libbulletjme.so” in both cases.

The jbullet thing has been there a while now and is harmless. For some reason, even apps that don’t use jbullet at all see this warning since some update way back.

Its strange… If there is any exception when copying it should be reported in the console. I would say the best way is to debug the Natives class and see if that file is actually opened and written to.

Ok, JMonkeyPlatform has a similar problem starting with Oracle JDK7:

On startup it shows a note:


Warning - could not install some modules: jME3 Code Checks - The module Java Hints was requested in implementation version "4" but only "7" was found.

I had the choice to disable the module or exit JMP. I disabled the module and JMP started. JMP's status bar shows an error, "show details" shows this Exception:

java.lang.UnsatisfiedLinkError: Can't load library: /home/christian/.jmonkeyplatform/liblwjgl.so
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1828)
at java.lang.Runtime.load0(Runtime.java:792)
at java.lang.System.load(System.java:1059)
at org.lwjgl.Sys$1.run(Sys.java:70)
at java.security.AccessController.doPrivileged(Native Method)
at org.lwjgl.Sys.doLoadLibrary(Sys.java:66)
at org.lwjgl.Sys.loadLibrary(Sys.java:82)
at org.lwjgl.Sys.(Sys.java:99)
at com.jme3.system.lwjgl.LwjglAbstractDisplay.run(LwjglAbstractDisplay.java:205)
[catch] at java.lang.Thread.run(Thread.java:722)

SceneViewer Window is open but empty.
This is from ~/.jmonkeyplatform/dev/var/log

>Log Session: Thursday, July 7, 2011 10:19:06 AM CEST
>System Info:
Product Version = jMonkeyPlatform Alpha-4
Operating System = Linux version 2.6.38-10-generic running on amd64
Java; VM; Vendor = 1.7.0; Java HotSpot(TM) 64-Bit Server VM 21.0-b17; Oracle Corporation
Runtime = Java(TM) SE Runtime Environment 1.7.0-b147
Java Home = /opt/jdk1.7.0/jre
System Locale; Encoding = de_DE (jmonkeyplatform); UTF-8
Home Directory = /home/christian
Current Directory = /opt/jmonkeyplatform/bin
User Directory = /home/christian/.jmonkeyplatform/dev
Installation = /opt/jmonkeyplatform/jmonkeyplatform
/opt/jmonkeyplatform/extra
/opt/jmonkeyplatform/harness
/opt/jmonkeyplatform/ide
/opt/jmonkeyplatform/java
/opt/jmonkeyplatform/platform
Boot & Ext. Classpath = /opt/jdk1.7.0/jre/lib/resources.jar:/opt/jdk1.7.0/jre/lib/rt.jar:/opt/jdk1.7.0/jre/lib/sunrsasign.jar:/opt/jdk1.7.0/jre/lib/jsse.jar:/opt/jdk1.7.0/jre/lib/jce.jar:/opt/jdk1.7.0/jre/lib/charsets.jar:/opt/jdk1.7.0/jre/classes:/opt/jdk1.7.0/jre/lib/ext/dnsns.jar:/opt/jdk1.7.0/jre/lib/ext/sunpkcs11.jar:/opt/jdk1.7.0/jre/lib/ext/sunec.jar:/opt/jdk1.7.0/jre/lib/ext/sunjce_provider.jar:/opt/jdk1.7.0/jre/lib/ext/localedata.jar:/opt/jdk1.7.0/jre/lib/ext/zipfs.jar
Application Classpath = /opt/jmonkeyplatform/platform/lib/boot.jar:/opt/jmonkeyplatform/platform/lib/org-openide-modules.jar:/opt/jmonkeyplatform/platform/lib/org-openide-util.jar:/opt/jmonkeyplatform/platform/lib/org-openide-util-lookup.jar:/opt/jdk1.7.0/lib/dt.jar:/opt/jdk1.7.0/lib/tools.jar
Startup Classpath = /opt/jmonkeyplatform/platform/core/org-openide-filesystems.jar:/opt/jmonkeyplatform/platform/core/core.jar:/opt/jmonkeyplatform/bin/./../jmonkeyplatform/core/locale/core_jmonkeyplatform.jar
WARNING [org.netbeans.core.modules]: had to upgrade dependencies for module com.jme3.gde.templates.tests: added = [module org.openide.util.lookup > 8.0] removed = []; details: [#170056: Separate module for Lookup API]
WARNING [org.netbeans.core.modules]: had to upgrade dependencies for module com.jme3.gde.textureeditor: added = [module org.openide.util.lookup > 8.0] removed = []; details: [#170056: Separate module for Lookup API]
WARNING [org.netbeans.core.modules]: had to upgrade dependencies for module com.jme3.gde.lwjgl.applet: added = [module org.openide.awt] removed = []; details: [SaveCookie extends Savable. To compile you need to include openide.awt on classpath.]
WARNING [org.netbeans.core.modules]: had to upgrade dependencies for module com.jme3.gde.codepalette: added = [module org.openide.awt] removed = []; details: [SaveCookie extends Savable. To compile you need to include openide.awt on classpath.]
WARNING [org.netbeans.core.modules]: had to upgrade dependencies for module com.jme3.gde.codecheck: added = [module org.netbeans.modules.editor.deprecated.pre65formatting/0 > 1.0] removed = []; details: [The old editor formatting API have been deprecated, see http://wiki.netbeans.org/EditorFormattingAPIUpgrade and update your module.]
WARNING [org.netbeans.core.modules]: had to upgrade dependencies for module com.jme3.gde.templates: added = [module org.openide.util.lookup > 8.0] removed = []; details: [#170056: Separate module for Lookup API]
WARNING [org.netbeans.core.modules]: had to upgrade dependencies for module com.jme3.gde.welcome: added = [module org.openide.awt] removed = []; details: [SaveCookie extends Savable. To compile you need to include openide.awt on classpath.]
WARNING [org.netbeans.core.modules]: had to upgrade dependencies for module com.jme3.gde.gui: added = [module org.openide.awt] removed = []; details: [SaveCookie extends Savable. To compile you need to include openide.awt on classpath.]
Warning - could not install some modules:
com.jme3.gde.codecheck - The module org.netbeans.modules.java.hints was requested in implementation version "4" but only "7" was found.

// EDIT: tested with most recent JMP with all updates installed except those from nightly builds
@glaucomardano: I was unable to find it. Where is it?
@pspeed: yes, looks like an JME issue. should I report in Forum "Troubleshooting | General" or can this topic be moved there?
@glaucomardano: this is no permission problem, since i garanted read and write access to all subfolders of /opt (even before extracting Mythruna)

Hmm. I guess the jME3 Code Checks module have to be upgraded to support the jdk 7.

OpenJDK reports different system names than the normal JDK, thus the system cannot be determined properly and the libraries are not extracted. As stated jME3 requires the default JDK, support for OpdnJDK/Java7 has to be evaluated first.

I did have jME running under OpenJDK. Something else is wrong it seems.

Sorry, I have noticed I have Oracle’s JDK7 (the one from http://jdk7.java.net/download.html , b147 (Release Candidate) ), not OpenJDK7 installed.

OpenJDK definitely fails on OSX, it reports “darwin” instead of “osx”.

Hi guys,



Don’t know if that’s related to Mythruna. When I start JMonkeyPlatform Alpha-4 I can see msg “Opening SceneViewer” and it hangs at 14% + there is red error right of it. Error says:



java.lang.UnsatisfiedLinkError: Can’t load library: /home/moore/.jmonkeyplatform/liblwjgl.so

at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1828)

at java.lang.Runtime.load0(Runtime.java:792)

at java.lang.System.load(System.java:1059)

at org.lwjgl.Sys$1.run(Sys.java:70)

at java.security.AccessController.doPrivileged(Native Method)

at org.lwjgl.Sys.doLoadLibrary(Sys.java:66)

at org.lwjgl.Sys.loadLibrary(Sys.java:82)

at org.lwjgl.Sys.(Sys.java:99)

at com.jme3.system.lwjgl.LwjglAbstractDisplay.run(LwjglAbstractDisplay.java:205)

[catch] at java.lang.Thread.run(Thread.java:722)



So looks like it’s trying to resolve 32 bit version of liblwjgl.so while I have 64 bit (it came with installation few minutes ago):



moore@hermez:~/java/jmonkeyplatform/bin$ ls -l /home/moore/.jmonkeyplatform/

total 852

drwxr-xr-x 2 moore moore 4096 2011-07-11 22:35 assetpacks

drwxr-xr-x 4 moore moore 4096 2011-07-11 22:45 dev

-rw-r–r-- 1 moore moore 508808 2011-07-11 22:45 liblwjgl64.so

-rw-r–r-- 1 moore moore 351827 2011-07-11 22:45 libopenal64.so



I run Ubuntu 10 64bit, Java is O$ JDK7 build 1.7.0-b147

Hope that points to sth…

hermez said:
Don't know if that's related to Mythruna. When I start JMonkeyPlatform Alpha-4 I can see msg "Opening SceneViewer" and it hangs at 14% + there is red error right of it...


This issue is very often, i guess it's a bad graphic card driver or it isn't able to support opengl 2. Try updating it to the lastest graphic card driver.

So it extracted the 64 bit libraries but is trying to load the 32 bit ones? Sounds like the LWJGL and jME3 platform detection is working differently.

My problem is solved by using Java 6 (Sun). So far all looks fine now :slight_smile:

I’m facing nearly the same problem with Oracle JDK6 on Ubuntu 11.04:

The error is this:

Warning - could not install some modules: jME3 Code Checks - The module Java Hints was requested in implementation version “4” but only “8” was found.



java -version’s output:

java version “1.6.0_26”

Java™ SE Runtime Environment (build 1.6.0_26-b03)

Java HotSpot™ 64-Bit Server VM (build 20.1-b02, mixed mode)



Does anybody know, what to do? I’ve downloaded SDK Alpha 4 and updated to stable, NOT to nightly…

Kind regards,

Stefan