1

This question already has an answer here:

i have recently bought my first rMBK and i really love it.

i would like to start programming in java and have therefore tried installing two IDEs, eclipse and NetBeans. i have also made sure to download the newest java version from oracle (7u45). my problem is that the java provide from oracle is not used in eclipse and i cannot even install NetBeans - it stops installation and ask me to install java 7, even though it should already be installed.

i am running OS 10.9.1. typing "java -version" gives the output:

java version "1.6.0_65"

Java(TM) SE Runtime Environment (build 1.6.0_65-b14-462-11M4609)

Java HotSpot(TM) 64-Bit Server VM (build 20.65-b04-462, mixed mode)

and "which java" gives "/usr/bin/java".

under "/Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home/bin/java" i can find the java version from oracle - but it is not the version used for anything except browser plugins.

typing "/Library/Internet\ Plug-Ins/JavaAppletPlugin.plugin/Contents/Home/bin/java -version"

java version "1.7.0_45"

Java(TM) SE Runtime Environment (build 1.7.0_45-b18)

Java HotSpot(TM) 64-Bit Server VM (build 24.45-b08, mixed mode)

i guess i can change the config file for eclipse, so that it uses the java in the strange "internet plugin" folder but for simplicity i would prefer if i could put Oracles java in my /usr/bin/ folder so all programs automatically uses the newest release. it would also allow me to install all the programs/aps that requires the newest java.

renaming apples java to "java_backup" and copying oracles java to the usr/bin folder does not work. would it make sense to update my path variable to include the strange "internet plugin"? i have previously made a mess by adding strange folders to my path environment on linux so i am a bit cautious about that.

marked as duplicate by user151019, Matthieu Riegler, bmike Dec 21 '13 at 1:17

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • If you are programming you want the JDK and if you install the JDK Oracle will make it available from /usr/bin/java – user151019 Dec 21 '13 at 0:13
  • Cheers! i guess i should have know, but must have missed the mentioning of the JDK in the tutorials i follow. my bad. following your link solved my problem. should i delete my post since it is sort of a duplicate? – DonMP Dec 21 '13 at 0:21

Browse other questions tagged .