简体   繁体   中英

deploy jar file with external libraries

I am finishing a project that I have to deploy as a jar file, in eclipse it works fine, my project depends on two libraries which also both depends on dll files. I have added the path to these dlls to the native library location of each one of the external jars. Then I export project as a jar file using the eclipse runnable jar file export wizard I get the jar file in the specified location, it runs but when I click on a button that calls one of the libraries I get I get java.lang.UnsatisfiedLinkError: no rxtxSerial in java.library.path on the console.

Edit : When I copy the dlls in [...]/jre7/bin/ folder my application works, but I want that my application runs without having to do this manipulation.

Regards.

像这样运行:java -Djava.library.path = / path_to_dll -jar app.jar

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM