简体   繁体   English

Eclipse Tycho无法解析正确的依赖关系

[英]Eclipse Tycho not able to resolve the correct dependency

I am utilizing Eclipse Tycho to build my RCP application with GMF dependencies. 我正在利用Eclipse Tycho来构建具有GMF依赖关系的RCP应用程序。

I am getting the following error - 我收到以下错误 -

[ERROR] Internal error: java.lang.RuntimeException: Could not download artifacts from any repository
[ERROR] osgi.bundle,org.eclipse.gmf.runtime.emf.core,1.4.1.v20120514-1615
[ERROR] osgi.bundle,org.eclipse.gmf.runtime.emf.commands.core,1.4.0.v20120514-1615
[ERROR] osgi.bundle,org.eclipse.gmf.runtime.emf.ui.properties,1.5.0.v20120514-1615
[ERROR] osgi.bundle,org.eclipse.gmf.runtime.diagram.ui,1.6.0.v20120514-1615
[ERROR] osgi.bundle,org.eclipse.gmf.runtime.diagram.ui.properties,1.4.2.v20120514-1615
[ERROR] osgi.bundle,org.eclipse.gmf.runtime.diagram.ui.providers,1.5.0.v20120514-1615
[ERROR] osgi.bundle,org.eclipse.gmf.runtime.diagram.ui.providers.ide,1.2.0.v20120514-1615
[ERROR] osgi.bundle,org.eclipse.gmf.runtime.diagram.ui.render,1.6.0.v20120514-1615
[ERROR] osgi.bundle,org.eclipse.gmf.runtime.diagram.ui.resources.editor,1.4.1.v20120514-1615
[ERROR] osgi.bundle,org.eclipse.gmf.runtime.diagram.ui.resources.editor.ide,1.2.1.v20120514-1615

I am specifing the following dependency in the Manifest.MF - 我在Manifest.MF中指定了以下依赖项 -

org.eclipse.gmf.runtime.emf.core;bundle-version="1.4.1",
 org.eclipse.gmf.runtime.emf.commands.core;bundle-version="1.4.0",
 org.eclipse.gmf.runtime.emf.ui.properties;bundle-version="1.5.0",
 org.eclipse.gmf.runtime.diagram.ui;bundle-version="1.6.0",
 org.eclipse.gmf.runtime.diagram.ui.properties;bundle-version="1.4.2",
 org.eclipse.gmf.runtime.diagram.ui.providers;bundle-version="1.5.0",
 org.eclipse.gmf.runtime.diagram.ui.providers.ide;bundle-version="1.2.0",
 org.eclipse.gmf.runtime.diagram.ui.render;bundle-version="1.6.0",
 org.eclipse.gmf.runtime.lite.svg;bundle-version="1.0.0",
 org.eclipse.gmf.runtime.diagram.ui.resources.editor;bundle-version="1.4.1",
 org.eclipse.gmf.runtime.diagram.ui.resources.editor.ide;bundle-version="1.2.1",

I have provided the repository location for GMF bundle as - 我已经为GMF包提供了存储库位置 -

<repository>
  <id>gmf-runtime</id>
  <url>http://download.eclipse.org/modeling/gmp/gmf-runtime/updates/releases</url>
  <layout>p2</layout>
</repository>

The P2 repository has all the above JAR's. P2存储库具有上述所有JAR。 The only difference is that for some reason Tycho is looking for .v20120514-1615 qualifier. 唯一的区别是出于某种原因,Tycho正在寻找.v20120514-1615资格赛。 However the P2 repository has .201302191707 qualifier. 但是P2存储库具有.201302191707限定符。 Not sure why Tycho is looking for that specific qualifier and not resolve to the latest version. 不确定为什么Tycho正在寻找那个特定的限定符而不是解决最新版本。

It seems the original P2 Repo was corrupted. 原来的P2 Repo似乎已经损坏了。 The problem is that Tycho tries to index the whole P2 repo even if the Plugins are not referenced. 问题是Tycho试图索引整个P2 repo,即使没有引用插件。 To solve this what did was - 要解决这个问题 -

  1. Open .product file and export the product 打开.product文件并导出产品
  2. Copy the 'repository' folder from the exported product artifacts and place it in a shared location 从导出的产品工件中复制“repository”文件夹并将其放在共享位置
  3. In the tag in Maven pom.xml give the location of this repository instead if external repositories. 在Maven pom.xml中的标记中,如果是外部存储库,则提供此存储库的位置。 All the future Tycho builds will use this repository 所有未来的Tycho构建都将使用此存储库

This way the repo size is small and all the build issues are resolved. 这样,repo大小很小,所有构建问题都得到了解决。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Eclipse无法解决Maven依赖关系 - Eclipse not able to resolve Maven dependency 使用 Tycho 解决对包 sun.misc 的依赖 - Resolve a dependency on package sun.misc with Tycho 第谷无法解析片段对其他片段的依赖 - Tycho cannot resolve fragment dependency on other fragment 需要Apache commons-lang3作为使用Tycho构建的Eclipse插件的依赖项 - Need Apache commons-lang3 as dependency of an Eclipse plugin built with Tycho 使用mvn-tycho时将参数传递给依赖项eclipse插件 - Passing arguments to dependency eclipse plugins when using mvn-tycho 在目标文件中更改位置后,Tycho 无法解析间接引用的依赖项 - After changing location in Target file, Tycho can not resolve indirectly referenced dependency 带有手动导出但没有使用tycho生成的Eclipse产品启动没有找到应用程序ID依赖项问题 - eclipse product launching with manual export but not with tycho build no application id has been found dependency leaf issue 无法使用pom.xml中的T​​ycho 1.0.0解决“ eclipse-plugin”打包类型 - Unable to resolve “eclipse-plugin” packaging type with Tycho 1.0.0 in pom.xml 如何解决 JPMS 和 OSGi Bundle 之间的冲突,用于 Eclipse 插件项目和 Tycho - How to resolve conflict between JPMS and OSGi Bundle for Eclipse plugin project an Tycho Maven 无法使用 Eclipse 解析 Jacob 依赖 - Maven cannot resolve Jacob dependency using eclipse
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM