我必须如何安装/配置 Xuggle 才不会出现 UnsatisfiedLinkError?
我刚刚开始使用 Xuggle,我将所有内容下载到 Eclipse 中,并将它们包含在引用库中,但我做了一个非常简单的测试,
package com.xuggle.xuggler.demos;
import com.xuggle.xuggler.IContainer;
public class getContainerInfo {
public static void main (String [] args){
IContainer myContainer = IContainer.make();
}
}
它引发了一堆错误,
2011-06-12 16:26:52,142 [main] ERROR com.xuggle.ferry.JNILibraryLoader - Could not load library: xuggle-xuggler; version: 3; Visit http://www.xuggle.com/xuggler/faq/ to find common solutions to this problem
Exception in thread "main" java.lang.UnsatisfiedLinkError: no xuggle-xuggler in java.library.path
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1734)
at java.lang.Runtime.loadLibrary0(Runtime.java:823)
at java.lang.System.loadLibrary(System.java:1028)
at com.xuggle.ferry.JNILibraryLoader.loadLibrary0(JNILibraryLoader.java:265)
at com.xuggle.ferry.JNILibraryLoader.loadLibrary(JNILibraryLoader.java:168)
at com.xuggle.xuggler.XugglerJNI.<clinit>(XugglerJNI.java:19)
at com.xuggle.xuggler.IContainer.<clinit>(IContainer.java:1457)
at com.xuggle.xuggler.demos.getContainerInfo.main(getContainerInfo.java:9)
I am JUST getting started with Xuggle and I downloaded everything into Eclipse and I included them in them in the Referenced Libraries but I made a really simple test,
package com.xuggle.xuggler.demos;
import com.xuggle.xuggler.IContainer;
public class getContainerInfo {
public static void main (String [] args){
IContainer myContainer = IContainer.make();
}
}
and it throws a bunch of errors,
2011-06-12 16:26:52,142 [main] ERROR com.xuggle.ferry.JNILibraryLoader - Could not load library: xuggle-xuggler; version: 3; Visit http://www.xuggle.com/xuggler/faq/ to find common solutions to this problem
Exception in thread "main" java.lang.UnsatisfiedLinkError: no xuggle-xuggler in java.library.path
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1734)
at java.lang.Runtime.loadLibrary0(Runtime.java:823)
at java.lang.System.loadLibrary(System.java:1028)
at com.xuggle.ferry.JNILibraryLoader.loadLibrary0(JNILibraryLoader.java:265)
at com.xuggle.ferry.JNILibraryLoader.loadLibrary(JNILibraryLoader.java:168)
at com.xuggle.xuggler.XugglerJNI.<clinit>(XugglerJNI.java:19)
at com.xuggle.xuggler.IContainer.<clinit>(IContainer.java:1457)
at com.xuggle.xuggler.demos.getContainerInfo.main(getContainerInfo.java:9)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
以下是我发现的。存在混乱,因为从 Xuggler 5.2 及更高版本开始,您不需要安装它并设置环境变量。
在网上寻找答案时,您可能会因发现新旧版本的步骤混合而感到困惑。下面 (B) 中的步骤不再适用。
我自己最终通过确保 jar 位于 J2EE 容器库中并从 Xuggler 5.2 升级到 5.4 解决了该问题。此后,链接错误消失了。
(A) 这适用于所有版本
来自Xuggler 文档:
(B) 这仅适用于 XUGGLER PRE 5.2
来自:Xuggler 常见问题解答:
Below is what I've found. There is confusion because as of Xuggler 5.2 and greater, you don't need to install it and set the environment variables.
When looking at the web for answers, you may be confused by finding a mixture of steps from old and new versions. The steps from (B) below, no longer apply.
I myself finally fixed the problem by making sure the jar was in the J2EE containers lib, and upgrading from Xuggler 5.2 to 5.4. Thereafter, the link error was gone.
(A) THIS APPLIES TO ALL VERSIONS
From the Xuggler Docs:
(B) THIS APPLIES ONLY TO XUGGLER PRE 5.2
From: Xuggler Faq:
问题是我没有重新启动。 Mtyson 在他的回答中包含了这一点,所以他是正确的。
The issue was that I didn't reboot. Mtyson included this in his answer, so he's correct.