1

I'm using a .jar library that needs additional .dll or .so to function. I copied them in a folder in my eclipse project and then added that folder to the native library location in Properties -> Java Build Path -> Libraries. When I start my application in eclipse, it works well but when I export it as a runnable jar and then execute it, it doesnt work anymore and gives me a java.lang.UnsatisfiedLinkError error.

Is there a possibility to add these additional files inside the .jar and also add them to the java.library.path variable when running the application?

Regards

1 Answer 1

1

I would suggest creating new resources folder in Eclipse (if you are using it, since that folder will be on classpath), or just add it manually to classpath.

Sign up to request clarification or add additional context in comments.

2 Comments

well if i do that, the path still has to be assigned to java.library.path, and i don't know how to do that. (btw. ive tried adding a resource folder already)
Are you using eclipse?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.