且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

Eclipse:指定的JRE安装不存在

更新时间:2022-10-19 13:00:06

我也有同样的问题。这是我如何修复它。


  1. 打开Eclipse。

  2. 转到首选项

  3. 点击添加

  4. 应该弹出一个窗口:


  1. 选择标准VM

  2. 选择目录

  3. 使用此路径:库/ Java / JavaVirtualMachines / jdk1.7.0_45.jdk / Contents / Home /

  4. 点击打开

  5. 然后完成

  6. 右键单击您的项目,然后单击属性

  7. 选择 Java构建路径然后单击添加库

  8. 选择 JRE系统库


  1. 点击环境,然后选择 jdk1.7.0_45

  2. 完成

这是你应该看到的,如果你做的正确




I used to have Eclipse configured well and work fine before. But I just uninstalled it and installed Eclipse Juno again on my Mac OS 10.10 today. But I kept getting this error: "The specified JRE does not exist."

I know it's a pretty simple and commonly seen problem, I just needed to install JRE and/or JDK into this clean Eclipse, however things didn't get work out.

And I've searched extensively on Stack Overflow: The posts I've looked at including: How to install JRE 1.7 on Mac OS X and use it with Eclipse? I followed exactly what the accepted answer said, but after having downloaded the JDK from http://www.oracle.com/technetwork/java/javase/downloads/index.html and installed it, I was going to add it to Eclipse via Preferences -> Java -> Installed JREs, however, I didn't see it as expected, the following is a screenshot of what I saw when I went to Preferences -> Java -> Installed JREs

But the screenshot just says the installed JREs list is BLANK, I couldn't add any JRE into my Eclipse.

Help please?

Also, I've tried other things that people have suggested: Properties -> Java Build Path what I see here is: JRE System Library OSGi/Minimum-1.2 with a red crossing sign in front of it (indicating something wrong with it?) So, I'm also blocked with this approach.

I had the same problem. This is how I fixed it.

  1. Open Eclipse.
  2. Go to Preferences.
  3. Click Add
  4. A Window should popup with this:

  1. Select Standard VM.
  2. Select Directory
  3. Use this path: Library/Java/JavaVirtualMachines/jdk1.7.0_45.jdk/Contents/Home/
  4. Click Open
  5. Then Finish
  6. Right click your Project then click Properties
  7. Select Java Build Path then click Add Library
  8. Select JRE System Library

  1. Click Environments and select the jdk1.7.0_45
  2. Finish

This is what you should see if you did it right: