Eclipse 4.4 (Luna) 是否需要 Java 1.7
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/24500488/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Does Eclipse 4.4 (Luna) Require Java 1.7
提问by user2554585
I decided to update my eclipse to 4.4 (luna release). When I try to launch it however, I get an error stating that eclipse requires 1.7 or later of java jvm.
我决定将我的 eclipse 更新到 4.4(luna 版本)。但是,当我尝试启动它时,我收到一条错误消息,指出 eclipse 需要 1.7 或更高版本的 java jvm。
Just wanted to see if this is true and if it is possible to get it running with 1.6 (specifically 1.6.0_65)
只是想看看这是否属实,是否可以使用 1.6(特别是 1.6.0_65)运行它
回答by Mathieu Fortin
If there is an explicit message stating that 1.7 or later is required when you run it with 1.6, I expect this to be a strong (ie blocking) minimum requirement. Eclipse Luna (4.4) is the first release requiring 1.7:
如果在使用 1.6 运行它时有明确的消息指出需要 1.7 或更高版本,我希望这是一个强大的(即阻塞)最低要求。Eclipse Luna (4.4) 是第一个需要 1.7 的版本:
http://wiki.eclipse.org/Eclipse/Installation
http://wiki.eclipse.org/Eclipse/Installation
And still, if you still doubt it you can verify for which version it was compiled. For every Eclipse classes run the following command:
而且,如果您仍然怀疑它,您可以验证它是针对哪个版本编译的。对于每个 Eclipse 类,运行以下命令:
javap -verbose EclipseClass.class
Look for Major Version. If value is 51this means it was compiled for java 1.7, so you are out of luck for 1.6. The magic numbers for major versions are :
寻找主要版本。如果值为51,这意味着它是为 Java 1.7 编译的,所以你不走运 1.6。主要版本的幻数是:
J2SE 8 = 52 (0x34 hex),
J2SE 7 = 51 (0x33 hex),
J2SE 6.0 = 50 (0x32 hex),
J2SE 5.0 = 49 (0x31 hex),
JDK 1.4 = 48 (0x30 hex),
JDK 1.3 = 47 (0x2F hex),
JDK 1.2 = 46 (0x2E hex),
JDK 1.1 = 45 (0x2D hex).
and are described here:
并在此处描述:
http://en.wikipedia.org/wiki/Java_class_file#Magic_Number
http://en.wikipedia.org/wiki/Java_class_file#Magic_Number
Thing is, each eclipse bundle have different minimum requirements, so this may not be a good option for a platform as big as Eclipse. Anyway, I mention it because its good to know.
问题是,每个 Eclipse 包都有不同的最低要求,因此对于像 Eclipse 这样大的平台,这可能不是一个好的选择。无论如何,我提到它是因为它很高兴知道。
回答by Leonardo Costa
I also had this problem during the IDE Luna installation. In my case, to solve this problem, I had that change the system variables in win 7. In my computer was the variable that was did referenced the jdk 6... after that I changed it, I could open it again.
我在 IDE Luna 安装过程中也遇到了这个问题。在我的情况下,为了解决这个问题,我在win 7中更改了系统变量。在我的电脑中是引用了jdk 6的变量......之后我更改了它,我可以再次打开它。
This linkhelped me:
这个链接帮助了我:
回答by 345Pilot
It is requesting to install latest JDK. This is the link http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
要求安装最新的JDK。这是链接 http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
回答by shashi
I have installed jdk1.7.0_67and its running successfully.
我已经安装了jdk1.7.0_67并且它运行成功。