使用 Maven 的依赖管理而不使用 RCP 应用程序的构建功能?
我想构建一个Eclipse RCP应用程序,并且为了易用性还想使用Maven的依赖管理,以便自动解决依赖关系。
我尝试过 Tycho,但没有成功(我想我还没有找到正确的方法来设置我的项目),但我什至不需要 Tycho 的功能,因为我只想使用 Maven 的依赖解析,并且从 Eclipse 内部构建。
有没有办法在 Eclipse 中设置插件项目,以便我可以使用依赖项管理而不必使用 Tycho?
非常感谢!
I want to build an Eclipse RCP application, and for ease of use also want to use Maven's Dependency Management, so that dependencies are automatically resolved.
I've tried Tycho, but to no avail (I guess I haven't found the right way to set up my project yet), but I wouldn't even need Tycho's power, as I want to use Maven's dependency resolution only, and build from within Eclipse.
Is there a way to set up the Plugin project in Eclipse, so that I can use the dependency management without having to use Tycho?
Many thanks in advance!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我已经搜索过类似的东西,但是你不能仅使用 Maven 进行依赖管理。有几个原因,大多数与 OSGI 相关,第二件事是您必须将所有 jar 放在本地才能构建 Eclipse RCP,而不是从另一个目录链接。
你可以尝试一些肮脏的技巧
http://felix.apache.org/site/apache -felix-maven-bundle-plugin-bnd.html
并手动复制您的依赖项,但这很痛苦,而且效果不佳。正确的方法是使用第谷。
以下是一些可以帮助您使用 tycho 设置插件的示例:
http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/tree/tycho-demo
I have searched for something simillar, but you can not use maven only for dependency management. There are several reasons, most are OSGI related, second thing is you have to have all you jar local in place to build Eclipse RCP, and not linked from another directory.
You could try couple of dirty tricks using
http://felix.apache.org/site/apache-felix-maven-bundle-plugin-bnd.html
and manual copying of your dependency but that is pain, and does not work very well. The right way to do it would it be to use tycho.
Here are couple of examples that could help you to setup your plugin using tycho:
http://git.eclipse.org/c/tycho/org.eclipse.tycho.git/tree/tycho-demo