You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have used JNAerator to produce java bindings for a shared library using the corresponding headers. The generated code can't find the native library at runtime. (I get UnsatisfiedLinkError)
I used the following options to generate the bindings:
$JNAERATOR -mode StandaloneJar -runtime JNA -forceStringSignatures -beanStructs -beautifyNames deezer.h Linux/x86_64/libdeezer.so -jar ../lib/deezer.jar
In the jar that was produced, the library file was put in the following location:
lib/linux_x64/libdeezer.so
However, debugging the problem I can see that when the code searches for the library in resources, it looks in the following location:
x86_64-linux-gnu/libdeezer.so
See com.sun.jna.Native#extractFromResourcePath(...)
This makes the generated standalone jar useless!
The text was updated successfully, but these errors were encountered:
I have used JNAerator to produce java bindings for a shared library using the corresponding headers. The generated code can't find the native library at runtime. (I get UnsatisfiedLinkError)
I used the following options to generate the bindings:
$JNAERATOR -mode StandaloneJar -runtime JNA -forceStringSignatures -beanStructs -beautifyNames deezer.h Linux/x86_64/libdeezer.so -jar ../lib/deezer.jar
In the jar that was produced, the library file was put in the following location:
lib/linux_x64/libdeezer.so
However, debugging the problem I can see that when the code searches for the library in resources, it looks in the following location:
x86_64-linux-gnu/libdeezer.so
See com.sun.jna.Native#extractFromResourcePath(...)
This makes the generated standalone jar useless!
The text was updated successfully, but these errors were encountered: