Skip to Main Content

Java SE (Java Platform, Standard Edition)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Native library problem

824073Apr 6 2012 — edited Apr 14 2012
Hi all,

I'm currently converting a desktop application to Java Web Start. This desktop application uses a native library (rxtx) and works just fine as a standalone application.

I created a jar file that contains the native library (dll file) and added this to my deployment descriptor:
	<resources os="Windows" arch="x86">
		<nativelib href="native/rxtx32.jar"/>
		<jar href="native/swt32.jar"/>
	</resources>
	<resources os="Windows" arch="x86_64">
		<nativelib href="native/rxtx64.jar"/>
		<jar href="native/swt64.jar"/>
	</resources>
	<resources os="Windows" arch="amd64">
		<nativelib href="native/rxtx64.jar"/>
		<jar href="native/swt64.jar"/>
	</resources>
Every time I run the application, I get this error:

Caused by: java.lang.UnsatisfiedLinkError: no rxtxSerial 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)

I don't understand what I am missing. Does the jar file need to contain anything else other than the native dll?

Thanks
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 12 2012
Added on Apr 6 2012
15 comments
1,695 views