I’ve to use OpenJML and that requires Java JDK7. I’ve installed JDK7 so far following the instructions from this link: http://formalmethods.insttech.washington.edu/software/openjml.html
After the installation my Eclipse project didn’t show any errors any more because it found JavaSE7 now.
But when I type java -version in Terminal there is still …
java version "1.6.0_29"
… displayed there. What can I do to use 1.7 in the shell as well?
The new JDK will be installed into:
/Library/Java/JavaVirtualMachinesOn my Mac with the developer preview installed you can run:
You can select the current system JVM via the Java Preferences application (use spotlight to find it).
Alternatively you can use
/usr/libexec/java_home --version 1.7to find the correctJAVA_HOMEvalue for the requested JDK.