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
5 changes: 2 additions & 3 deletions .github/workflows/android-build-custom-dev-app.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,8 @@ jobs:
- name: npm install
run: npm ci

- name: Add NDK 26.1.10909125
run: echo "y" | ${ANDROID_HOME}/cmdline-tools/latest/bin/sdkmanager --install "ndk;26.1.10909125"

- name: Add NDK 27.3.13750724
run: echo "y" | ${ANDROID_HOME}/cmdline-tools/latest/bin/sdkmanager --install "ndk;27.3.13750724"
- name: Build with Gradle
run: ./gradlew assembleDevDebug
working-directory: ./android
27 changes: 26 additions & 1 deletion android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ buildscript {
androidXCore = "1.6.0"
androidXBrowser = "1.3.0"

ndkVersion = "26.1.10909125"
ndkVersion = "27.3.13750724"
}
repositories {
google()
Expand Down Expand Up @@ -84,6 +84,31 @@ allprojects {
maven {
url "$rootDir/../node_modules/@notifee/react-native/android/libs"
}

// Build all modules with Android 16KB pages enabled
plugins.withId('com.android.application') {
android {
defaultConfig {
externalNativeBuild {
cmake {
arguments "-DANDROID_SUPPORT_FLEXIBLE_PAGE_SIZES=ON"
}
}
}
}
}

plugins.withId('com.android.library') {
android {
defaultConfig {
externalNativeBuild {
cmake {
arguments "-DANDROID_SUPPORT_FLEXIBLE_PAGE_SIZES=ON"
}
}
}
}
}
}
}

