我正在尝试在 android 上启动 OSGI Felix 框架。我点击了这个链接,一切都很顺利。在 bundle 目录中,我添加了一个 bundle,它是我之前创建的一个 eclipse 插件项目,以便在 android 上启动它。它只有一个在 start() 方法中带有“Hello”消息的激活器类。现在,当我在 android shell 上启动 Felix 时,我注意到我添加的包引起了问题,无法在 android 上启动。这是我在启动 Felix 时遇到的错误:
ERROR: Error starting file:bundle/HelloforAndroid_1.0.0.201307312320.jar (org.os
gi.framework.BundleException: Activator start error in bundle HelloforAndroid [5
].)
java.lang.UnsupportedOperationException: can't load this type of class file
at java.lang.VMClassLoader.defineClass(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:292)
at org.apache.felix.framework.searchpolicy.ContentClassLoader.findClass(
ContentClassLoader.java:223)
at org.apache.felix.framework.searchpolicy.ContentClassLoader.loadClassF
romModule(ContentClassLoader.java:94)
at org.apache.felix.framework.searchpolicy.ContentLoaderImpl.getClass(Co
ntentLoaderImpl.java:166)
at org.apache.felix.framework.searchpolicy.R4SearchPolicyCore.findClassO
rResource(R4SearchPolicyCore.java:471)
at org.apache.felix.framework.searchpolicy.R4SearchPolicyCore.findClass(
R4SearchPolicyCore.java:185)
at org.apache.felix.framework.searchpolicy.R4SearchPolicy.findClass(R4Se
archPolicy.java:45)
at org.apache.felix.moduleloader.ModuleImpl.getClass(ModuleImpl.java:216
)
at org.apache.felix.framework.Felix.createBundleActivator(Felix.java:346
8)
at org.apache.felix.framework.Felix._startBundle(Felix.java:1649)
at org.apache.felix.framework.Felix.startBundle(Felix.java:1578)
at org.apache.felix.framework.Felix.setFrameworkStartLevel(Felix.java:11
72)
at org.apache.felix.framework.StartLevelImpl.run(StartLevelImpl.java:265
)
谁能帮我弄清楚这个捆绑包有什么遗漏或错误?谢谢。