Skip to content

Commit

Permalink
NeuronRobotics#224 Allow to specify native library name via a system …
Browse files Browse the repository at this point in the history
…property (and skip auto-detection)
  • Loading branch information
Neeme Praks committed Jun 21, 2022
1 parent 7aa21d1 commit 3eafb65
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/main/java/gnu/io/NativeResource.java
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,11 @@ private void inJarLoad(String name)throws UnsatisfiedLinkError, NativeResourceEx

private void loadLib(String name) throws NativeResourceException {
try {
String libNameFromClasspath = System.getProperty(name + ".classpathlib");
if(libNameFromClasspath != null) {
inJarLoad(libNameFromClasspath);
return;
}
if(OSUtil.isARM()) {
//System.err.println("Attempting arm variants");
for(String libName : OSUtil.is64Bit() ? ARM64_LIBS : ARM32_LIBS) {
Expand Down

0 comments on commit 3eafb65

Please sign in to comment.