Expand Down
16 changes: 6 additions & 10 deletions ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -52,11 +52,10 @@ PODS:
- RNCAsyncStorage
- SSZipArchive
- Yoga
- op-sqlite (15.0.7):
- op-sqlite (15.1.5):
- DoubleConversion
- glog
- hermes-engine
- OpenSSL-Universal
- RCT-Folly (= 2024.11.18.00)
- RCTRequired
- RCTTypeSafety
Expand All @@ -74,7 +73,6 @@ PODS:
- ReactCommon/turbomodule/bridging
- ReactCommon/turbomodule/core
- Yoga
- OpenSSL-Universal (3.3.3001)
- RCT-Folly (2024.11.18.00):
- boost
- DoubleConversion
Expand Down Expand Up @@ -2237,9 +2235,9 @@ PODS:
- ReactCommon/turbomodule/bridging
- ReactCommon/turbomodule/core
- Yoga
- SDWebImage (5.21.2):
- SDWebImage/Core (= 5.21.2)
- SDWebImage/Core (5.21.2)
- SDWebImage (5.21.3):
- SDWebImage/Core (= 5.21.3)
- SDWebImage/Core (5.21.3)
- SDWebImageAVIFCoder (0.11.1):
- libavif/core (>= 0.11.0)
- SDWebImage (~> 5.10)
Expand Down Expand Up @@ -2350,7 +2348,6 @@ SPEC REPOS:
- libavif
- libdav1d
- libwebp
- OpenSSL-Universal
- SDWebImage
- SDWebImageAVIFCoder
- SDWebImageWebPCoder
Expand Down Expand Up @@ -2549,8 +2546,7 @@ SPEC CHECKSUMS:
libdav1d: 23581a4d8ec811ff171ed5e2e05cd27bad64c39f
libwebp: 02b23773aedb6ff1fd38cec7a77b81414c6842a8
MendixNative: 358ef00fc883a39da69680c6c2a09ecf85a0b887
op-sqlite: 12554de3e1a0cb86cbad3cf1f0c50450f57d3855
OpenSSL-Universal: 6082b0bf950e5636fe0d78def171184e2b3899c2
op-sqlite: a8239b295e2fad068d587c16d6c41d1ffd98ede8
RCT-Folly: e78785aa9ba2ed998ea4151e314036f6c49e6d82
RCTDeprecation: be794de7dc6ed8f9f7fbf525f86e7651b8b68746
RCTRequired: a83787b092ec554c2eb6019ff3f5b8d125472b3b
Expand Down Expand Up @@ -2629,7 +2625,7 @@ SPEC CHECKSUMS:
RNScreens: 0d4cb9afe052607ad0aa71f645a88bb7c7f2e64c
RNSVG: 8ad5c94593e5e4a6e133e6934e2188e3c688d27a
RNVectorIcons: bd818296a51dc2bb8c3bd97a3ca399df1afe216d
SDWebImage: 9f177d83116802728e122410fb25ad88f5c7608a
SDWebImage: 16309af6d214ba3f77a7c6f6fdda888cb313a50a
SDWebImageAVIFCoder: afe194a084e851f70228e4be35ef651df0fc5c57
SDWebImageWebPCoder: e38c0a70396191361d60c092933e22c20d5b1380
SocketRocket: d4aabe649be1e368d1318fdf28a022d714d65748
Expand Down
Binary file added mendix-native-0.3.2.tgz
Binary file not shown.
16 changes: 8 additions & 8 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
"dependencies": {
"@d11/react-native-fast-image": "8.11.1",
"@gorhom/bottom-sheet": "5.1.1",
"mendix-native": "https://github.com/mendix/mendix-native/releases/download/v0.3.1/mendix-native-v0.3.1.tgz",
"@op-engineering/op-sqlite": "15.0.7",
"mendix-native": "./mendix-native-0.3.2.tgz",
"@op-engineering/op-sqlite": "15.1.5",
"@react-native-async-storage/async-storage": "2.0.0",
"@react-native-camera-roll/camera-roll": "7.4.0",
"@react-native-community/cli": "18.0.1",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
diff --git a/node_modules/@op-engineering/op-sqlite/android/build.gradle b/node_modules/@op-engineering/op-sqlite/android/build.gradle
index d36fd85..7513556 100644
index 7df016d..dc94a38 100644
--- a/node_modules/@op-engineering/op-sqlite/android/build.gradle
+++ b/node_modules/@op-engineering/op-sqlite/android/build.gradle
@@ -1,5 +1,4 @@
Expand Down Expand Up @@ -69,7 +69,7 @@ index d36fd85..7513556 100644
println "[OP-SQLITE] using sqlcipher."
} else if(useLibsql) {
diff --git a/node_modules/@op-engineering/op-sqlite/android/cpp-adapter.cpp b/node_modules/@op-engineering/op-sqlite/android/cpp-adapter.cpp
index 8feaf77..261ec22 100644
index 5912d7b..f2cb85b 100644
--- a/node_modules/@op-engineering/op-sqlite/android/cpp-adapter.cpp
+++ b/node_modules/@op-engineering/op-sqlite/android/cpp-adapter.cpp
@@ -19,8 +19,8 @@ struct OPSQLiteBridge : jni::JavaClass<OPSQLiteBridge> {
Expand All @@ -79,7 +79,7 @@ index 8feaf77..261ec22 100644
- makeNativeMethod("clearStateNativeJsi",
- OPSQLiteBridge::clearStateNativeJsi)});
+ makeNativeMethod("clearStateNativeJsi", OPSQLiteBridge::clearStateNativeJsi),
+ makeNativeMethod("deleteAllDBsJsi", OPSQLiteBridge::deleteAllDBsJsi)});
+ makeNativeMethod("deleteAllDBsJsi", OPSQLiteBridge::deleteAllDBsJsi)});
}

private:
Expand All @@ -89,7 +89,7 @@ index 8feaf77..261ec22 100644
}
+
+ static bool deleteAllDBsJsi(jni::alias_ref<jni::JObject> thiz) {
+ return opsqlite::deleteAllDbs();
+ return opsqlite::deleteAllDbs();
+ }
};

