简体   繁体   English

JNA java.lang.UnsatisfiedLinkError:无法加载库'./OUNPPM'

[英]JNA java.lang.UnsatisfiedLinkError: Unable to load library './OUNPPM'

So, I have a project that uses a series of external C .dll s and it works fine when running in Netbeans, but when I try to run the .jar by itself, I get this error: 所以,我有一个使用一系列外部C .dll的项目,它在Netbeans中运行时工作正常,但是当我尝试.jar运行.jar ,我收到此错误:

Exception in thread "Thread-3" java.lang.UnsatisfiedLinkError: Unable to load library './OUNPPM': The specified module could not be found. 线程“Thread-3”中的异常java.lang.UnsatisfiedLinkError:无法加载库'./OUNPPM':找不到指定的模块。

I've encountered this before for a few different reasons: 我之前遇到过这个问题有几个原因:

1) Not finding the file. 1)找不到文件。 2) Not finding another .dll that .dll is dependent on. 2)没有找到.dll依赖的另一个.dll。 3) Trying to load a 64-bit .dll with the 32-bit JRE (or vice versa) 3)尝试使用32位JRE加载64位.dll(反之亦然)

Is there any way to get a better error message to find out what is going on? 有没有办法得到更好的错误信息,以找出发生了什么? JNI gave better errors, but I'm not really at a place I can change those right now. JNI给出了更好的错误,但我现在并不是真正能够改变这些错误的地方。

when you are launching the main class in your jar file, how are you running it and have you set your jna.library.path. 当您在jar文件中启动主类时,如何运行它并让您设置jna.library.path。

If your jna.library.path points to the location of the correct dlls then you shoul dnot get those errors. 如果您的jna.library.path指向正确dll的位置,那么您应该不会得到这些错误。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 java.lang.UnsatisfiedLinkError:无法加载库 - java.lang.UnsatisfiedLinkError: Unable to load library Applet jna.jar-java.lang.UnsatisfiedLinkError:无法加载库 - Applet jna.jar - java.lang.UnsatisfiedLinkError: Unable to load library 线程“ main”中的异常java.lang.UnsatisfiedLinkError:无法加载库 - Exception in thread “main” java.lang.UnsatisfiedLinkError: Unable to load library 无法加载Xuggle库:java.lang.UnsatisfiedLinkError - Unable to load Xuggle library: java.lang.UnsatisfiedLinkError JNA-Ubuntu上的java.lang.UnsatisfiedLinkError - JNA - java.lang.UnsatisfiedLinkError on Ubuntu ghost4j调用ghotscript dll-java.lang.UnsatisfiedLinkError:无法加载库'gsdll32 - ghost4j invoking ghotscript dll - java.lang.UnsatisfiedLinkError: Unable to load library 'gsdll32 线程“main”中的异常 java.lang.UnsatisfiedLinkError - 无法加载库 - 无法获取 InputStream - Exception in thread “main” java.lang.UnsatisfiedLinkError - Unable to load library - Can't obtain InputStream java.lang.UnsatisfiedLinkError:无法加载库“ jpbc-pbc”:找不到指定的模块 - java.lang.UnsatisfiedLinkError: Unable to load library 'jpbc-pbc': The specified module could not be found 为什么会出现java.lang.UnsatisfiedLinkError:无法加载库? - Why do I get java.lang.UnsatisfiedLinkError: Unable to load library? 线程“主”中的异常java.lang.UnsatisfiedLinkError:无法加载库“ TableauExtract”:找不到指定的模块 - Exception in thread “main” java.lang.UnsatisfiedLinkError: Unable to load library 'TableauExtract': The specified module could not be found
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM