This Java instance does not support a 32-bit JVM.

This is where you talk about the NXJ software itself, installation issues, and programming talk.

Moderators: 99jonathan, roger, imaqine

This Java instance does not support a 32-bit JVM.

Postby Quizmaster » Mon Feb 10, 2014 1:58 am

Hello everyone, This is my first time trying to install leJOS, I am on a MacBook Air. I set up all the environment variables and I already have the 64-bit JDK 1.8.0 installed. Every time I try to run nxjflashg I get the following error: Nicholass-MacBook-Air:bin nicholasshoemake$ ./nxjflashg
Error: This Java instance does not support a 32-bit JVM.
Please install the desired version.

How can I correct this?
Quizmaster
New User
 
Posts: 5
Joined: Mon Feb 10, 2014 1:43 am

Re: This Java instance does not support a 32-bit JVM.

Postby skoehler » Mon Feb 10, 2014 8:39 am

Install Java 6 from Apple. Newer versions don't support 32Bit Java anymore.
skoehler
leJOS Team Member
 
Posts: 1418
Joined: Thu Oct 30, 2008 4:54 pm

Re: This Java instance does not support a 32-bit JVM.

Postby Quizmaster » Tue Feb 11, 2014 1:49 am

Ok, so how do I downgrade to Java 6? Every tutorial I find on how to uninstall Java 8 tells me I need to delete the /Library/Java/JavaVirtualMachines directory, but I can't find that folder, even when I use the Go To Folder function in Finder, so how else can I uninstall Java 8?
Quizmaster
New User
 
Posts: 5
Joined: Mon Feb 10, 2014 1:43 am

Re: This Java instance does not support a 32-bit JVM.

Postby Quizmaster » Wed Feb 12, 2014 2:07 am

Ok, so I managed to downgrade to Java 6, and I even ran nxjflashg without any issues, but today when I tried to run nxjflashg again today, I got a new error
Code: Select all
Nicholass-MacBook-Air:bin nicholasshoemake$ ./nxjflashg
The variable LEJOS_NXT_JAVA_HOME does not point to the root directory
of a JRE or JDK. The following file does not exist or
is not executable:
  "/usr/libexec/java_home/bin/java"
./nxjflashg: line 78: /usr/libexec/java_home/bin/javac: Not a directory

The weird thing is, I didn't even set that directory path, I set the environment variables in /.profile exactly as instructed on the leJOS install gude. So, how can I fix this?
Quizmaster
New User
 
Posts: 5
Joined: Mon Feb 10, 2014 1:43 am

Re: This Java instance does not support a 32-bit JVM.

Postby skoehler » Wed Feb 12, 2014 8:26 am

Does the directory /usr/libexec/java_home still exist?
If so, is there a bin/java executable in it?

I'm not quite sure why you get an error about javac in the end, but let's fix the message about /usr/libexec/java_home/bin/java first.
The messages basically tell you, that nxjflashg cant find a JDK/JRE at the path you specified.
skoehler
leJOS Team Member
 
Posts: 1418
Joined: Thu Oct 30, 2008 4:54 pm

Re: This Java instance does not support a 32-bit JVM.

Postby Quizmaster » Wed Feb 12, 2014 10:57 am

It's strange, there is no file or directory inside java_home, if I try to cd into it, I get this
Code: Select all
Nicholass-MacBook-Air:libexec nicholasshoemake$ cd /usr/libexec/java_home
-bash: cd: /usr/libexec/java_home: Not a directory
Nicholass-MacBook-Air:libexec nicholasshoemake$ ./java_home
/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home

Why do think it is that I'm getting that pathname, what should I do?
Quizmaster
New User
 
Posts: 5
Joined: Mon Feb 10, 2014 1:43 am

Re: This Java instance does not support a 32-bit JVM.

Postby skoehler » Wed Feb 12, 2014 10:58 am

Quizmaster wrote:It's strange, there is no file or directory inside java_home, if I try to cd into it, I get this
Code: Select all
Nicholass-MacBook-Air:libexec nicholasshoemake$ cd /usr/libexec/java_home
-bash: cd: /usr/libexec/java_home: Not a directory
Nicholass-MacBook-Air:libexec nicholasshoemake$ ./java_home
/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home

Why do think it is that I'm getting that pathname, what should I do?


That's because java_home is it self an executable, not a directory.
Set LEJOS_NXT_JAVA_HOME to /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home and everything should work.
skoehler
leJOS Team Member
 
Posts: 1418
Joined: Thu Oct 30, 2008 4:54 pm


Return to NXJ Software

Who is online

Users browsing this forum: No registered users and 3 guests

more stuff