Go Down

Topic: Java 6 Launch Error on Mac (Read 2128 times) previous topic - next topic

darcysays

I'm not sure if anyone has come across this yet but Arduino 11 will not launch when Java 6 is the default JVM on Mac.
The error is as follows:

Cannot launch Java application
Uncaught exception in main method: java.lang.UnsatisfiedLinkError: /Applications/arduino-0011/Arduino 11.app/Contents/Resources/Java/librxtxSerial.jnilib:


Switching to Java 5 makes everything ok. From what I have read this is because Java 6 is 64bit only and requires all native libraries to also be 64bit.

To avoid this error in future releases it might be an idea to change the Info.plist JVMVersion property from 1.4+ to 1.4*
That way rather than the latest version being used, the latest version of 1.4.x is used.

mellis

Thanks for the report and the suggested fix.  I'll put it into the next version.

mellis

Actually, does anyone know how far back in Mac OS X there's support for Java 5.  Is it available on 10.3.9?  That way I can change the property to 1.5, instead of 1.4.

darcysays

Quote
Actually, does anyone know how far back in Mac OS X there's support for Java 5.  Is it available on 10.3.9?  That way I can change the property to 1.5, instead of 1.4.

Just from a quick search it looks like 1.5 is not officially supported in Panther (10.3). Not sure there is any great advantage to running it on 1.5 is there? Although I note Processing is now 1.5...

The other thing you can do is use retroweaver to turn your fancy code to 1.4 compliant code: http://retroweaver.sourceforge.net/

rasputnik

Does anyone know of a way to tell Arduino.app to run under a particular version of Java, while keeping 1.6 as the default JDK?

Got a few other Java bits that would really benefit from a 1.6 default.

rasputnik

Ah, editing JVMVersion in info.plist does the trick. Cool.

snowmaninthesun

color me clueless, but where is this info.plist? there are about 100 of them on my mac...

rasputnik

Actually there's a much simpler way;

just right-click Arduino.app -> Get Info

then check the "Open in 32 bit mode" option under 'General'.

snowmaninthesun

thanks, i figured this out about five minutes after posting, now if only I could get the IDE to work... http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1248563924/0

tege

Hello, after I clicked the "Open in 32 Bit Mode" checkbox I get a new error-message: "Cannot launch Java application Uncaught exception in main method: java.lang.NumberFormatException: null"

Any idea what could be the problem?
Thanks!

mellis

tege: what version of Arduino are you running?

tege

I tried all versions from 12 to 17. 17 is working but makes some problems communicating with max/mso under version 17?

mellis

You might need to delete your Arduino preferences file (you can find the location in the preferences dialog).  Then run Arduino 0016 (not 0017) to recreate the preferences file.  (If you run Arduino 0017 first, Arduino 0016 will have trouble with the preferences file that gets created.)

tege


robyn farah

Quote
You might need to delete your Arduino preferences file (you can find the location in the preferences dialog).  Then run Arduino 0016 (not 0017) to recreate the preferences file.


hey i am stuck on the solution above.
I am  confused where "the arduino preferences" is. if it is the folder within "show package content", it tried deleting that Arduino 16 wouldn't even open.

thanks,
robz

Go Up