

I had to switch between 1.6_XX and 1.7_XX so wrote a litte script for that. Install an other Java version, that you need.

There is information at that discusses using homebrew to install Java and it mentions Java6 (the post is dated Dec 2017).

dmg, I'm sure it installs in the correct location and will be visible with java_home. I'm sure you could search a bit more though as I understand it, once they (Oracle) have discontinued a version, they no longer maintain it since it could be a security risk. I can get to but any earlier version is a 404 (11 is the latest). Then simply in your ~/.bashrc or ~/.bash_profile: $ export JAVA_HOME=$(/usr/libexec/java_home -v 1.7.0_80)Īs for getting version 1.6 (or nearly any prev version) I think that as of this date (Nov 2018) you will be out of luck. To see which versions you have installed use: /usr/libexec/java_home -Vįor example shows this for me: 15:04 $ /usr/libexec/java_home -Vġ0.0.1, x86_64: "Java SE 10.0.1" /Library/Java/JavaVirtualMachines/jdk-10.0.1.jdk/Contents/Homeġ.7.0_80, x86_64: "Java SE 7" /Library/Java/JavaVirtualMachines/jdk1.7.0_80.jdk/Contents/Home
