0

我正在尝试创建一个具有 selenium firefox Web 驱动程序的 OSGI 包。我在 Maven 项目中使用了相同的依赖项,并且一切正常。但是当我创建包时,编译没有问题。但是在安装 bundle 时,有一些内部依赖项无法解决。maven bundle 插件 embed-transitivy 中有一个属性。我将它设置为 true ,它几乎解决了 firefox-webdriver 的所有内部依赖项。还有一些无法解决。

错误:

net.sf.cglib.asm.util -- Cannot be resolved
org.apache.avalon.framework.logger -- Cannot be resolved
org.apache.log -- Cannot be resolved
org.apache.log4j from log4j.over.slf4j (4)
org.apache.tools.ant -- Cannot be resolved
org.apache.tools.ant.types -- Cannot be resolved
org.codehaus.aspectwerkz.hook -- Cannot be resolved
sun.misc -- Cannot be resolved

此外,当我在 cglib-nodep.2.1_3.jar 中搜索 net.sf.cglib.asm.util 时,没有这样的类。内部使用 cglib-nodep.2.1_3.jar 的 firefox 驱动程序。我猜2.1_3版本有问题。我不知道 OSGI 如何解析这个版本名称。

有人可以弄清楚可能是什么问题。我在哪里可以找到 net.sf.cglib.asm.util 类?

PS:我使用的是 2.25.0 版本的 firefox-driver,它在内部依赖于 cglib 并获取它的 2.1_3 版本。

4

2 回答 2

0

听起来你正面临这里描述的问题http://spring.io/blog/2009/01/19/exposing-the-boot-classpath-in-osgi/和这里http://blog.meschberger.ch/2008 /10/osgi-bundles-require-classes-from.html

于 2014-04-07T20:56:23.327 回答
0

我认为有一个不同的问题。你可能想看看这个。 http://code.google.com/p/google-guice/issues/detail?id=208

您遇到了同样的问题。所以读那个。它可能会有所帮助。

于 2012-09-17T10:57:20.177 回答