I want ot change my jdk versiob from 1.8 to 1.6 but how do have to do this? I read this post How to set or change the default Java (JDK) version on OS X? which is what I think the solution, but when I am goign to 'C:\Program Files\Java' there are only two folder, one jdk1.8.0_65 and jdk1.8.0_73 there is no jdk1.6 so how and where can I get this there?
Asked
Active
Viewed 1,665 times
0
-
you can download old java release from the oracle site: http://www.oracle.com/technetwork/java/javase/downloads/java-archive-downloads-javase6-419409.html – Ji aSH Apr 03 '16 at 10:35
-
Did I need SE or Environemtal? – Number_987 Apr 03 '16 at 10:45
-
you currently have 2 JDKs installed on your system, so you probably need it there (development kit) – Ji aSH Apr 03 '16 at 10:57
-
But now I have to install things is that right thats an exe not an folder. – Number_987 Apr 03 '16 at 11:03
-
choose the jdk 6.45 and yes you have an exe in the list – Ji aSH Apr 03 '16 at 11:17
-
Ok now thers a folder like jdk1.8.0_73 should i do now this in CMD?: – Number_987 Apr 03 '16 at 13:56
-
export JAVA_HOME=`C:\Program Files\Java -v sdk1.6.0_45` ??? – Number_987 Apr 03 '16 at 13:57
1 Answers
0
Install the Java version you want to use.
You can use jenv, it is like a Java environment manager. It is super easy to use and clean
For Mac, follow the steps:
brew install jenv
git clone https://github.com/gcuisinier/jenv.git ~/.jenv
Installation: If you are using bash follow these steps:
$ echo 'export PATH="$HOME/.jenv/bin:$PATH"' >> ~/.bash_profile
echo 'eval "$(jenv init -)"' >> ~/.bash_profile
$ exec $SHELL -l
Add desired versions of JVM to jenv:
jenv add /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home
jenv add /System/Library/Java/JavaVirtualMachines/1.8.0.jdk/Contents/Home
Check the installed versions:
jenv versions
Set the Java version you want to use by:
jenv global oracle64-1.6.0

slal
- 2,657
- 18
- 29