Comments (6)
I also had to import com.facebook.react.bridge.JSIModulePackage;
in MainApplication.java to make it work on android
from react-native-mmkv.
I believe this works with v1.2.5 now, let me know if anyone can confirm
from react-native-mmkv.
2021-08-20 16:15:15.292 31642-31690/com.testapp D/SoLoader: Not resolving dependencies for libjscexecutor.so
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: java.lang.UnsatisfiedLinkError: dlopen failed: library "libjsc.so" not found
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at java.lang.Runtime.load0(Runtime.java:938)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at java.lang.System.load(System.java:1631)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.facebook.soloader.SoLoader$1.load(SoLoader.java:405)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.facebook.soloader.DirectorySoSource.loadLibraryFrom(DirectorySoSource.java:77)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.facebook.soloader.DirectorySoSource.loadLibrary(DirectorySoSource.java:50)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.facebook.soloader.ApplicationSoSource.loadLibrary(ApplicationSoSource.java:89)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.facebook.soloader.SoLoader.doLoadLibraryBySoName(SoLoader.java:860)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.facebook.soloader.SoLoader.loadLibraryBySoNameImpl(SoLoader.java:740)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.facebook.soloader.SoLoader.loadLibraryBySoName(SoLoader.java:654)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.facebook.soloader.SoLoader.loadLibrary(SoLoader.java:634)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.facebook.soloader.SoLoader.loadLibrary(SoLoader.java:582)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.swmansion.reanimated.NativeProxy.getDefaultJSExecutorFactory(NativeProxy.java:98)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.swmansion.reanimated.NativeProxy.<init>(NativeProxy.java:81)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.swmansion.reanimated.NodesManager.initWithContext(NodesManager.java:127)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.swmansion.reanimated.ReanimatedJSIModulePackage.getJSIModules(ReanimatedJSIModulePackage.java:18)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.testapp.MMKVJSIPackage.getJSIModules(MMKVJSIPackage.java:16)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.facebook.react.ReactInstanceManager.createReactContext(ReactInstanceManager.java:1265)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.facebook.react.ReactInstanceManager.access$1100(ReactInstanceManager.java:131)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at com.facebook.react.ReactInstanceManager$5.run(ReactInstanceManager.java:1023)
2021-08-20 16:15:15.294 31642-31690/com.testapp W/System.err: at java.lang.Thread.run(Thread.java:919)
2021-08-20 16:15:15.294 31642-31690/com.testapp E/SoLoader: couldn't find DSO to load: libjscexecutor.so caused by: dlopen failed: library "libjsc.so" not found result: 0
2021-08-20 16:15:15.296 31642-31690/com.testapp D/SoLoader: About to load: libturbomodulejsijni.so
2021-08-20 16:15:15.297 31642-31690/com.testapp D/SoLoader: libturbomodulejsijni.so not found on /data/data/com.testapp/lib-main
2021-08-20 16:15:15.297 31642-31690/com.testapp D/SoLoader: libturbomodulejsijni.so found on /data/app/com.testapp-6na_3ySNovN7Y7TsQ7pyLw==/lib/arm64
2021-08-20 16:15:15.297 31642-31690/com.testapp D/SoLoader: Not resolving dependencies for libturbomodulejsijni.so
2021-08-20 16:15:15.299 31642-31690/com.testapp D/SoLoader: Loaded: libturbomodulejsijni.so
2021-08-20 16:15:17.302 31642-31690/com.testapp I/ReactNativeJNI: Inspector::Inspector transitioning to initial state RunningDetached
2021-08-20 16:15:17.305 31642-31690/com.testapp I/MMKV: <MMKV.cpp:156::initialize> version v1.2.7 page size:4096
2021-08-20 16:15:17.305 31642-31690/com.testapp I/MMKV: <MMKV.cpp:167::initialize> armv8 AES instructions is supported
2021-08-20 16:15:17.305 31642-31690/com.testapp I/MMKV: <MMKV.cpp:175::initialize> armv8 CRC32 instructions is supported
2021-08-20 16:15:17.305 31642-31690/com.testapp I/MMKV: <MMKV.cpp:198::initializeMMKV> root dir: /data/user/0/com.testapp/files/mmkv
2021-08-20 16:15:17.306 31642-31690/com.testapp A/libc: Fatal signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x2 in tid 31690 (create_react_co), pid 31642 (onvergeagentapp)
2021-08-20 16:15:18.575 31642-31642/com.testapp W/ActivityThread: SCHED: com.testapp/.MainActivity [74, r=186ms, a=63ms, w=6242ms]
from react-native-mmkv.
MMKVJSIPackage.java
package com.testapp;
import com.facebook.react.bridge.JSIModuleSpec;
import com.facebook.react.bridge.JavaScriptContextHolder;
import com.facebook.react.bridge.ReactApplicationContext;
import com.swmansion.reanimated.ReanimatedJSIModulePackage;
import com.facebook.react.bridge.JSIModulePackage;
import com.reactnativemmkv.MmkvModule;
import java.util.Collections;
import java.util.List;
public class MMKVJSIPackage extends ReanimatedJSIModulePackage {
@Override
public List<JSIModuleSpec> getJSIModules(ReactApplicationContext reactApplicationContext, JavaScriptContextHolder jsContext) {
super.getJSIModules(reactApplicationContext, jsContext);
MmkvModule.install(jsContext, reactApplicationContext.getFilesDir().getAbsolutePath() + "/mmkv");
return Collections.emptyList();
}
}
from react-native-mmkv.
im using sir the latest version "react-native-mmkv": "^1.2.5",
from react-native-mmkv.
This should work with 1.3.0 and above, so you can revert those two steps mentioned in my original comment. Let me know if you are still having issues autolinking MMKV.
from react-native-mmkv.
Related Issues (20)
- "Required key not available" This log is displayed when the system has just started. HOT 1
- new support for react native 0.73 ? HOT 5
- Does the storage work on native Android and IOS, after bundling the RN application
- [Question] Why is it recommended to re-use the same instance throughout the entire app? HOT 2
- Unclear docs regarding encryption HOT 5
- How to change AsyncStorage with MMKV in redux persist HOT 2
- QUESTION: Explain working when react-native new architecture is NOT enabled in my app HOT 2
- "setState" from `useMMKV<Type>` hooks does not behave 100% correctly with function parameter
- Issue with Reactotron and MMKV Plugin HOT 2
- Configure project :react-native-mmkv HOT 3
- app:compileReleaseJavaWithJavac FAILED HOT 2
- library "libreactnativemmkv.so" not found, js engine: hermes HOT 1
- Build Failed FAILED: build.ninja HOT 1
- "React Native is not running on device" prevents me from running the app HOT 6
- getBoolean returns undefined HOT 1
- Android: Build Error
- Feature: get keys with prefix HOT 3
- .
- react-native-mmkv is not supported in Expo Go!
- The enableKeyExpire function and the expireDuration parameter are missing HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react-native-mmkv.