在 Windows 7 64 位上安装 eclipse 时出错

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/12997148/
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

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-19 19:14:22  来源:igfitidea点击:

Errors installing eclipse on Windows 7 64bit

eclipseinstallation

提问by froadie

I'm trying to install Eclipse on my Windows 7 laptop.

我正在尝试在我的 Windows 7 笔记本电脑上安装 Eclipse。

When trying to run eclipse.exe I got the following error:

尝试运行 eclipse.exe 时出现以下错误:

A Java Runtime Environment (JRE) or Java Development Kit (JDK) must be available in order to run Eclipse. No Java virtual machine was found after searching the following locations: C:\ProgramFiles (x86)\Eclipse\eclipse\jre\bin\javaw.exe javaw.exe in your current PATH

Java 运行时环境 (JRE) 或 Java 开发工具包 (JDK) 必须可用才能运行 Eclipse。搜索以下位置后未找到 Java 虚拟机:C:\ProgramFiles (x86)\Eclipse\eclipse\jre\bin\javaw.exe javaw.exe in your current PATH

I know that I have a JRE on my computer, so I modified the eclipse.ini file to point it to the correct location:

我知道我的计算机上有一个 JRE,因此我修改了 eclipse.ini 文件以将其指向正确的位置:

-vm
C:\Program Files (x86)\Java\jre6\bin

Now when I run the eclipse exe file it starts to run, but then I get the following error:

现在,当我运行 eclipse exe 文件时,它开始运行,但随后出现以下错误:

Failed to load the JNI shared library "C:\Program Files (x86)\Java\jre6\bin\client\jvm.dll"

无法加载 JNI 共享库“C:\Program Files (x86)\Java\jre6\bin\client\jvm.dll”

I tried adding the javaw.exe file to the path in eclipse.ini:

我尝试将 javaw.exe 文件添加到 eclipse.ini 的路径中:

-vm
C:\Program Files (x86)\Java\jre6\bin\javaw.exe

But then I get a long detailed error message:

但是后来我收到了一条很长的详细错误消息:

---------------------------
Eclipse
---------------------------
Java was started but returned exit code=13
C:\Program Files (x86)\Java\jre6\bin\javaw.exe
-Xms40m
-Xmx512m
-XX:MaxPermSize=256m
-jar C:\Program Files (x86)\Eclipse\eclipse\plugins/org.eclipse.equinox.launcher_1.3.0.v20120522-1813.jar
-os win32
-ws win32
-arch x86_64
-showsplash C:\Program Files (x86)\Eclipse\eclipse\plugins\org.eclipse.platform_4.2.1.v201209141800\splash.bmp
-launcher C:\Program Files (x86)\Eclipse\eclipse\eclipse.exe
-name Eclipse
--launcher.library C:\Program Files (x86)\Eclipse\eclipse\plugins/org.eclipse.equinox.launcher.win32.win32.x86_64_1.1.200.v20120522-1813\eclipse_1503.dll
-startup C:\Program Files (x86)\Eclipse\eclipse\plugins/org.eclipse.equinox.launcher_1.3.0.v20120522-1813.jar
--launcher.overrideVmargs
-exitdata 1e38_58
-vm C:\Program Files (x86)\Java\jre6\bin\javaw.exe
-vmargs
-Xms40m
-Xmx512m
-XX:MaxPermSize=256m
-jar C:\Program Files (x86)\Eclipse\eclipse\plugins/org.eclipse.equinox.launcher_1.3.0.v20120522-1813.jar 
---------------------------
OK   
---------------------------

Any ideas of how I can get Eclipse to run?

关于如何让 Eclipse 运行的任何想法?

回答by aleroot

Make sure that you're version of Eclipse and JDK match, either both 64-bit or both 32-bit, then set the path of the JRE in the .ini file .

确保您的 Eclipse 和 JDK 版本匹配,无论是 64 位还是 32 位,然后在 .ini 文件中设置 JRE 的路径。

I think that the problem in your case is that you have a 64bit version of eclipse and you are trying to run it with a 32bit JVM ...

我认为你的问题是你有一个 64 位版本的 eclipse 并且你试图用 32 位 JVM 运行它......

回答by janjonas

Make sure you've installed a 64-Bit version of Java and your eclipse.ini points to this Java version.

确保您已安装 64 位版本的 Java,并且您的 eclipse.ini 指向此 Java 版本。

See http://blog.janjonas.net/2013-02-09/eclipse-windows-64bit-java-runtime-environment-java-development-kit-must-be-available-java-returned-exit-code-13for more details.

http://blog.janjonas.net/2013-02-09/eclipse-windows-64bit-java-runtime-environment-java-development-kit-must-be-available-java-returned-exit-code-13更多细节。

回答by Mani Kandan

for this problem you have to install first latest version java and install eclipse workbench :https://www.eclipse.org/downloads/download.php?file=/oomph/epp/oxygen/R2/eclipse-inst-win64.exe&mirror_id=105. select eclipse ide and start install

对于这个问题,你必须安装第一个最新版本的 java 并安装 eclipse 工作台:https: //www.eclipse.org/downloads/download.php?file =/oomph/ epp/oxygen/ R2/eclipse-inst-win64.exe &mirror_id =105。选择eclipse ide并开始安装

回答by rlegendi

This is a common issue, check i)which version of Java do you have (java -version), and ii)also check you are using x64 JRE with an installation of x64 Eclipse (or x86 from both of them).

这是一个常见问题,请检查i)您拥有哪个版本的 Java ( java -version),以及ii)还要检查您使用的是 x64 JRE 并安装了 x64 Eclipse(或两者的 x86)。

Also, specifying the -vmis important to be well-formed: you should specify the full path for the javaw.exefile. For the details, refer to the documentation of the eclipse.ini file.

此外,指定-vm格式对于格式正确很重要:您应该指定javaw.exe文件的完整路径。有关详细信息,请参阅eclipse.ini 文件文档