This discussion is archived
1 Reply Latest reply: Apr 6, 2010 8:08 AM by 843802 RSS cannot found the JVM

843802 Newbie
Currently Being Moderated
I am trying to use the new javaplugin ( with my application,
which is based on XULRunner 1.9.1, and thus can run standard netscape/firefox plugins.

First I put the plugin in the "plugins/" directory of my application (lets call it /home/me/foo)
then tried to start the application : the plugin loads!
but a few seconds after, I got this error message:
Didn't find JVM under /home/me/foo/plugins
xulrunner-stub: ../../../../src/plugin/solaris/plugin2/common/JavaVM.c:104: InitializeJVM: Assertion `foundJVM' failed.
I conclude it cannot find any JVM, neither in the system (I have multiple JREs in my system, but only use is used by default, of course)
or in my "/home/me/foo/plugins" (why does it try to load it from there?).

Since I also wish to bundle the JRE with my application,
I put a JRE (I took the Processing project as an example of standalone java application) in a "java" directory, along with my application.

Then, using a shell script (not very nice, I admit it), I tried to set the environment variables before starting the application like :
export JAVA_HOME=`pwd`/java
export PATH=`pwd`/java
# run the app
along with subtle variations (/java/bin, /java/bin/java..), with no success.

In last resort, I also tried to edit the xulrunner app config file (it's in javascript), with something like this :
// of course this would only work on my computer, but I maybe I could use a JS/mozilla platform variable here to get the absolute path
with no more success.

Thanks in advance, I you got any hint to tell the plugin where to find a JVM!

regards, Julian

Edited by: jbilcke on Apr 6, 2010 4:03 PM
  • 1. Re: cannot found the JVM
    843802 Newbie
    Currently Being Moderated
    I think I found an explanation. The library seems to search its dependencies in the parent directories

    so it looks compulsory to create a link
    cd /home/me/foo
    ln -s `pwd`/java/lib/amd64/ plugins/
    I still need to figure out how achieve the same procedure under Windows, though.

    Edited by: jbilcke on Apr 6, 2010 5:07 PM