Expand Down Expand Up @@ -118,20 +118,20 @@ index 44f86df..9d9f710 100644
val instance = OPSQLiteBridge()
}
diff --git a/node_modules/@op-engineering/op-sqlite/android/src/main/java/com/op/sqlite/OPSQLiteModule.kt b/node_modules/@op-engineering/op-sqlite/android/src/main/java/com/op/sqlite/OPSQLiteModule.kt
index 688832f..9ea814b 100644
index 49a01b9..bdfa829 100644
--- a/node_modules/@op-engineering/op-sqlite/android/src/main/java/com/op/sqlite/OPSQLiteModule.kt
+++ b/node_modules/@op-engineering/op-sqlite/android/src/main/java/com/op/sqlite/OPSQLiteModule.kt
@@ -13,7 +13,7 @@ import java.io.OutputStream
@@ -12,7 +12,7 @@ import java.io.InputStream
import java.io.OutputStream
import com.facebook.react.util.RNLog;

//@ReactModule(name = OPSQLiteModule.NAME)
-internal class OPSQLiteModule(context: ReactApplicationContext?) : ReactContextBaseJavaModule(context) {
+class OPSQLiteModule(context: ReactApplicationContext?) : ReactContextBaseJavaModule(context) {
override fun getName(): String {
return NAME
}
@@ -56,6 +56,17 @@ internal class OPSQLiteModule(context: ReactApplicationContext?) : ReactContextB
return true
@@ -54,6 +54,16 @@ internal class OPSQLiteModule(context: ReactApplicationContext?) : ReactContextB
throw Exception("Do not call getDylibPath on Android")
}

+ @ReactMethod(isBlockingSynchronousMethod = true)
Expand All @@ -143,16 +143,15 @@ index 688832f..9ea814b 100644
+ fun deleteAllDBs() {
+ OPSQLiteBridge.instance.deleteAllDBs();
+ }
+
+
@ReactMethod
fun moveAssetsDatabase(args: ReadableMap, promise: Promise) {
val filename = args.getString("filename")!!
diff --git a/node_modules/@op-engineering/op-sqlite/cpp/DBHostObject.cpp b/node_modules/@op-engineering/op-sqlite/cpp/DBHostObject.cpp
index 85710ee..8cf10f2 100644
index eadea09..5701d15 100644
--- a/node_modules/@op-engineering/op-sqlite/cpp/DBHostObject.cpp
+++ b/node_modules/@op-engineering/op-sqlite/cpp/DBHostObject.cpp
@@ -889,6 +889,10 @@ void DBHostObject::invalidate() {
@@ -675,6 +675,10 @@ void DBHostObject::invalidate() {
#endif
}

Expand All @@ -164,23 +163,23 @@ index 85710ee..8cf10f2 100644

} // namespace opsqlite
diff --git a/node_modules/@op-engineering/op-sqlite/cpp/DBHostObject.h b/node_modules/@op-engineering/op-sqlite/cpp/DBHostObject.h
index cc174b7..ff36f74 100644
index 68a9bc4..142e9d9 100644
--- a/node_modules/@op-engineering/op-sqlite/cpp/DBHostObject.h
+++ b/node_modules/@op-engineering/op-sqlite/cpp/DBHostObject.h
@@ -73,6 +73,7 @@ class JSI_EXPORT DBHostObject : public jsi::HostObject {
void on_commit();
void on_rollback();
void invalidate();
+ void drop();
~DBHostObject() override;
@@ -68,6 +68,7 @@ public:
void on_commit();
void on_rollback();
void invalidate();
+ void drop();
~DBHostObject() override;

private:
diff --git a/node_modules/@op-engineering/op-sqlite/cpp/bindings.cpp b/node_modules/@op-engineering/op-sqlite/cpp/bindings.cpp
index 5e1c1de..dc21c65 100644
--- a/node_modules/@op-engineering/op-sqlite/cpp/bindings.cpp
+++ b/node_modules/@op-engineering/op-sqlite/cpp/bindings.cpp
@@ -36,6 +36,13 @@ void invalidate() {
dbs.clear();
private:
diff --git a/node_modules/@op-engineering/op-sqlite/cpp/OPSqlite.cpp b/node_modules/@op-engineering/op-sqlite/cpp/OPSqlite.cpp
index e33579a..791fa70 100644
--- a/node_modules/@op-engineering/op-sqlite/cpp/OPSqlite.cpp
+++ b/node_modules/@op-engineering/op-sqlite/cpp/OPSqlite.cpp
@@ -42,6 +42,13 @@ void invalidate() {
dbs.clear();
}

+bool deleteAllDbs() {
Expand All @@ -191,12 +190,12 @@ index 5e1c1de..dc21c65 100644
+}
+
void install(jsi::Runtime &rt,
const std::shared_ptr<react::CallInvoker> &invoker,
const std::shared_ptr<react::CallInvoker> &_invoker,
const char *base_path, const char *crsqlite_path,
diff --git a/node_modules/@op-engineering/op-sqlite/cpp/bindings.h b/node_modules/@op-engineering/op-sqlite/cpp/bindings.h
diff --git a/node_modules/@op-engineering/op-sqlite/cpp/OPSqlite.hpp b/node_modules/@op-engineering/op-sqlite/cpp/OPSqlite.hpp
index 91511ab..cc73dfe 100644
--- a/node_modules/@op-engineering/op-sqlite/cpp/bindings.h
+++ b/node_modules/@op-engineering/op-sqlite/cpp/bindings.h
--- a/node_modules/@op-engineering/op-sqlite/cpp/OPSqlite.hpp
+++ b/node_modules/@op-engineering/op-sqlite/cpp/OPSqlite.hpp
@@ -14,6 +14,7 @@ void install(jsi::Runtime &rt,
const char *base_path, const char *crsqlite_path,
const char *sqlite_vec_path);
Expand All @@ -206,18 +205,33 @@ index 91511ab..cc73dfe 100644

} // namespace opsqlite
diff --git a/node_modules/@op-engineering/op-sqlite/op-sqlite.podspec b/node_modules/@op-engineering/op-sqlite/op-sqlite.podspec
index 375cc3e..e6fce21 100644
index 32906a2..4a1e452 100644
--- a/node_modules/@op-engineering/op-sqlite/op-sqlite.podspec
+++ b/node_modules/@op-engineering/op-sqlite/op-sqlite.podspec
@@ -1,4 +1,3 @@
@@ -1,12 +1,13 @@
-require "json"
require_relative "./generate_tokenizers_header_file"

log_message = lambda do |message|
@@ -39,11 +38,10 @@ else
app_package = JSON.parse(File.read(File.join(__dir__, "example", "package.json")))
puts "\e[34m#{message}\e[0m"
end

+# NOTE: Disabled as redundant for now, re-enable if needed
# In the sample app the dir is not inside of node_modules
-is_user_app = __dir__.include?("node_modules")
+# is_user_app = __dir__.include?("node_modules")
+is_user_app = false
package = JSON.parse(File.read(File.join(__dir__, "package.json")))
app_package = nil
package_json_path = nil
@@ -32,13 +33,13 @@ else
package_json_path = File.join(__dir__, "example", "package.json")
end

-app_package = JSON.parse(File.read(package_json_path))
+# NOTE: Disabled as redundant for now, re-enable if needed
+# app_package = JSON.parse(File.read(package_json_path))

-op_sqlite_config = app_package["op-sqlite"]
-use_sqlcipher = false
+use_sqlcipher = true
Expand All @@ -228,7 +242,7 @@ index 375cc3e..e6fce21 100644
phone_version = false
sqlite_flags = ""
fts5 = false
@@ -51,37 +49,6 @@ rtree = false
@@ -46,37 +47,6 @@ rtree = false
use_sqlite_vec = false
tokenizers = []

Expand All @@ -247,19 +261,19 @@ index 375cc3e..e6fce21 100644
-
-if phone_version then
- if use_sqlcipher then
- raise "SQLCipher is not supported with phone version"
- raise "SQLCipher is not supported with phone version. It cannot load extensions."
- end
-
- if use_crsqlite then
- raise "CRSQLite is not supported with phone version"
- raise "CRSQLite is not supported with phone version. It cannot load extensions."
- end
-
- if rtree then
- raise "RTree is not supported with phone version"
- raise "RTree is not supported with phone version. It cannot load extensions."
- end
-
- if use_sqlite_vec then
- raise "SQLite Vec is not supported with phone version"
- raise "SQLite Vec is not supported with phone version. It cannot load extensions."
- end
-end
-
Expand Down