我们正在从Eclipse 3.5 RCP迁移到Eclispse Mars RCP。
在eclipse 3.5 RCP中,我们能够在32位和64位机器上启动我们的应用程序,即使产品导出是在32位或64位日食中完成的。 但是对于Eclipse Mars RCP,如果我们使用64位eclipse导出产品,那么它不能在32位机器上工作,而且它在64位机器上工作正常。与此类似,如果我们使用32位eclipse输出产品,它在32位机器上工作正常,而且它不能在64位工作
我在eclipse mars 64bit版本中使用导出产品向导导出项目。之后,我将该产品加入战争并在服务器中部署了相同的产品。通过使用jnlp文件,产品可以成功下载到本地客户端计算机。它在64位机器上成功推出。但是在32位机器上启动应用程序,我们得到了下面提到的异常。
org.osgi.framework.BundleException: Could not resolve module: org.eclipse.equinox.ds [3]
Unresolved requirement: Import-Package: org.eclipse.equinox.internal.util.event; version="1.0.0"
at org.eclipse.osgi.container.Module.start(Module.java:434)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1582)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1562)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.doContainerStartLevel(ModuleContainer.java:1533)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1476)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340)
在谷歌搜索后,我们发现如果我们在导出产品期间添加了插件文件夹中存在的org.eclipse.update。* jars,它可能会解决此问题。添加上面提到的问题后解决了,但得到org.eclispe.swt错误。
!SESSION 2015-09-23 15:02:06.883 -----------------------------------------------
eclipse.buildId=unknown
java.version=1.8.0_45
java.vendor=Oracle Corporation
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_US
!ENTRY org.eclipse.osgi 4 0 2015-09-23 15:02:31.177
!MESSAGE An error occurred while automatically activating bundle org.eclipse.ui.workbench (78).
!STACK 0
org.osgi.framework.BundleException: Error starting module.
at org.eclipse.osgi.container.Module.doStart(Module.java:580)
at org.eclipse.osgi.container.Module.start(Module.java:439)
at org.eclipse.osgi.framework.util.SecureAction$22.run(SecureAction.java:460)
at org.eclipse.osgi.framework.util.SecureAction$22.run(SecureAction.java:1)
at java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:458)
at org.eclipse.osgi.internal.hooks.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:107)
at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClass(ClasspathManager.java:531)
at org.eclipse.osgi.internal.loader.ModuleClassLoader.findLocalClass(ModuleClassLoader.java:324)
at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:327)
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:402)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:352)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:344)
at org.eclipse.osgi.internal.framework.BundleContextImpl.loadBundleActivator(BundleContextImpl.java:754)
at org.eclipse.osgi.internal.framework.BundleContextImpl.start(BundleContextImpl.java:706)
at org.eclipse.osgi.internal.framework.EquinoxBundle.startWorker0(EquinoxBundle.java:941)
at org.eclipse.osgi.internal.framework.EquinoxBundle$EquinoxModule.startWorker(EquinoxBundle.java:318)
at org.eclipse.osgi.container.Module.doStart(Module.java:571)
at org.eclipse.osgi.container.Module.start(Module.java:439)
at org.eclipse.osgi.framework.util.SecureAction$22.run(SecureAction.java:460)
at org.eclipse.osgi.framework.util.SecureAction$22.run(SecureAction.java:1)
at java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:458)
at org.eclipse.osgi.internal.hooks.EclipseLazyStarter.postFindLocalClass(EclipseLazyStarter.java:107)
at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClass(ClasspathManager.java:531)
at org.eclipse.osgi.internal.loader.ModuleClassLoader.findLocalClass(ModuleClassLoader.java:324)
at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:327)
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:402)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:352)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:344)
at org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:160)
at java.lang.ClassLoader.loadClass(Unknown Source)
at org.eclipse.osgi.internal.framework.EquinoxBundle.loadClass(EquinoxBundle.java:573)
at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:174)
at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905)
at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:191)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:380)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:235)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.*****..tool.installer.Installer.launchEclipse(Installer.java:959)
at com.*****..tool.installer.Installer.run(Installer.java:510)
at com.*****..tool.installer.Installer.main(Installer.java:1128)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.sun.javaws.Launcher.executeApplication(Unknown Source)
at com.sun.javaws.Launcher.executeMainClass(Unknown Source)
at com.sun.javaws.Launcher.doLaunchApp(Unknown Source)
at com.sun.javaws.Launcher.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.NoClassDefFoundError: org/eclipse/swt/SWTError
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Unknown Source)
at java.lang.Class.getConstructor0(Unknown Source)
at java.lang.Class.newInstance(Unknown Source)
at org.eclipse.osgi.internal.framework.BundleContextImpl.loadBundleActivator(BundleContextImpl.java:755)
at org.eclipse.osgi.internal.framework.BundleContextImpl.start(BundleContextImpl.java:706)
at org.eclipse.osgi.internal.framework.EquinoxBundle.startWorker0(EquinoxBundle.java:941)
at org.eclipse.osgi.internal.framework.EquinoxBundle$EquinoxModule.startWorker(EquinoxBundle.java:318)
at org.eclipse.osgi.container.Module.doStart(Module.java:571)
... 57 more
Caused by: java.lang.ClassNotFoundException: org.eclipse.swt.SWTError cannot be found by org.eclipse.ui.workbench_3.107.0.v20150510-1732
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:439)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:352)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:344)
at org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:160)
at java.lang.ClassLoader.loadClass(Unknown Source)
... 66 more
!ENTRY org.eclipse.swt.win32.win32.x86_64 2 0 2015-09-23 15:02:31.190
!MESSAGE Could not resolve module: org.eclipse.swt.win32.win32.x86_64 [91]
Unresolved requirement: Require-Capability: eclipse.platform; filter:="(& (osgi.ws=win32) (osgi.os=win32) (osgi.arch=x86_64))"
!ENTRY org.eclipse.core.resources.win32.x86_64 2 0 2015-09-23 15:02:31.191
!MESSAGE Could not resolve module: org.eclipse.core.resources.win32.x86_64 [87]
Unresolved requirement: Require-Capability: eclipse.platform; filter:="(& (osgi.os=win32) (osgi.arch=x86_64))"
!ENTRY org.eclipse.core.filesystem.win32.x86_64 2 0 2015-09-23 15:02:31.191
!MESSAGE Could not resolve module: org.eclipse.core.filesystem.win32.x86_64 [86]
Unresolved requirement: Require-Capability: eclipse.platform; filter:="(& (osgi.os=win32) (osgi.arch=x86_64))"
!ENTRY org.eclipse.equinox.security.win32.x86_64 2 0 2015-09-23 15:02:31.192
!MESSAGE Could not resolve module: org.eclipse.equinox.security.win32.x86_64 [89]
Unresolved requirement: Require-Capability: eclipse.platform; filter:="(& (osgi.os=win32) (osgi.arch=x86_64))"