运行mvn jfx时出现UnsatisfiedLinkError:使用IntelliJ运行 [英] UnsatisfiedLinkError when running mvn jfx:run with IntelliJ

查看:295
本文介绍了运行mvn jfx时出现UnsatisfiedLinkError:使用IntelliJ运行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用了快速启动JavaFX原型 http://zenjava.com/javafx/maven/index.htmlrel =nofollow> JavaFX Maven插件,用于创建Maven JavaFX项目。

I have used the Quickstart JavaFX archetype from the JavaFX Maven Plugin to create a Maven JavaFX project.

当使用mvn jfx:run从命令行运行此项目时,一切正常,但是当我尝试通过在命令行中使用jfx:run创建运行配置从IntelliJ(12.1.6)运行它时得到一个UnsatisifedLinkError:

When running this project from the command line with "mvn jfx:run" everything works fine, but when I try to run it from IntelliJ (12.1.6) by creating a run configuration with "jfx:run" in the command line I get an UnsatisifedLinkError:

java.lang.UnsatisfiedLinkError: com.sun.glass.ui.win.WinApplication._submitForLaterInvocation(Ljava/lang/Runnable;)V
    at com.sun.glass.ui.win.WinApplication._submitForLaterInvocation(Native Method)
    at com.sun.glass.ui.win.WinApplication.submitForLaterInvocation(WinApplication.java:215)
    at com.sun.glass.ui.InvokeLaterDispatcher.run(InvokeLaterDispatcher.java:101)

有关如何解决此问题的任何建议?

Any advice for how to fix this?

推荐答案

将JRE / bin目录添加到java.libary.path系统属性似乎可行。 JVM使用此属性来定位具有本机代码的DLL。

Adding the JRE /bin directory to the java.libary.path system property seems to work. This property used by the JVM for locating DLLs with native code.

编辑运行/调试配置并将运行器配置的VM选项设置为:

Edit run/debug configuration and set the VM Options of the runner configuration to something like:


-Djava.library.path =C:\Program Files\Java\jdk1.7.0_45\jre\bin

-Djava.library.path="C:\Program Files\Java\jdk1.7.0_45\jre\bin"

这篇关于运行mvn jfx时出现UnsatisfiedLinkError:使用IntelliJ运行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