Eclipse 插件依赖关系消失
我正在 Eclipse 中开发 OSGi,并且项目的插件依赖项消失了。
我已经检查了 .classpath,看起来不错:
<classpath>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="src" path="src"/>
<classpathentry kind="output" path="bin"/>
</classpath>
我尝试使用 -clean 启动 eclipse,并且尝试创建一个新的工作区并将项目导入到该工作区中 - 两者都没有运气。
有什么想法吗? :)
I am developing OSGi in Eclipse, and the plugin dependices has vanished for a project.
I have checked .classpath, and it seems fine:
<classpath>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="src" path="src"/>
<classpathentry kind="output" path="bin"/>
</classpath>
I have tried starting eclipse with -clean and I have tried creating a new workspace and importing the projects into that workspace - no luck with either.
Any ideas? :)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(4)
一些奇怪的日食错误。重新编辑manifest文件,依赖重新出现,项目编译成功。
Some strange eclipse bug. Re-edited the manifest file, and the dependencies reappeared and the project successfully compiled.
如果有人仍然遇到这个问题,最终对我有用的解决方案是(在 Eclipse 4.3 上)
这应该修复该项目的插件依赖项条目。
希望有帮助!
In case anyone still encounters this issue, the solution that worked for me eventually was (on Eclipse 4.3)
This should fix the Plug-in Dependencies entries for that project.
Hope it helps!
检查您是否在 Eclipse 中定义了有效的目标平台。
转到窗口 ->首选项->插件开发->目标平台。
导入插件时,它被设置为空的目标平台,您可以通过首先编辑选定的目标,然后选择目标平台的内容选项卡来验证这一点,它是空的。
我将目标平台更改为“运行平台(活动)”。
这会在项目中导入必要的库,并将它们添加到插件依赖项中。
您还可以选择定义自己的自定义目标平台,但这需要更多的工作和知识。
Check that you defined a valid target platform in Eclipse.
Go to Window -> Preferences -> Plug-in Development -> Target Platform.
When importing the plugin it was set to an empty target platform, you can verify this by first edit the selected target, then selecting the content tab of the target platform, it's empty.
I changed the Target Platform to 'Running Platform (Active)'.
This imported the necessary libs in the project, they were added to the plugin dependencies.
You can also opt to define your own custom target platform but that needs some more work and knowledge.
.classpath 文件仅适用于 Java 构建器。依赖项位于 META-INF/MANIFEST.MF 中
The .classpath file is for Java builder only. Dependencies are in META-INF/MANIFEST.MF