Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm testing Snow Leopard for our IT team in preparation for it's actual launch. I'm currently running seed 10A394, which comes with Java JDK 1.6.

I found one Java desktop application that no longer runs under Snow Leopard, the app won't even start. The vendor is recommending that I downgrade to JDK 1.5.

The problem is that every Java for Mac package that I've been able to find first checks that it's about to be installed on the version of Mac OS that Apple had in mind when the package was created. This page is a good example, there are two different packages but each explicitly checks for MacOS 10.4 or 10.5 before installing, so neither works on Snow Leopard.

Once I get it installed, I know how to change the order so that the lower version is preferred -- I just can't find any packages that will install.

share|improve this question

3 Answers 3

up vote 3 down vote accepted

MacOS comes with versions of Java going back as far as 1.3. See /System/Library/Frameworks/JavaVM.framework/Versions. The only time you need to install from a package is when the latest Java is newer than your OS version and you can't use the Software Update for some reason.

The vendor of your application should really take responsibility, but you can probably fix the problem by editing the .plist of the app. Right click the application and choose Show Package Contents then open the Info.plist file with a text editor. You'll see a Java dictionary in that file and a key JVMVersion. Change the value to 1.5* (1.4+ would mean anything after version 1.4, 1.6* would be any version of 1.6.) That will get your app running in Java 1.5.

However this may not be the whole story. Along side the Info.plist, you'll find MacOS/JavaApplicationStub. This is the actual MacOS X Binary that launches the JVM. The developer may have shipped their app with an old version of this file that is not compatible with your OS. You'll have an up to date copy of this file on your machine already at /System/Library/Frameworks/JavaVM.framework/Versions/Current/Resources/MacOS/JavaApplicationStub. Replace the application's version with this one.

The application might still not run because (for example) it can't load 32-bit native libraries after being launched as 64-bit. In that case you can strip out the 64-bit portion of the Stub with the lipo command: lipo -remove x86_64 JavaApplicationStub -output JavaApplicationStub

Hope this works. And if it does, be sure to let the developer of the app know of course.

share|improve this answer

If you have multiple versions of java installed you can change the order of preference in Applications/Utilities/Java.

Install the version you need and set it to the top preferred version.

share|improve this answer
    
Right, but I need to get a second version of Java installed before I can select it from that tool, and that's where I'm falling down. Any thoughts on how to get an alternate version installed? –  Jeremy Wadhams Jul 6 '09 at 18:41

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.