From ee36b61cbfeded5aadd21fce39b9deb3983fefc1 Mon Sep 17 00:00:00 2001 From: gwenn Date: Sat, 1 Jul 2017 17:23:04 +0200 Subject: [PATCH] Try to fix Appveyor build Seems to be related to this: https://github.com/java-native-access/jna/pull/633 --- src/main/java/org/sqlite/SQLite.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main/java/org/sqlite/SQLite.java b/src/main/java/org/sqlite/SQLite.java index bdf4377..ac4c7b5 100644 --- a/src/main/java/org/sqlite/SQLite.java +++ b/src/main/java/org/sqlite/SQLite.java @@ -12,6 +12,7 @@ import com.sun.jna.Library; import com.sun.jna.Memory; import com.sun.jna.Native; +import com.sun.jna.NativeLibrary; import com.sun.jna.Pointer; import com.sun.jna.PointerType; import com.sun.jna.ptr.IntByReference; @@ -19,6 +20,7 @@ import java.nio.ByteBuffer; import java.nio.charset.Charset; +import java.util.Collections; // TODO JNA/Bridj/JNR/JNI and native libs embedded in JAR. public final class SQLite implements Library { @@ -26,7 +28,7 @@ public final class SQLite implements Library { // public static final NativeLibrary JNA_NATIVE_LIB = NativeLibrary.getInstance(SQLite.JNA_LIBRARY_NAME); static { - Native.register(JNA_LIBRARY_NAME); + Native.register(NativeLibrary.getInstance(JNA_LIBRARY_NAME, Collections.singletonMap(OPTION_STRING_ENCODING, "UTF-8"))); } public static final int SQLITE_OK = 0;