Eclipse plugin 如何从Eclipse插件链接为Java编译的Z3构建?
Eclipse plugin 如何从Eclipse插件链接为Java编译的Z3构建?,eclipse-plugin,z3,Eclipse Plugin,Z3,我有一个完美工作的Z3 Java构建系统。我想从Eclipse插件中调用它。我尝试了几种方法,但没有一种对我有效。这些方法是:
将Z3 build添加为外部类文件夹
线程“main”java.lang.UnsatifiedLink中出现异常错误:否
位于的java.library.path中的libz3java
loadLibrary(ClassLoader.java:1867)位于
位于的java.lang.Runtime.loadLibrary0(Runtime.java:870)
jav
我有一个完美工作的Z3 Java构建系统。我想从Eclipse插件中调用它。我尝试了几种方法,但没有一种对我有效。这些方法是:
将Z3 build添加为外部类文件夹
线程“main”java.lang.UnsatifiedLink中出现异常错误:否
位于的java.library.path中的libz3java
loadLibrary(ClassLoader.java:1867)位于
位于的java.lang.Runtime.loadLibrary0(Runtime.java:870)
java.lang.System.loadLibrary(System.java:1122)位于
Native.(Native.java:14)位于
com.microsoft.z3.Global.ToggleWarningMessages(Global.java:87)位于
main(TestZ3.java:9)
将Z3构建复制到Eclipse插件的根目录中。然后在库下添加com.microsoft.z3.jar(右键单击项目->构建路径->配置构建路径->库->添加jar)。错误是:
java.lang.UnsatisfiedLinkError:位于的java.library.path中没有libz3java
loadLibrary(ClassLoader.java:1867)位于
位于的java.lang.Runtime.loadLibrary0(Runtime.java:870)
java.lang.System.loadLibrary(System.java:1122)位于
Native.(Native.java:14)位于
com.microsoft.z3.Global.ToggleWarningMessages(Global.java:87)位于
plugintest.handlers.SampleHandler.execute(SampleHandler.java:37)位于
org.eclipse.ui.internal.handlers.HandlerProxy.execute(HandlerProxy.java:295)
在
org.eclipse.ui.internal.handlers.E4HandlerProxy.execute(E4HandlerProxy.java:90)
位于的sun.reflect.NativeMethodAccessorImpl.invoke0(本机方法)
invoke(NativeMethodAccessorImpl.java:62)
在
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
位于java.lang.reflect.Method.invoke(Method.java:498)
org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:56)
在
org.eclipse.e4.core.internal.di.InjectorImpl.invokeUsingClass(InjectorImpl.java:252)
在
org.eclipse.e4.core.internal.di.InjectorImpl.invoke(InjectorImpl.java:234)
在
org.eclipse.e4.core.contexts.ContextInjectionFactory.invoke(ContextInjectionFactory.java:132)
在
org.eclipse.e4.core.commands.internal.HandlerServiceHandler.execute(HandlerServiceHandler.java:152)
在
org.eclipse.core.commands.Command.executeWithChecks(Command.java:493)
在
org.eclipse.core.commands.ParameterizedCommand.executeWithChecks(ParameterizedCommand.java:486)
在
org.eclipse.e4.core.commands.internal.HandlerServiceImpl.executeHandler(HandlerServiceImpl.java:210)
在
org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem.executeItem(HandledContributionItem.java:799)
在
org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem.handleWidgetSelection(HandledContributionItem.java:675)
在
org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem.access$7(HandledContributionItem.java:659)
在
org.eclipse.e4.ui.workbench.renderers.swt.HandledContributionItem$4.handleEvent(HandledContributionItem.java:592)
位于org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
位于org.eclipse.swt.widgets.Display.sendEvent(Display.java:4362)
org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1113)位于
org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4180)
在org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3769)上
在
org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$4.run(PartRenderingEngine.java:1127)
在
org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:337)
在
org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1018)
在
org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:156)
位于org.eclipse.ui.internal.Workbench$5.run(Workbench.java:694)
org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:337)
在
org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:606)
在
org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:150)
在
org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:139)
在
org.eclipse.equinox.internal.app.eclipseeapphandle.run(eclipseeapphandle.java:196)
在
org.eclipse.core.runtime.internal.adapter.eclipseeappluncher.runApplication(eclipseeappluncher.java:134)
在
org.eclipse.core.runtime.internal.adapter.eclipseeappluncher.start(eclipseeappluncher.java:104)
在
org.eclipse.core.runtime.adapter.EclipseStarter.run(EclipseStarter.java:380)
在
org.eclipse.core.runtime.adapter.EclipseStarter.run(EclipseStarter.java:235)
位于的sun.reflect.NativeMethodAccessorImpl.invoke0(本机方法)
invoke(NativeMethodAccessorImpl.java:62)
在
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
位于java.lang.reflect.Method.invoke(Method.java:498)
org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:669)位于
org.eclipse.equinox.launcher.Main.basicRun(Main.java:608)位于
org.eclipse.equinox.launcher.Main.run(Main.java:1515)位于
org.eclipse.equinox.launcher.Main.Main(Main.java:1488)
不管有没有上一步,我都将com.microsoft.z3.jar添加到位于Plugin.xml运行时选项卡的Classpath中。在这种情况下,插件找不到按钮按下命令后调用的处理程序
!!找不到消息pluginest.handlers.SampleHandler
PluginTest_1.0.0.0限定符!堆栈0 java.lang.ClassNotFoundException:
找不到plugintest.handlers.SampleHandler…详细信息
事实上,这种方法在我之前的一次安装(戴尔、英特尔、x64、EclipseMars(x64)、Java1.8x64)中很有效
在中的讨论之后,我使用z3 Build direct配置了com.microsoft.z3.jar的本机库位置
HP Laptop (AMD, x64)
C:\Users\nmd02\git\resa_mars_workspace>java -version
java version "1.8.0_144"
Java(TM) SE Runtime Environment (build 1.8.0_144-b01)
Java HotSpot(TM) 64-Bit Server VM (build 25.144-b01, mixed mode)