Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Load Required Libraries in ReactBridge's static init #910

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
@@ -0,0 +1,28 @@
--- a/ReactAndroid/src/main/java/com/facebook/react/bridge/ReactBridge.java
+++ b/ReactAndroid/src/main/java/com/facebook/react/bridge/ReactBridge.java
@@ -31,6 +31,25 @@ public class ReactBridge {
Systrace.beginSection(
TRACE_TAG_REACT_JAVA_BRIDGE, "ReactBridge.staticInit::load:reactnativejni");
ReactMarker.logMarker(ReactMarkerConstants.LOAD_REACT_NATIVE_SO_FILE_START);
+
+ // JS Engine is configurable.. And we exepct only one packaged
+ // Hence ignore failure
+ try {
+ SoLoader.loadLibrary("hermes");
+ }catch (UnsatisfiedLinkError jscE){}
+
+ try {
+ SoLoader.loadLibrary("v8jsi");
+ }catch (UnsatisfiedLinkError jscE){}
+
+ SoLoader.loadLibrary("glog");
+ SoLoader.loadLibrary("glog_init");
+ SoLoader.loadLibrary("fb");
+ SoLoader.loadLibrary("fbjni");
+ SoLoader.loadLibrary("yoga");
+ SoLoader.loadLibrary("folly_json");
+ SoLoader.loadLibrary("reactperfloggerjni");
+ SoLoader.loadLibrary("jsinspector");
SoLoader.loadLibrary("reactnativejni");
msgharpu marked this conversation as resolved.
Show resolved Hide resolved
ReactMarker.logMarker(ReactMarkerConstants.LOAD_REACT_NATIVE_SO_FILE_END);
Systrace.endSection(TRACE_TAG_REACT_JAVA_BRIDGE);