Target is not a JDK root. System library was not found. Eclipse Oxygen 4.7 + Java9 error

半城伤御伤魂 提交于 2019-11-30 01:05:00

问题


I'm trying to test JDK9 (jdk-9-ea+147 version) with Eclipse Oxygen IDE.

I've installed jdk along with jre. From Eclipse Market Place I've installed Java9 Beta extension:

The problem is, when I'm trying to add new installed jre from Eclipse I get following error:

Interesting thing is that this error doesn't occur with installations of previous JDK versions:

Does anyone encounter simillar problem with Eclipse Oxygen? Any feedback is appreciated.


回答1:


I've just successfully tested JDK9 with Eclipse Oxygen IDE following the approach you detailed.

Here are the details of my installation (under Windows 10):

  • I downloaded and installed Java jdk-9+181 from http://jdk.java.net/9/

  • I downloaded and installed Eclipse Oxygen from https://www.eclipse.org/downloads/download.php?file=/oomph/epp/oxygen/R/eclipse-inst-win64.exe

  • I started Eclipse and attempted to add JRE9 (Windows -> Preferences -> Java -> Installed JREs -> Add...)

  • I got the error reported in the OP ("Target is not a JDK root...").

  • I then installed Java 9 Support (BETA) for Oxygen as detailed here: https://marketplace.eclipse.org/content/java-9-support-beta-oxygen

  • I restarted Eclipse and tried to add JRE 9 again. This time it worked fine:

  • Also, see https://wiki.eclipse.org/Java9/Examples for further details.



回答2:


This looks like Eclipse bug 494481.

Unfortunately there is currently no fix or workaround listed for the bug.




回答3:


You should use Standard VM not standard 1.1x VM best regards! se pic




回答4:


Oxygen does not come with java9 support. You need to install the eclipse Java9 support patch from the market place https://marketplace.eclipse.org/content/java-9-support-beta-oxygen to be able to use Java9 or you can update from "Help" menu bar.

Ref - https://bugs.eclipse.org/bugs/show_bug.cgi?id=509704




回答5:


set the path to:: /Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home



来源:https://stackoverflow.com/questions/41029647/target-is-not-a-jdk-root-system-library-was-not-found-eclipse-oxygen-4-7-jav

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!