Board index » jbuilder » Native executable can't find Java

Native executable can't find Java


2007-05-02 01:49:30 AM
jbuilder24
After months, even years, suddenly I get this message trying to run any of
the native executables I have (even old ones).
"Unable to find a supported JDK or JRE version. Version 1.3.1 or higher is
required.
Check your installation and use +javahome to specify the JDK or JRE
location"
There is no problem if +javahome is used to point to the JDK or JRE.
I don't know exactly when it broke because when developing I don't use the
native executables, only when I deploy. I suppose I updated Java, or
something. Since this has happened, I've updated Java to give it a chance
to repair whatever is broken, but still the problem persists.
I've googled many times and find reference to this message but never in
reference to JBuilder native executables. Is there something to fix in the
registry?
John
 
 

Re:Native executable can't find Java

John T. Dow wrote:
Quote
I've googled many times and find reference to this message but never in
reference to JBuilder native executables. Is there something to fix in the
registry?
Take a look at the "CurrentVersion" key in
"HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Runtime Environment" and play
with the values (1.3, 1.4, 1.5) to match what's installed and see if that
works. Also, when you type "java -version" on the command line, what do
you get?
--
Kevin Dean [TeamB]
Dolphin Data Development Ltd.
www.datadevelopment.com/
Please see Borland's newsgroup guidelines at
info.borland.com/newsgroups/guide.html
 

Re:Native executable can't find Java

"Kevin Dean [TeamB]" < XXXX@XXXXX.COM >wrote in
Quote
John T. Dow wrote:

>I've googled many times and find reference to this message but never
>in reference to JBuilder native executables. Is there something to fix
>in the registry?

Take a look at the "CurrentVersion" key in
"HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Runtime Environment" and
play with the values (1.3, 1.4, 1.5) to match what's installed and see
if that works. Also, when you type "java -version" on the command
line, what do you get?

I tried various things in the registry, but still no joy.
java -version displays this:
java version "1.6.0_01"
Java(TM) SE Runtime Environment (build 1.6.0_01-b06)
Java HotSpot(TM) Client VM (build 1.6.0_01-b06, mixed mode, sharing)
In the registry, at "HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Runtime
Environment"
"CurrentVersion" has "1.6"
I tried 1.4, 1.5.
BrowserJavaVersion has 1.6.0_11 and I tried various values there.
[default] had no value, I tried 1.5, 1.5.0_11, 1.6.
This is what appears under "Java Runtime Environment"
1.4.2_13
1.5
1.5.0
1.5.0_10
1.5.0_11
1.6
1.6.0_11
Why is there no 1.4?
Why is there no 1.4.2 and no 1.6.0?
BTW, my JBuilder is 2006 so it's expecting 1.5, but I've tried various
settings when building the native excecutable.
John
 

{smallsort}

Re:Native executable can't find Java

John T. Dow wrote:
Quote
BTW, my JBuilder is 2006 so it's expecting 1.5, but I've tried various
settings when building the native excecutable.
Try running the raw JAR file:
java -jar <jarfilename>
What happens then?
--
Kevin Dean [TeamB]
Dolphin Data Development Ltd.
www.datadevelopment.com/
Please see Borland's newsgroup guidelines at
info.borland.com/newsgroups/guide.html
 

Re:Native executable can't find Java

"Kevin Dean [TeamB]" < XXXX@XXXXX.COM >wrote in
Quote
John T. Dow wrote:

>BTW, my JBuilder is 2006 so it's expecting 1.5, but I've tried various
>settings when building the native excecutable.

Try running the raw JAR file:

java -jar <jarfilename>

What happens then?

"Invalid or corrupt jarfile <fullpath of jar file>"
 

Re:Native executable can't find Java

John T. Dow wrote:
Quote
"Invalid or corrupt jarfile <fullpath of jar file>"
The problem then is your Java installation. At this point, I would
recommend uninstalling all versions of Java and reinstalling them.
--
Kevin Dean [TeamB]
Dolphin Data Development Ltd.
www.datadevelopment.com/
Please see Borland's newsgroup guidelines at
info.borland.com/newsgroups/guide.html
 

Re:Native executable can't find Java

"Kevin Dean [TeamB]" < XXXX@XXXXX.COM >wrote in
Quote
John T. Dow wrote:

>"Invalid or corrupt jarfile <fullpath of jar file>"

The problem then is your Java installation. At this point, I would
recommend uninstalling all versions of Java and reinstalling them.

Before I do that, remember that I can run Java without problem.
The only problem is that native executables, whether they've been around
for months or have just been built, give this error message. However,
they all run if I specify the +javahome parameter and provide the proper
path.
I can run JBuilder2006 and JBuilder2007. DBPilot runs without doing
anything different.
Also, what do you mean by "uninstalling Java". Each JBuilder has its own
JDK in addition to the several updates I've installed independently. I
don't see any trace of those JDK's in the registry, so what is meant by
ininstalling those 2 JDK's? Or can they stay.
I can certainly uninstall the JDK's and JRE's I've installed from
java.com. Would that be sufficient?
After uninstalling, I presume I should scan the registry for any
lingering reference to Java. Currently all my versions of Java are under
C:\Program Files\Java but in the past I had some in another location.
Is this a Windows registry problem? A Windows environment variable? Not
Windows related at all?
John
 

Re:Native executable can't find Java

"John T. Dow" < XXXX@XXXXX.COM >wrote in
Quote
"Kevin Dean [TeamB]" < XXXX@XXXXX.COM >wrote in
news:xn0f5qjaugdqhg000-kdean@www.teamb.com:

>John T. Dow wrote:
>
>>"Invalid or corrupt jarfile <fullpath of jar file>"
>
>The problem then is your Java installation. At this point, I would
>recommend uninstalling all versions of Java and reinstalling them.
>
The problem has been fixed. I began removing java versions, checking
after each to see if a native executable would run.
Success after removing the first jdk!
Strangely, jdk 5.0 update 10 made no registry changes when it was
removed. Also, its directory under c:\program files\java was not removed.
I had to delete it manually.
After jdk 5.0 update 10 was removed the native executable problem
vanished.
I also removed jdk 5.0 update 11. It made registry changes and removed
the files.
I removed jre 5.0 update 10. It too made registry changes and removed its
files.
The native executable problem has not returned.
So there was something bogus about jdk 5.0 update 10.
John