Trying to install eclipse
and I get an error
Version 1.6.0_65 of the JVM is not suitable for this product.
Java -version from command line says
Java(TM) SE Runtime Environment (build 1.6.0_65-b14-466.1-11M4716)
Java HotSpot(TM) 64-Bit Server VM (build 20.65-b04-466.1, mixed mode)
How can I change that to a compatible version? I did google this and cruise this site for answers with the suggested questions when writing this but was not able to find something that solved it. I found a few answers telling you to do this (with my current installed version in)
export JAVA_HOME=`/usr/libexec/java_home -v 1.8.*'
When I run the EXPORT command it just takes me to a command line and from there I have no idea what to do.
I did download the 64-bit version.
Seems like it should be an easy thing to do....
If you're looking to resolve this without changing eclipse. ini file, just reinstall eclipse IDE. It can be the same version or newer one. I have reinstalled the same version and it's worked without issues, no needing of changing eclipse.
Eclipse 4.23 (2022-03) It is the supported release. A Java 11 or newer JRE/JDK is required, LTS release are preferred to run all Eclipse 2022-03 packages based on Eclipse 4.23, with certain packages choosing to provide one by default.
Right click Eclipse
and click Show Package Contents
And open Contents\info.plist
in a texteditor
Then search for <key>Eclipse</key>
and immediately after the <key>Eclipse</key>
you will have <array>
tag, add the following inside <array>
tag.
<string>-vm</string>
<string>YOUR_JAVA_HOME/jre/lib/server/libjvm.dylib</string>
Replace YOUR_JAVA_HOME
with the output of /usr/libexec/java_home -v 1.8.*
. Then eclipse will run on that particular JVM.
For example my Info.plist has the following
<key>Eclipse</key>
<array>
<string>-vm</string>
<string>/Library/Java/JavaVirtualMachines/jdk1.8.0_51.jdk/Contents/Home/jre/lib/server/libjvm.dylib</string>
<string>-keyring</string>
<string>~/.eclipse_keyring</string>
<string>-showlocation</string>
</array>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With