Question

I've been having problems getting eclipse working on my 2010 Mavericks Macbook. The original problem that I was having (not the current problem) was the "You have to have Java SE 6 installed" message. I tried following the solution in this thread: Eclipse Kepler for OS X Mavericks request Java SE 6 and found that the jdk1.7.0_51.jdk file didn't exist. Before posting here I also tried setting the JAVA_HOME as suggested on another thread using this command:

export JAVA_HOME /Library/Internet Plug-Ins/JavaAppletPlugin.plugin/Contents/Home

And found that interestingly enough, it changed the startup problem - instead of showing the SE 6 error, it wouldn't even try to open (the application icon wouldn't even briefly show on the dock) and it would lag a little bit when an open command (double-click, cmd-down arrow, opening from spotlight, etc) was used.

I decided to make a thread (Eclipse does not recognize Java 7 on Mavericks, can't find jdk.1.7.0_51 to fix issue) where greg-449 pointed out that I downloaded the wrong file (runtime environment instead of development kit). Sure enought the jdk1.7.0_51.jdk file appeared, and I followed the instructions in the first thread I linked to above.

But I'm still getting the issue where Eclipse seems like it won't even attempt to open. I tried setting JAVA_HOME to what appeared to be the actual "home" directory (/Library/Java/JavaVirtualMachines/jdk1.7.0_51.jdk/Contents/Home) but I'm still getting the same issue.

Anyone know how to fix this? Did I screw up badly somewhere along the way? Any answer is appreciated.

Was it helpful?

Solution

You can set path to jdk in eclipse.ini file as written here. http://wiki.eclipse.org/Eclipse.ini. Version for MacOs exists

edited. looks like a solution http://burrsutter.blogspot.ru/2013/12/eclipse-does-not-contain.html

OTHER TIPS

Eclipse ignores the JAVA_HOME variable, so that has no effect. See this.

  • It looks for a java in eclipse/jre
  • Is there one specified as an argument? eclipse -vm c:\...
  • Is there one specified in eclipse.ini file? -vm c:/jre/bin/javaw.exe

First of all, Eclipse JDT (Java Development Tools) includes its own ECJ (Eclipse Java compiler) so it does not need a JDK and runs perfectly well with a JRE. The only reason to download JDK is to get source code for the java classpath.

Secondly, the JAVA_HOME environment variable is not checked (1) if you have a path to JRE in eclipse.ini or (2) if you have a symbolic link "jre" next to eclipse executable as well as in some other cases. So, if I were you I'd try modifying these variables. Furthermore, it may be a good idea to try starting Eclipse from command line to see if there is any error message being printed.

Finally, I've never used Mac so it's difficult for me to guess, but if the problem is related to JRE, I suggest to try setting -vm to a different value. Normally, a path to JRE directory should be enough, but you can try as well to give a path to the actual libjvm.so (e.g. something like lib/amd64/server/libjvm.so) or to java executable (bin/java).

Oh, another thing to check is that there is a sane -Xmx argument to JVM somewhere in eclipse.ini. You can try by adding -Xmx1024m on the line following -vmargs.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top