Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 14 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,21 @@ regen:
# NOTE: adding v (verbose) flag for the beginning stage:
ndkbuild:
rm -rf lib libs
ndk-build
zip sqlite-native-driver-libs.zip libs/*/*
# 29/08/2024 Android 15 : Add Page Size 16Kb support
# ndk-build
ndk-build.cmd

# 29/08/2024 Android 15 : Add Page Size 16Kb support
#zip sqlite-native-driver-libs.zip libs/*/*
zip sqlite-ndk-native-driver-libs.zip libs/*/*
mv libs lib
jar cf sqlite-native-driver.jar lib

# 29/08/2024 Android 15 : Add Page Size 16Kb support
#jar cf sqlite-native-driver.jar lib
jar cf sqlite-ndk-native-driver.jar lib

clean:
rm -rf obj lib libs sqlite-native-driver.jar *.zip
# 29/08/2024 Android 15 : Add Page Size 16Kb support
#rm -rf obj lib libs sqlite-native-driver.jar *.zip
rm -rf obj lib libs sqlite-ndk-native-driver.jar *.zip

6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
# WARNING TEST PLUGIN

This plugin is forked from https://github.com/brodycj/Android-sqlite-ext-native-driver, and only provided to test the compilation of new Libs for Android 15 16Kb Page Size.



# Android sqlite native driver with extra features

Provides Android NDK build of sqlite3 (<http://sqlite.org/>, public domain) with a low-level JNI interface accessible from a single (singleton) single `SQLiteNative` class, along with the following extra features: REGEXP, BASE64
Expand Down
5 changes: 5 additions & 0 deletions jni/Android.mk
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,11 @@ LOCAL_CFLAGS += -DSQLITE_ENABLE_JSON1
LOCAL_CFLAGS += -DSQLITE_DEFAULT_PAGE_SIZE=4096
LOCAL_CFLAGS += -DSQLITE_DEFAULT_CACHE_SIZE=-2000

# 29/08/2024 Android 15 : Add Page Size 16Kb support
# https://developer.android.com/guide/practices/page-sizes
# https://source.android.com/docs/core/architecture/16kb-page-size/16kb
LOCAL_LDFLAGS += "-Wl,-z,max-page-size=16384"

LOCAL_SRC_FILES := ../native/sqlc_all.c

include $(BUILD_SHARED_LIBRARY)
3 changes: 3 additions & 0 deletions jni/Application.mk
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,6 @@ APP_ABI := armeabi-v7a x86 x86_64 arm64-v8a
# - https://developer.android.com/ndk/guides/stable_apis
# - https://developer.android.com/studio/releases/platforms
APP_PLATFORM := android-22

# 03/09/2024 Android 15 : Add Page Size 16Kb support
APP_SUPPORT_FLEXIBLE_PAGE_SIZES := true
17 changes: 17 additions & 0 deletions notes.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@

Install cygwin: setup-x86_64.exe -q --packages="make zip"
C:\Users\alex\Documents\GitHub\Android-sqlite-ext-native-driver

Modify jni/Android.mk
LOCAL_MODULE := sqlc-native-driver --> LOCAL_MODULE := sqlc-ndk-native-driver

Modify jni/Application.mk
APP_SUPPORT_FLEXIBLE_PAGE_SIZES := true

Open cygwin
cd /cygdrive/c/Users/alex/Documents/GitHub/Android-sqlite-native-driver
export PATH=$PATH:/cygdrive/c/Users/alex/AppData/Local/Android/Sdk/ndk/27.0.12077973/
export PATH=$PATH:export PATH=$PATH:/cygdrive/c/Program\ Files/Java/jdk-18.0.2/bin/
source ~/.bashrc
make init
make
Binary file added sqlite-ndk-native-driver.jar
Binary file not shown.