How to add a dll to a jar
807603Nov 29 2007 — edited Dec 3 2007Hi! Everyone.
I have a jar which contains a few classes and a dll file which one of my class uses. When I run my java class, it throws the following Exception.
Exception in thread "main" java.lang.UnsatisfiedLinkError: no WinSpecific in java.library.path
at java.lang.ClassLoader.loadLibrary(Unknown Source)
at java.lang.Runtime.loadLibrary0(Unknown Source)
at java.lang.System.loadLibrary(Unknown Source)
at WinSpecific.<clinit>(WinSpecific.java:6)
at Specific.<init>(Specific.java:10)
at Specific.main(Specific.java:30)
(WinSpecific is the name of the dll)
If my jar and dll both are in the same folder and the dll file in an extracted form then there is no problem, the class would run. But I want the dll to be inside the jar.
Please help.