Eclipse Spring Boot 构建路径包含重复条目
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/36507516/
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
Eclipse Spring Boot Build Path Contains Duplicate Entry
提问by skmansfield
I have been using Eclipse Luna and sprint boot for quite a while. Just today, when I created a new project I am getting the following build error,
我使用 Eclipse Luna 和 sprint boot 已经有一段时间了。就在今天,当我创建一个新项目时,我收到以下构建错误,
Build path contains duplicate entry: 'org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.8' for project 'TomcatHttpDemo'
I am not sure if this is related to this problem but I tried
我不确定这是否与这个问题有关,但我试过了
properties> Java Build Path > Libraries
and found that 'JRE System Library[JavaSE-1.8] was listed twice. I deleted one of them and then cleaned and re-built the project. I got a bunch of new errors. These errors were all related to deleting the JRE system library. I even restarted Eclipse several times to clear out any lingering errors.
并发现'JRE System Library[JavaSE-1.8]被列出了两次。我删除了其中之一,然后清理并重新构建了该项目。我遇到了一堆新错误。这些错误都与删除JRE系统库有关。我什至多次重新启动 Eclipse 以清除任何挥之不去的错误。
I was running Luna 4.4 and upgraded to Mars 4.5 but the problem continues to persist. I can build my old projects with no problems at all. Using Luna or Mars the old projects build and execute properly. Any time I try to create a new project I get the duplicate entry error. Any help would be appreciated.
我正在运行 Luna 4.4 并升级到 Mars 4.5,但问题仍然存在。我可以毫无问题地构建我的旧项目。使用 Luna 或 Mars 可以正确构建和执行旧项目。每当我尝试创建一个新项目时,都会出现重复输入错误。任何帮助,将不胜感激。
回答by Kamel Mili
if i understand your problem it's library issue with your project so
如果我理解你的问题,那就是你的项目的库问题
1.Select your project then go to Properties
1.选择您的项目,然后转到属性
2.Java build Path
2.Java构建路径
3.in the Top select Libraires
3.在顶部选择Libraires
4.add a JRE System Library
4.添加JRE系统库
5.check the Execution Environment Then Click to Environments
5.勾选执行环境然后点击Environments
6.On the left click to Installed JREs
6.在左边点击Installed JREs
7.Then Click To add , Standard VM
7.然后点击添加,标准VM
8.click To directory Then go to /yourprograms/java/jdk 1.8
8.单击到目录然后转到/yourprograms/java/jdk 1.8
9.then Click finish after this check what you just added and click ok
9.然后在此检查您刚刚添加的内容后单击完成并单击确定
10.when everything is closed update your maven Project
10.当一切都关闭时更新你的maven项目
i hope it helps you
我希望它能帮助你