blob: e6c15cc1dbc9bdc71db1becea97317f0ef4ddbf4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
--- a/src/java/net/jpountz/util/Native.java
+++ b/src/java/net/jpountz/util/Native.java
@@ -100,17 +100,18 @@ public enum Native {
return;
}
- cleanupOldTempLibs();
+// cleanupOldTempLibs();
// Try to load lz4-java (liblz4-java.so on Linux) from the java.library.path.
+ final File library = new File(System.mapLibraryName("lz4-java"));
try {
- System.loadLibrary("lz4-java");
+ System.load(library.getAbsolutePath());
loaded = true;
return;
} catch (UnsatisfiedLinkError ex) {
// Doesn't exist, so proceed to loading bundled library.
}
-
+/*
String resourceName = resourceName();
InputStream is = Native.class.getResourceAsStream(resourceName);
if (is == null) {
@@ -158,6 +159,6 @@ public enum Native {
tempLib.deleteOnExit();
tempLibLock.deleteOnExit();
}
- }
+ }*/
}
}
|