Home > Uncategorized > How to easily switch the default Java version on Mac OSX

How to easily switch the default Java version on Mac OSX

After installing Netbeans and Java7 for some JavaFX tinkering several of my other apps stopped working.

A lot of the solutions I found online involve writing scripts or changing startup scripts for specific programs, but I found none of them easy or maintainable enough. I ended up altering the symbolic link named “Current” in /System/Library/Frameworks/JavaVM.framework/Versions

A link called CurrentJDK in the same directory still pointed at a 1.6 version, so I simply changed the Current link to point to the CurrentJDK link. That way I can simply change it back when I want 1.7 to be the default.

sudo ln -s CurrentJDK/ Current

Advertisements
Categories: Uncategorized
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: