我在我的安装程序中使用a Hyperic SIGAR库作为第三方库。 我的安装程序将所有第三个lib文件解压到%TEMP%\\ user文件夹。在多语言操作系统上使用Hyperic SIGAR时出现“java.library.path中没有sigar-x86-winnt.dll”错误
英语OS的一切都很正常,但是当我试图西班牙操作系统上运行我的安装程序, 我遇到了以下错误:
Java库包括sigar.jar:
java.class.path = C:\ DOCUME〜1 \ 西班牙语字母 \ CONFIG〜1个\ TEMP \ e4j58.tmp_dir \用户\ sigar.jar
我的安装程序支持的WinXP,Win7操作系统的。
的错误是:
no sigar-x86-winnt.dll in java.library.path
org.hyperic.sigar.SigarException: no sigar-x86-winnt.dll in java.library.path
at org.hyperic.sigar.Sigar.loadLibrary(Sigar.java:172)
at org.hyperic.sigar.Sigar.<clinit>(Sigar.java:100)
at I4jScript_Internal_1.eval(I4jScript_Internal_1.java:23)
at I4jScript_Internal_1.evaluate(I4jScript_Internal_1.java:79)
at com.install4j.runtime.installer.helper.Script.evaluate(Unknown Source)
at com.install4j.runtime.installer.ContextImpl.runScript(Unknown Source)
at com.install4j.runtime.installer.ContextImpl.runScript(Unknown Source)
at com.install4j.runtime.beans.actions.control.RunScriptAction.execute(Unknown Source)
at com.install4j.runtime.beans.actions.SystemInstallOrUninstallAction.install(Unknown Source)
at com.install4j.runtime.installer.InstallerContextImpl.performActionInt(Unknown Source)
at com.install4j.runtime.installer.ContextImpl.performAction(Unknown Source)
at com.install4j.runtime.installer.controller.Controller.executeActions(Unknown Source)
at com.install4j.runtime.installer.controller.Controller.handleCommand(Unknown Source)
at com.install4j.runtime.installer.controller.Controller.handleStartup(Unknown Source)
at com.install4j.runtime.installer.controller.Controller.start(Unknown Source)
at com.install4j.runtime.installer.Installer.main(Unknown Source)
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.exe4j.runtime.LauncherEngine.launch(Unknown Source)
at com.exe4j.runtime.WinLauncher.main(Unknown Source)
at com.install4j.runtime.launcher.WinLauncher.main(Unknown Source)'
是否有人已经遇到了类似的错误,并可以建议? 谢谢。
尝试这个例子加载文件 [1]:http://stackoverflow.com/questions/4691095/java-loading-dlls通过相对路径和隐藏他们在罐子里面 – Kris 2013-07-16 21:36:13