react-native 0.71.0-rc.2 → 0.71.0-rc.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Libraries/Core/ReactNativeVersion.js +1 -1
- package/Libraries/Image/ImageSource.js +0 -2
- package/Libraries/PermissionsAndroid/PermissionsAndroid.js +4 -2
- package/React/Base/RCTVersion.m +1 -1
- package/React/CxxBridge/JSCExecutorFactory.mm +1 -1
- package/ReactAndroid/build.gradle +66 -23
- package/ReactAndroid/gradle.properties +1 -1
- package/ReactAndroid/src/main/java/com/facebook/hermes/reactexecutor/BUCK +1 -0
- package/ReactAndroid/src/main/java/com/facebook/hermes/reactexecutor/HermesExecutor.java +5 -4
- package/ReactAndroid/src/main/java/com/facebook/react/modules/systeminfo/ReactNativeVersion.java +1 -1
- package/ReactAndroid/src/main/jni/CMakeLists.txt +1 -0
- package/ReactAndroid/src/main/jni/react/hermes/reactexecutor/BUCK +1 -1
- package/ReactAndroid/src/main/jni/react/hermes/reactexecutor/CMakeLists.txt +5 -14
- package/ReactAndroid/src/main/jni/react/jscexecutor/BUCK +1 -1
- package/ReactAndroid/src/main/jni/react/jscexecutor/OnLoad.cpp +1 -1
- package/ReactCommon/React-Fabric.podspec +0 -2
- package/ReactCommon/ReactCommon.podspec +4 -1
- package/ReactCommon/cxxreact/ReactNativeVersion.h +1 -1
- package/ReactCommon/hermes/React-hermes.podspec +0 -1
- package/ReactCommon/hermes/executor/CMakeLists.txt +6 -5
- package/ReactCommon/hermes/inspector/CMakeLists.txt +4 -4
- package/ReactCommon/jsc/.clang-tidy +6 -0
- package/ReactCommon/jsc/BUCK +34 -0
- package/ReactCommon/jsc/CMakeLists.txt +35 -0
- package/ReactCommon/{jsi → jsc}/JSCRuntime.cpp +0 -0
- package/ReactCommon/{jsi → jsc}/JSCRuntime.h +0 -0
- package/ReactCommon/{jsi → jsc}/React-jsc.podspec +1 -5
- package/ReactCommon/jsi/BUCK +1 -31
- package/ReactCommon/jsi/CMakeLists.txt +0 -16
- package/ReactCommon/jsi/React-jsi.podspec +16 -3
- package/ReactCommon/jsiexecutor/React-jsiexecutor.podspec +0 -1
- package/ReactCommon/react/bridging/CallbackWrapper.h +1 -1
- package/ReactCommon/react/nativemodule/core/ReactCommon/CallbackWrapper.h +11 -0
- package/ReactCommon/react/nativemodule/core/ReactCommon/TurboModuleUtils.h +1 -2
- package/android/README.md +21 -0
- package/jest/react-native-env.js +3 -1
- package/package.json +11 -11
- package/react.gradle +2 -2
- package/scripts/cocoapods/jsengine.rb +4 -4
- package/scripts/hermes/prepare-hermes-for-build.js +1 -1
- package/scripts/react_native_pods.rb +1 -1
- package/scripts/react_native_pods_utils/script_phases.sh +10 -12
- package/sdks/.hermesversion +1 -1
- package/sdks/hermes-engine/hermes-engine.podspec +1 -1
- package/sdks/hermesc/osx-bin/hermesc +0 -0
- package/sdks/hermesc/win64-bin/hermesc.exe +0 -0
- package/template/_eslintrc.js +1 -3
- package/template/android/build.gradle +1 -1
- package/template/ios/Podfile +7 -1
- package/template/package.json +2 -4
- package/types/public/ReactNativeTypes.d.ts +4 -2
- package/ReactCommon/jsi/React-jsidynamic.podspec +0 -42
|
@@ -75,7 +75,8 @@ const PERMISSIONS = Object.freeze({
|
|
|
75
75
|
ANSWER_PHONE_CALLS: 'android.permission.ANSWER_PHONE_CALLS',
|
|
76
76
|
READ_PHONE_NUMBERS: 'android.permission.READ_PHONE_NUMBERS',
|
|
77
77
|
UWB_RANGING: 'android.permission.UWB_RANGING',
|
|
78
|
-
POST_NOTIFICATION: 'android.permission.POST_NOTIFICATIONS',
|
|
78
|
+
POST_NOTIFICATION: 'android.permission.POST_NOTIFICATIONS', // Remove in 0.72
|
|
79
|
+
POST_NOTIFICATIONS: 'android.permission.POST_NOTIFICATIONS',
|
|
79
80
|
NEARBY_WIFI_DEVICES: 'android.permission.NEARBY_WIFI_DEVICES',
|
|
80
81
|
});
|
|
81
82
|
|
|
@@ -106,7 +107,8 @@ class PermissionsAndroid {
|
|
|
106
107
|
CAMERA: string,
|
|
107
108
|
GET_ACCOUNTS: string,
|
|
108
109
|
NEARBY_WIFI_DEVICES: string,
|
|
109
|
-
POST_NOTIFICATION: string,
|
|
110
|
+
POST_NOTIFICATION: string, // Remove in 0.72
|
|
111
|
+
POST_NOTIFICATIONS: string,
|
|
110
112
|
PROCESS_OUTGOING_CALLS: string,
|
|
111
113
|
READ_CALENDAR: string,
|
|
112
114
|
READ_CALL_LOG: string,
|
package/React/Base/RCTVersion.m
CHANGED
|
@@ -117,7 +117,10 @@ final def preparePrefab = tasks.register("preparePrefab", PreparePrefabHeadersTa
|
|
|
117
117
|
),
|
|
118
118
|
new PrefabPreprocessingEntry(
|
|
119
119
|
"fabricjni",
|
|
120
|
-
|
|
120
|
+
[
|
|
121
|
+
new Pair("src/main/jni/react/fabric", ""),
|
|
122
|
+
new Pair("src/main/jni/react/cxxcomponents", "react/cxxcomponents/")
|
|
123
|
+
]
|
|
121
124
|
),
|
|
122
125
|
new PrefabPreprocessingEntry(
|
|
123
126
|
"react_render_mapbuffer",
|
|
@@ -144,6 +147,7 @@ final def preparePrefab = tasks.register("preparePrefab", PreparePrefabHeadersTa
|
|
|
144
147
|
new Pair(new File(buildDir, "third-party-ndk/boost/boost_1_76_0/").absolutePath, ""),
|
|
145
148
|
new Pair(new File(buildDir, "third-party-ndk/double-conversion/").absolutePath, ""),
|
|
146
149
|
new Pair(new File(buildDir, "third-party-ndk/folly/").absolutePath, ""),
|
|
150
|
+
new Pair(new File(buildDir, "third-party-ndk/glog/exported/").absolutePath, ""),
|
|
147
151
|
new Pair("../ReactCommon/butter/", "butter/"),
|
|
148
152
|
new Pair("../ReactCommon/callinvoker/", ""),
|
|
149
153
|
new Pair("../ReactCommon/react/bridging/", "react/bridging/"),
|
|
@@ -152,6 +156,8 @@ final def preparePrefab = tasks.register("preparePrefab", PreparePrefabHeadersTa
|
|
|
152
156
|
new Pair("../ReactCommon/react/nativemodule/core/platform/android/", ""),
|
|
153
157
|
new Pair("../ReactCommon/react/renderer/componentregistry/", "react/renderer/componentregistry/"),
|
|
154
158
|
new Pair("../ReactCommon/react/renderer/components/root/", "react/renderer/components/root/"),
|
|
159
|
+
new Pair("../ReactCommon/react/renderer/core/", "react/renderer/core/"),
|
|
160
|
+
new Pair("../ReactCommon/react/renderer/debug/", "react/renderer/debug/"),
|
|
155
161
|
new Pair("../ReactCommon/react/renderer/leakchecker/", "react/renderer/leakchecker/"),
|
|
156
162
|
new Pair("../ReactCommon/react/renderer/mapbuffer/", "react/renderer/mapbuffer/"),
|
|
157
163
|
new Pair("../ReactCommon/react/renderer/mounting/", "react/renderer/mounting/"),
|
|
@@ -159,6 +165,7 @@ final def preparePrefab = tasks.register("preparePrefab", PreparePrefabHeadersTa
|
|
|
159
165
|
new Pair("../ReactCommon/react/renderer/scheduler/", "react/renderer/scheduler/"),
|
|
160
166
|
new Pair("../ReactCommon/react/renderer/telemetry/", "react/renderer/telemetry/"),
|
|
161
167
|
new Pair("../ReactCommon/react/renderer/uimanager/", "react/renderer/uimanager/"),
|
|
168
|
+
new Pair("../ReactCommon/react/debug/", "react/debug/"),
|
|
162
169
|
new Pair("../ReactCommon/react/utils/", "react/utils/"),
|
|
163
170
|
new Pair("src/main/jni/react/jni", "react/jni/"),
|
|
164
171
|
]
|
|
@@ -174,6 +181,38 @@ final def preparePrefab = tasks.register("preparePrefab", PreparePrefabHeadersTa
|
|
|
174
181
|
"rrc_image",
|
|
175
182
|
new Pair("../ReactCommon/react/renderer/components/image/", "react/renderer/components/image/")
|
|
176
183
|
),
|
|
184
|
+
// These prefab targets are used by Expo & Reanimated
|
|
185
|
+
new PrefabPreprocessingEntry(
|
|
186
|
+
"hermes_executor",
|
|
187
|
+
// "hermes_executor" is statically linking against "hermes_executor_common"
|
|
188
|
+
// and "hermes_inspector". Here we expose only the headers that we know are needed.
|
|
189
|
+
new Pair("../ReactCommon/hermes/inspector/", "hermes/inspector/")
|
|
190
|
+
),
|
|
191
|
+
new PrefabPreprocessingEntry(
|
|
192
|
+
"jscexecutor",
|
|
193
|
+
// "jscexecutor" is statically linking against "jscruntime"
|
|
194
|
+
// Here we expose only the headers that we know are needed.
|
|
195
|
+
new Pair("../ReactCommon/jsc/", "jsc/")
|
|
196
|
+
),
|
|
197
|
+
new PrefabPreprocessingEntry(
|
|
198
|
+
"react_render_uimanager",
|
|
199
|
+
new Pair("../ReactCommon/react/renderer/uimanager/", "react/renderer/uimanager/"),
|
|
200
|
+
),
|
|
201
|
+
new PrefabPreprocessingEntry(
|
|
202
|
+
"react_render_scheduler",
|
|
203
|
+
new Pair("../ReactCommon/react/renderer/scheduler/", "react/renderer/scheduler/"),
|
|
204
|
+
),
|
|
205
|
+
new PrefabPreprocessingEntry(
|
|
206
|
+
"react_render_mounting",
|
|
207
|
+
new Pair("../ReactCommon/react/renderer/mounting/", "react/renderer/mounting/"),
|
|
208
|
+
),
|
|
209
|
+
new PrefabPreprocessingEntry(
|
|
210
|
+
"reactnativejni",
|
|
211
|
+
[
|
|
212
|
+
new Pair("src/main/jni/react/jni", "react/jni/"),
|
|
213
|
+
new Pair("../ReactCommon/cxxreact/", "cxxreact/"),
|
|
214
|
+
]
|
|
215
|
+
),
|
|
177
216
|
]
|
|
178
217
|
)
|
|
179
218
|
it.outputDir.set(prefabHeadersDir)
|
|
@@ -402,12 +441,11 @@ android {
|
|
|
402
441
|
"-DANDROID_TOOLCHAIN=clang",
|
|
403
442
|
"-DANDROID_PLATFORM=android-21"
|
|
404
443
|
|
|
405
|
-
targets "
|
|
406
|
-
"jscexecutor",
|
|
407
|
-
"jsijniprofiler",
|
|
444
|
+
targets "jsijniprofiler",
|
|
408
445
|
"reactnativeblob",
|
|
409
446
|
"reactperfloggerjni",
|
|
410
447
|
// prefab targets
|
|
448
|
+
"reactnativejni",
|
|
411
449
|
"react_render_debug",
|
|
412
450
|
"turbomodulejsijni",
|
|
413
451
|
"runtimeexecutor",
|
|
@@ -426,7 +464,12 @@ android {
|
|
|
426
464
|
"yoga",
|
|
427
465
|
"folly_runtime",
|
|
428
466
|
"react_nativemodule_core",
|
|
429
|
-
"react_render_imagemanager"
|
|
467
|
+
"react_render_imagemanager",
|
|
468
|
+
"react_render_uimanager",
|
|
469
|
+
"react_render_scheduler",
|
|
470
|
+
"react_render_mounting",
|
|
471
|
+
"hermes_executor",
|
|
472
|
+
"jscexecutor"
|
|
430
473
|
}
|
|
431
474
|
}
|
|
432
475
|
ndk {
|
|
@@ -434,24 +477,6 @@ android {
|
|
|
434
477
|
}
|
|
435
478
|
}
|
|
436
479
|
|
|
437
|
-
buildTypes {
|
|
438
|
-
debug {
|
|
439
|
-
externalNativeBuild {
|
|
440
|
-
cmake {
|
|
441
|
-
targets "hermes-executor-debug"
|
|
442
|
-
}
|
|
443
|
-
}
|
|
444
|
-
}
|
|
445
|
-
|
|
446
|
-
release {
|
|
447
|
-
externalNativeBuild {
|
|
448
|
-
cmake {
|
|
449
|
-
targets "hermes-executor-release"
|
|
450
|
-
}
|
|
451
|
-
}
|
|
452
|
-
}
|
|
453
|
-
}
|
|
454
|
-
|
|
455
480
|
externalNativeBuild {
|
|
456
481
|
cmake {
|
|
457
482
|
path "src/main/jni/CMakeLists.txt"
|
|
@@ -549,6 +574,24 @@ android {
|
|
|
549
574
|
react_render_imagemanager {
|
|
550
575
|
headers(new File(prefabHeadersDir, "react_render_imagemanager").absolutePath)
|
|
551
576
|
}
|
|
577
|
+
react_render_uimanager {
|
|
578
|
+
headers(new File(prefabHeadersDir, "react_render_uimanager").absolutePath)
|
|
579
|
+
}
|
|
580
|
+
react_render_scheduler {
|
|
581
|
+
headers(new File(prefabHeadersDir, "react_render_scheduler").absolutePath)
|
|
582
|
+
}
|
|
583
|
+
react_render_mounting {
|
|
584
|
+
headers(new File(prefabHeadersDir, "react_render_mounting").absolutePath)
|
|
585
|
+
}
|
|
586
|
+
reactnativejni {
|
|
587
|
+
headers(new File(prefabHeadersDir, "reactnativejni").absolutePath)
|
|
588
|
+
}
|
|
589
|
+
hermes_executor {
|
|
590
|
+
headers(new File(prefabHeadersDir, "hermes_executor").absolutePath)
|
|
591
|
+
}
|
|
592
|
+
jscexecutor {
|
|
593
|
+
headers(new File(prefabHeadersDir, "jscexecutor").absolutePath)
|
|
594
|
+
}
|
|
552
595
|
}
|
|
553
596
|
|
|
554
597
|
publishing {
|
|
@@ -17,6 +17,7 @@ rn_android_library(
|
|
|
17
17
|
react_native_target("java/com/facebook/hermes/instrumentation:instrumentation"),
|
|
18
18
|
react_native_target("java/com/facebook/hermes/instrumentation:hermes_samplingprofiler"),
|
|
19
19
|
react_native_target("java/com/facebook/react/bridge:bridge"),
|
|
20
|
+
react_native_target("java/com/facebook/react/common:common"),
|
|
20
21
|
react_native_target("jni/react/hermes/reactexecutor:jni"),
|
|
21
22
|
":runtimeconfig",
|
|
22
23
|
],
|
|
@@ -9,6 +9,7 @@ package com.facebook.hermes.reactexecutor;
|
|
|
9
9
|
|
|
10
10
|
import com.facebook.jni.HybridData;
|
|
11
11
|
import com.facebook.react.bridge.JavaScriptExecutor;
|
|
12
|
+
import com.facebook.react.common.build.ReactBuildConfig;
|
|
12
13
|
import com.facebook.soloader.SoLoader;
|
|
13
14
|
import javax.annotation.Nullable;
|
|
14
15
|
|
|
@@ -23,11 +24,11 @@ public class HermesExecutor extends JavaScriptExecutor {
|
|
|
23
24
|
if (mode_ == null) {
|
|
24
25
|
// libhermes must be loaded explicitly to invoke its JNI_OnLoad.
|
|
25
26
|
SoLoader.loadLibrary("hermes");
|
|
26
|
-
|
|
27
|
-
|
|
27
|
+
SoLoader.loadLibrary("hermes_executor");
|
|
28
|
+
// libhermes_executor is built differently for Debug & Release so we load the proper mode.
|
|
29
|
+
if (ReactBuildConfig.DEBUG == true) {
|
|
28
30
|
mode_ = "Debug";
|
|
29
|
-
}
|
|
30
|
-
SoLoader.loadLibrary("hermes-executor-release");
|
|
31
|
+
} else {
|
|
31
32
|
mode_ = "Release";
|
|
32
33
|
}
|
|
33
34
|
}
|
|
@@ -56,6 +56,7 @@ add_react_common_subdir(reactperflogger)
|
|
|
56
56
|
add_react_common_subdir(logger)
|
|
57
57
|
add_react_common_subdir(jsiexecutor)
|
|
58
58
|
add_react_common_subdir(cxxreact)
|
|
59
|
+
add_react_common_subdir(jsc)
|
|
59
60
|
add_react_common_subdir(jsi)
|
|
60
61
|
add_react_common_subdir(butter)
|
|
61
62
|
add_react_common_subdir(callinvoker)
|
|
@@ -8,29 +8,20 @@ set(CMAKE_VERBOSE_MAKEFILE on)
|
|
|
8
8
|
|
|
9
9
|
file(GLOB_RECURSE hermes_executor_SRC CONFIGURE_DEPENDS *.cpp)
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
set(HERMES_TARGET_SUFFIX debug)
|
|
13
|
-
else()
|
|
14
|
-
set(HERMES_TARGET_SUFFIX release)
|
|
15
|
-
endif()
|
|
16
|
-
|
|
17
|
-
set(HERMES_TARGET_NAME hermes-executor-${HERMES_TARGET_SUFFIX})
|
|
18
|
-
|
|
19
|
-
add_library(
|
|
20
|
-
${HERMES_TARGET_NAME}
|
|
11
|
+
add_library(hermes_executor
|
|
21
12
|
SHARED
|
|
22
13
|
${hermes_executor_SRC}
|
|
23
14
|
)
|
|
24
15
|
target_compile_options(
|
|
25
|
-
|
|
16
|
+
hermes_executor
|
|
26
17
|
PRIVATE
|
|
27
18
|
$<$<CONFIG:Debug>:-DHERMES_ENABLE_DEBUGGER=1>
|
|
28
19
|
-fexceptions
|
|
29
20
|
)
|
|
30
|
-
target_include_directories(
|
|
21
|
+
target_include_directories(hermes_executor PRIVATE .)
|
|
31
22
|
target_link_libraries(
|
|
32
|
-
|
|
33
|
-
|
|
23
|
+
hermes_executor
|
|
24
|
+
hermes_executor_common
|
|
34
25
|
jsireact
|
|
35
26
|
fb
|
|
36
27
|
fbjni
|
|
@@ -78,7 +78,6 @@ Pod::Spec.new do |s|
|
|
|
78
78
|
|
|
79
79
|
s.subspec "core" do |ss|
|
|
80
80
|
ss.dependency folly_dep_name, folly_version
|
|
81
|
-
ss.dependency "React-jsidynamic", version
|
|
82
81
|
ss.compiler_flags = folly_compiler_flags + ' ' + boost_compiler_flags
|
|
83
82
|
ss.source_files = "react/renderer/core/**/*.{m,mm,cpp,h}"
|
|
84
83
|
ss.exclude_files = "react/renderer/core/tests"
|
|
@@ -303,7 +302,6 @@ Pod::Spec.new do |s|
|
|
|
303
302
|
|
|
304
303
|
s.subspec "uimanager" do |ss|
|
|
305
304
|
ss.dependency folly_dep_name, folly_version
|
|
306
|
-
ss.dependency "React-jsidynamic", version
|
|
307
305
|
ss.compiler_flags = folly_compiler_flags
|
|
308
306
|
ss.source_files = "react/renderer/uimanager/**/*.{m,mm,cpp,h}"
|
|
309
307
|
ss.exclude_files = "react/renderer/uimanager/tests"
|
|
@@ -61,7 +61,10 @@ Pod::Spec.new do |s|
|
|
|
61
61
|
ss.subspec "core" do |sss|
|
|
62
62
|
sss.source_files = "react/nativemodule/core/ReactCommon/**/*.{cpp,h}",
|
|
63
63
|
"react/nativemodule/core/platform/ios/**/*.{mm,cpp,h}"
|
|
64
|
-
|
|
64
|
+
excluded_files = ENV['USE_FRAMEWORKS'] == nil ?
|
|
65
|
+
"react/nativemodule/core/ReactCommon/LongLivedObject.h" :
|
|
66
|
+
"react/nativemodule/core/ReactCommon/{LongLivedObject,CallbackWrapper}.h"
|
|
67
|
+
sss.exclude_files = excluded_files
|
|
65
68
|
end
|
|
66
69
|
|
|
67
70
|
s.subspec "react_debug_core" do |sss|
|
|
@@ -44,7 +44,6 @@ Pod::Spec.new do |s|
|
|
|
44
44
|
}.merge!(build_type == :debug ? { "GCC_PREPROCESSOR_DEFINITIONS" => "HERMES_ENABLE_DEBUGGER=1" } : {})
|
|
45
45
|
s.header_dir = "reacthermes"
|
|
46
46
|
s.dependency "React-cxxreact", version
|
|
47
|
-
s.dependency "React-jsidynamic", version
|
|
48
47
|
s.dependency "React-jsiexecutor", version
|
|
49
48
|
s.dependency "React-jsinspector", version
|
|
50
49
|
s.dependency "React-perflogger", version
|
|
@@ -8,21 +8,22 @@ set(CMAKE_VERBOSE_MAKEFILE on)
|
|
|
8
8
|
|
|
9
9
|
file(GLOB_RECURSE hermes_executor_SRC CONFIGURE_DEPENDS *.cpp)
|
|
10
10
|
add_library(
|
|
11
|
-
|
|
11
|
+
hermes_executor_common
|
|
12
12
|
STATIC
|
|
13
13
|
${hermes_executor_SRC}
|
|
14
14
|
)
|
|
15
|
-
target_include_directories(
|
|
16
|
-
target_link_libraries(
|
|
15
|
+
target_include_directories(hermes_executor_common PUBLIC .)
|
|
16
|
+
target_link_libraries(hermes_executor_common
|
|
17
17
|
jsireact
|
|
18
18
|
hermes-engine::libhermes
|
|
19
19
|
jsi
|
|
20
|
-
debug
|
|
20
|
+
debug
|
|
21
|
+
hermes_inspector
|
|
21
22
|
)
|
|
22
23
|
|
|
23
24
|
if(${CMAKE_BUILD_TYPE} MATCHES Debug)
|
|
24
25
|
target_compile_options(
|
|
25
|
-
|
|
26
|
+
hermes_executor_common
|
|
26
27
|
PRIVATE
|
|
27
28
|
-DHERMES_ENABLE_DEBUGGER=1
|
|
28
29
|
)
|
|
@@ -8,20 +8,20 @@ set(CMAKE_VERBOSE_MAKEFILE on)
|
|
|
8
8
|
|
|
9
9
|
file(GLOB hermesinspector_SRC CONFIGURE_DEPENDS *.cpp detail/*.cpp chrome/*.cpp)
|
|
10
10
|
|
|
11
|
-
add_library(
|
|
11
|
+
add_library(hermes_inspector
|
|
12
12
|
STATIC
|
|
13
13
|
${hermesinspector_SRC})
|
|
14
14
|
|
|
15
15
|
target_compile_options(
|
|
16
|
-
|
|
16
|
+
hermes_inspector
|
|
17
17
|
PRIVATE
|
|
18
18
|
-DHERMES_ENABLE_DEBUGGER=1
|
|
19
19
|
-DHERMES_INSPECTOR_FOLLY_KLUDGE=1
|
|
20
20
|
-fexceptions
|
|
21
21
|
)
|
|
22
22
|
|
|
23
|
-
target_include_directories(
|
|
24
|
-
target_link_libraries(
|
|
23
|
+
target_include_directories(hermes_inspector PUBLIC ${REACT_COMMON_DIR})
|
|
24
|
+
target_link_libraries(hermes_inspector
|
|
25
25
|
jsinspector
|
|
26
26
|
fb
|
|
27
27
|
fbjni
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
load("//tools/build_defs/oss:rn_defs.bzl", "APPLE", "IOS", "MACOSX", "get_apple_compiler_flags", "get_apple_inspector_flags", "get_preprocessor_flags_for_build_mode", "react_native_xplat_dep", "rn_xplat_cxx_library")
|
|
2
|
+
|
|
3
|
+
APPLE_COMPILER_FLAGS = get_apple_compiler_flags()
|
|
4
|
+
|
|
5
|
+
rn_xplat_cxx_library(
|
|
6
|
+
name = "JSCRuntime",
|
|
7
|
+
srcs = [
|
|
8
|
+
"JSCRuntime.cpp",
|
|
9
|
+
],
|
|
10
|
+
header_namespace = "jsc",
|
|
11
|
+
exported_headers = [
|
|
12
|
+
"JSCRuntime.h",
|
|
13
|
+
],
|
|
14
|
+
apple_sdks = (IOS, MACOSX),
|
|
15
|
+
compiler_flags_pedantic = True,
|
|
16
|
+
fbobjc_compiler_flags = APPLE_COMPILER_FLAGS + [
|
|
17
|
+
"-Os",
|
|
18
|
+
],
|
|
19
|
+
fbobjc_frameworks = [
|
|
20
|
+
"$SDKROOT/System/Library/Frameworks/JavaScriptCore.framework",
|
|
21
|
+
],
|
|
22
|
+
fbobjc_preprocessor_flags = get_preprocessor_flags_for_build_mode() + get_apple_inspector_flags(),
|
|
23
|
+
labels = [
|
|
24
|
+
"pfh:ReactNative_CommonInfrastructurePlaceholder",
|
|
25
|
+
],
|
|
26
|
+
platforms = APPLE,
|
|
27
|
+
visibility = ["PUBLIC"],
|
|
28
|
+
xplat_mangled_args = {
|
|
29
|
+
"soname": "libjscjsi.$(ext)",
|
|
30
|
+
},
|
|
31
|
+
exported_deps = [
|
|
32
|
+
react_native_xplat_dep("jsi:jsi"),
|
|
33
|
+
],
|
|
34
|
+
)
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
2
|
+
#
|
|
3
|
+
# This source code is licensed under the MIT license found in the
|
|
4
|
+
# LICENSE file in the root directory of this source tree.
|
|
5
|
+
|
|
6
|
+
##################
|
|
7
|
+
### jscruntime ###
|
|
8
|
+
##################
|
|
9
|
+
|
|
10
|
+
cmake_minimum_required(VERSION 3.13)
|
|
11
|
+
set(CMAKE_VERBOSE_MAKEFILE on)
|
|
12
|
+
|
|
13
|
+
add_compile_options(
|
|
14
|
+
-fexceptions
|
|
15
|
+
-frtti
|
|
16
|
+
-O3
|
|
17
|
+
-Wno-unused-lambda-capture
|
|
18
|
+
-DLOG_TAG=\"ReactNative\")
|
|
19
|
+
|
|
20
|
+
add_library(jscruntime
|
|
21
|
+
STATIC
|
|
22
|
+
JSCRuntime.h
|
|
23
|
+
JSCRuntime.cpp)
|
|
24
|
+
|
|
25
|
+
target_include_directories(jscruntime PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
|
|
26
|
+
|
|
27
|
+
target_link_libraries(jscruntime
|
|
28
|
+
folly_runtime
|
|
29
|
+
jsc
|
|
30
|
+
jsi
|
|
31
|
+
glog)
|
|
32
|
+
|
|
33
|
+
# TODO: Remove this flag when ready.
|
|
34
|
+
# Android has this enabled by default, but the flag is still needed for iOS.
|
|
35
|
+
target_compile_options(jscruntime PRIVATE -DRN_FABRIC_ENABLED)
|
|
File without changes
|
|
File without changes
|
|
@@ -28,12 +28,8 @@ Pod::Spec.new do |s|
|
|
|
28
28
|
s.source_files = "JSCRuntime.{cpp,h}"
|
|
29
29
|
s.exclude_files = "**/test/*"
|
|
30
30
|
s.framework = "JavaScriptCore"
|
|
31
|
-
s.dependency "React-jsi", version
|
|
32
|
-
s.default_subspec = "Default"
|
|
33
31
|
|
|
34
|
-
s.
|
|
35
|
-
# no-op
|
|
36
|
-
end
|
|
32
|
+
s.dependency "React-jsi", version
|
|
37
33
|
|
|
38
34
|
s.subspec "Fabric" do |ss|
|
|
39
35
|
ss.pod_target_xcconfig = { "OTHER_CFLAGS" => "$(inherited) -DRN_FABRIC_ENABLED" }
|
package/ReactCommon/jsi/BUCK
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
load("//tools/build_defs/oss:rn_defs.bzl", "
|
|
1
|
+
load("//tools/build_defs/oss:rn_defs.bzl", "react_native_xplat_dep", "rn_xplat_cxx_library")
|
|
2
2
|
|
|
3
3
|
rn_xplat_cxx_library(
|
|
4
4
|
name = "jsi",
|
|
@@ -56,33 +56,3 @@ rn_xplat_cxx_library(
|
|
|
56
56
|
react_native_xplat_dep("jsi:jsi"),
|
|
57
57
|
],
|
|
58
58
|
)
|
|
59
|
-
|
|
60
|
-
rn_xplat_cxx_library(
|
|
61
|
-
name = "JSCRuntime",
|
|
62
|
-
srcs = [
|
|
63
|
-
"JSCRuntime.cpp",
|
|
64
|
-
],
|
|
65
|
-
header_namespace = "jsi",
|
|
66
|
-
exported_headers = [
|
|
67
|
-
"JSCRuntime.h",
|
|
68
|
-
],
|
|
69
|
-
apple_sdks = (IOS, MACOSX),
|
|
70
|
-
compiler_flags_pedantic = True,
|
|
71
|
-
fbobjc_compiler_flags = [
|
|
72
|
-
"-Os",
|
|
73
|
-
],
|
|
74
|
-
fbobjc_frameworks = [
|
|
75
|
-
"$SDKROOT/System/Library/Frameworks/JavaScriptCore.framework",
|
|
76
|
-
],
|
|
77
|
-
labels = [
|
|
78
|
-
"pfh:ReactNative_CommonInfrastructurePlaceholder",
|
|
79
|
-
],
|
|
80
|
-
platforms = APPLE,
|
|
81
|
-
visibility = ["PUBLIC"],
|
|
82
|
-
xplat_mangled_args = {
|
|
83
|
-
"soname": "libjscjsi.$(ext)",
|
|
84
|
-
},
|
|
85
|
-
exported_deps = [
|
|
86
|
-
react_native_xplat_dep("jsi:jsi"),
|
|
87
|
-
],
|
|
88
|
-
)
|
|
@@ -25,19 +25,3 @@ target_include_directories(jsi PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
|
|
|
25
25
|
target_link_libraries(jsi
|
|
26
26
|
folly_runtime
|
|
27
27
|
glog)
|
|
28
|
-
|
|
29
|
-
##################
|
|
30
|
-
### jscruntime ###
|
|
31
|
-
##################
|
|
32
|
-
|
|
33
|
-
add_library(jscruntime STATIC
|
|
34
|
-
JSCRuntime.h
|
|
35
|
-
JSCRuntime.cpp)
|
|
36
|
-
|
|
37
|
-
target_include_directories(jscruntime PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
|
|
38
|
-
|
|
39
|
-
target_link_libraries(jscruntime folly_runtime jsc glog)
|
|
40
|
-
|
|
41
|
-
# TODO: Remove this flag when ready.
|
|
42
|
-
# Android has this enabled by default, but the flag is still needed for iOS.
|
|
43
|
-
target_compile_options(jscruntime PRIVATE -DRN_FABRIC_ENABLED)
|
|
@@ -20,6 +20,10 @@ else
|
|
|
20
20
|
source[:tag] = "v#{version}"
|
|
21
21
|
end
|
|
22
22
|
|
|
23
|
+
folly_compiler_flags = '-DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1 -Wno-comma -Wno-shorten-64-to-32'
|
|
24
|
+
folly_version = '2021.07.22.00'
|
|
25
|
+
boost_compiler_flags = '-Wno-documentation'
|
|
26
|
+
|
|
23
27
|
Pod::Spec.new do |s|
|
|
24
28
|
s.name = "React-jsi"
|
|
25
29
|
s.version = version
|
|
@@ -30,18 +34,27 @@ Pod::Spec.new do |s|
|
|
|
30
34
|
s.platforms = { :ios => "12.4" }
|
|
31
35
|
s.source = source
|
|
32
36
|
|
|
37
|
+
s.header_dir = "jsi"
|
|
38
|
+
s.compiler_flags = folly_compiler_flags + ' ' + boost_compiler_flags
|
|
39
|
+
s.pod_target_xcconfig = { "HEADER_SEARCH_PATHS" => "\"$(PODS_ROOT)/boost\" \"$(PODS_ROOT)/RCT-Folly\" \"$(PODS_ROOT)/DoubleConversion\"" }
|
|
40
|
+
|
|
41
|
+
s.dependency "boost", "1.76.0"
|
|
42
|
+
s.dependency "DoubleConversion"
|
|
43
|
+
s.dependency "RCT-Folly", folly_version
|
|
44
|
+
s.dependency "glog"
|
|
45
|
+
|
|
33
46
|
if js_engine == :jsc
|
|
34
47
|
s.source_files = "**/*.{cpp,h}"
|
|
35
48
|
s.exclude_files = [
|
|
36
|
-
"jsi/JSIDynamic.{h,cpp}",
|
|
37
49
|
"jsi/jsilib-posix.cpp",
|
|
38
50
|
"jsi/jsilib-windows.cpp",
|
|
39
51
|
"**/test/*"
|
|
40
52
|
]
|
|
41
|
-
|
|
53
|
+
|
|
42
54
|
elsif js_engine == :hermes
|
|
43
55
|
# JSI is provided by hermes-engine when Hermes is enabled
|
|
44
|
-
|
|
56
|
+
# Just need to provide JSIDynamic in this case.
|
|
57
|
+
s.source_files = "jsi/JSIDynamic.{cpp,h}"
|
|
45
58
|
s.dependency "hermes-engine"
|
|
46
59
|
end
|
|
47
60
|
end
|
|
@@ -36,7 +36,6 @@ Pod::Spec.new do |s|
|
|
|
36
36
|
|
|
37
37
|
s.dependency "React-cxxreact", version
|
|
38
38
|
s.dependency "React-jsi", version
|
|
39
|
-
s.dependency "React-jsidynamic", version
|
|
40
39
|
s.dependency "React-perflogger", version
|
|
41
40
|
s.dependency "RCT-Folly", folly_version
|
|
42
41
|
s.dependency "DoubleConversion"
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
#pragma once
|
|
9
|
+
|
|
10
|
+
// This header is left here for compatibility reasons.
|
|
11
|
+
#include <react/bridging/CallbackWrapper.h>
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# The `/android` folder inside `react-native`
|
|
2
|
+
|
|
3
|
+
Starting from React Native 0.71, we're not shipping the `/android` folder inside the React Native NPM package
|
|
4
|
+
anymore due to sizing constraints on NPM. The Android artifacts are distributed via Maven Central.
|
|
5
|
+
You can read more about it in this RFC:
|
|
6
|
+
https://github.com/react-native-community/discussions-and-proposals/pull/508
|
|
7
|
+
|
|
8
|
+
If you're a library author and you're manipulating the React Native .aar files, to extract headers,
|
|
9
|
+
extract `.so` files or do anything with it, you're probably doing something wrong. React Native
|
|
10
|
+
0.71 ships with all the necessary logic to let you consume it transparently by just using:
|
|
11
|
+
|
|
12
|
+
```
|
|
13
|
+
implementation("com.facebook.react:react-android")
|
|
14
|
+
// or to keep backward compatibility with older versions of React Native:
|
|
15
|
+
implementation("com.facebook.react:react-native:+")
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
You should consider refactoring your library code not to unzip/manipulate the React Native .aar files.
|
|
19
|
+
|
|
20
|
+
This README.md file is kept in this folder as some libraries are checking the existence of the `/android` folder
|
|
21
|
+
and failing user builds if the folder is missing.
|
package/jest/react-native-env.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-native",
|
|
3
|
-
"version": "0.71.0-rc.
|
|
3
|
+
"version": "0.71.0-rc.4",
|
|
4
4
|
"bin": "./cli.js",
|
|
5
5
|
"description": "A framework for building native apps using React",
|
|
6
6
|
"license": "MIT",
|
|
@@ -104,30 +104,30 @@
|
|
|
104
104
|
},
|
|
105
105
|
"dependencies": {
|
|
106
106
|
"@jest/create-cache-key-function": "^29.2.1",
|
|
107
|
-
"@react-native-community/cli": "10.0.0
|
|
108
|
-
"@react-native-community/cli-platform-android": "10.0.0
|
|
109
|
-
"@react-native-community/cli-platform-ios": "10.0.0
|
|
107
|
+
"@react-native-community/cli": "10.0.0",
|
|
108
|
+
"@react-native-community/cli-platform-android": "10.0.0",
|
|
109
|
+
"@react-native-community/cli-platform-ios": "10.0.0",
|
|
110
110
|
"@react-native/assets": "1.0.0",
|
|
111
111
|
"@react-native/normalize-color": "2.1.0",
|
|
112
112
|
"@react-native/polyfills": "2.0.0",
|
|
113
113
|
"abort-controller": "^3.0.0",
|
|
114
114
|
"anser": "^1.4.9",
|
|
115
115
|
"base64-js": "^1.1.2",
|
|
116
|
-
"deprecated-react-native-prop-types": "^
|
|
116
|
+
"deprecated-react-native-prop-types": "^3.0.1",
|
|
117
117
|
"event-target-shim": "^5.0.1",
|
|
118
118
|
"invariant": "^2.2.4",
|
|
119
119
|
"jest-environment-node": "^29.2.1",
|
|
120
120
|
"jsc-android": "^250230.2.1",
|
|
121
121
|
"memoize-one": "^5.0.0",
|
|
122
|
-
"metro-react-native-babel-transformer": "0.73.
|
|
123
|
-
"metro-runtime": "0.73.
|
|
124
|
-
"metro-source-map": "0.73.
|
|
122
|
+
"metro-react-native-babel-transformer": "0.73.5",
|
|
123
|
+
"metro-runtime": "0.73.5",
|
|
124
|
+
"metro-source-map": "0.73.5",
|
|
125
125
|
"mkdirp": "^0.5.1",
|
|
126
126
|
"nullthrows": "^1.1.1",
|
|
127
127
|
"pretty-format": "^26.5.2",
|
|
128
128
|
"promise": "^8.3.0",
|
|
129
129
|
"react-devtools-core": "^4.26.1",
|
|
130
|
-
"react-native-gradle-plugin": "^0.71.
|
|
130
|
+
"react-native-gradle-plugin": "^0.71.11",
|
|
131
131
|
"react-refresh": "^0.4.0",
|
|
132
132
|
"react-shallow-renderer": "^16.15.0",
|
|
133
133
|
"regenerator-runtime": "^0.13.2",
|
|
@@ -175,8 +175,8 @@
|
|
|
175
175
|
"jest": "^29.2.1",
|
|
176
176
|
"jest-junit": "^10.0.0",
|
|
177
177
|
"jscodeshift": "^0.13.1",
|
|
178
|
-
"metro-babel-register": "0.73.
|
|
179
|
-
"metro-memory-fs": "0.73.
|
|
178
|
+
"metro-babel-register": "0.73.5",
|
|
179
|
+
"metro-memory-fs": "0.73.5",
|
|
180
180
|
"mkdirp": "^0.5.1",
|
|
181
181
|
"mock-fs": "^5.1.4",
|
|
182
182
|
"prettier": "^2.4.1",
|
package/react.gradle
CHANGED
|
@@ -442,11 +442,11 @@ afterEvaluate {
|
|
|
442
442
|
|
|
443
443
|
if (cleanup) {
|
|
444
444
|
// Reduce size by deleting the debugger/inspector
|
|
445
|
-
include '**/
|
|
445
|
+
include '**/libhermes_executor_debug.so'
|
|
446
446
|
} else {
|
|
447
447
|
// Release libs take precedence and must be removed
|
|
448
448
|
// to allow debugging
|
|
449
|
-
include '**/
|
|
449
|
+
include '**/libhermes_executor_release.so'
|
|
450
450
|
}
|
|
451
451
|
} else {
|
|
452
452
|
// For JSC, delete all the libhermes* files
|
|
@@ -11,9 +11,9 @@ require_relative './utils.rb'
|
|
|
11
11
|
# @parameter fabric_enabled: whether Fabirc is enabled
|
|
12
12
|
def setup_jsc!(react_native_path: "../node_modules/react-native", fabric_enabled: false)
|
|
13
13
|
pod 'React-jsi', :path => "#{react_native_path}/ReactCommon/jsi"
|
|
14
|
-
pod 'React-jsc', :path => "#{react_native_path}/ReactCommon/
|
|
14
|
+
pod 'React-jsc', :path => "#{react_native_path}/ReactCommon/jsc"
|
|
15
15
|
if fabric_enabled
|
|
16
|
-
pod 'React-jsc/Fabric', :path => "#{react_native_path}/ReactCommon/
|
|
16
|
+
pod 'React-jsc/Fabric', :path => "#{react_native_path}/ReactCommon/jsc"
|
|
17
17
|
end
|
|
18
18
|
end
|
|
19
19
|
|
|
@@ -30,7 +30,7 @@ def setup_hermes!(react_native_path: "../node_modules/react-native", fabric_enab
|
|
|
30
30
|
abort unless prep_status == 0
|
|
31
31
|
|
|
32
32
|
pod 'React-jsi', :path => "#{react_native_path}/ReactCommon/jsi"
|
|
33
|
-
pod 'hermes-engine', :podspec => "#{react_native_path}/sdks/hermes/hermes-engine.podspec"
|
|
33
|
+
pod 'hermes-engine', :podspec => "#{react_native_path}/sdks/hermes-engine/hermes-engine.podspec"
|
|
34
34
|
pod 'React-hermes', :path => "#{react_native_path}/ReactCommon/hermes"
|
|
35
35
|
pod 'libevent', '~> 2.1.12'
|
|
36
36
|
end
|
|
@@ -72,7 +72,7 @@ def is_building_hermes_from_source(react_native_version, react_native_path)
|
|
|
72
72
|
isInMain = react_native_version.include?('1000.0.0')
|
|
73
73
|
|
|
74
74
|
hermestag_file = File.join(react_native_path, "sdks", ".hermesversion")
|
|
75
|
-
isInCI = ENV['
|
|
75
|
+
isInCI = ENV['REACT_NATIVE_CI'] === 'true'
|
|
76
76
|
|
|
77
77
|
isReleaseBranch = File.exist?(hermestag_file) && isInCI
|
|
78
78
|
|
|
@@ -100,7 +100,7 @@ def use_react_native! (
|
|
|
100
100
|
else
|
|
101
101
|
setup_jsc!(:react_native_path => prefix, :fabric_enabled => fabric_enabled)
|
|
102
102
|
end
|
|
103
|
-
|
|
103
|
+
|
|
104
104
|
pod 'React-jsiexecutor', :path => "#{prefix}/ReactCommon/jsiexecutor"
|
|
105
105
|
pod 'React-jsinspector', :path => "#{prefix}/ReactCommon/jsinspector"
|
|
106
106
|
|
|
@@ -13,8 +13,6 @@ GENERATED_SCHEMA_FILE="$GENERATED_SRCS_DIR/schema.json"
|
|
|
13
13
|
|
|
14
14
|
cd "$RCT_SCRIPT_RN_DIR"
|
|
15
15
|
|
|
16
|
-
CODEGEN_REPO_PATH="$RCT_SCRIPT_RN_DIR/packages/react-native-codegen"
|
|
17
|
-
CODEGEN_NPM_PATH="$RCT_SCRIPT_RN_DIR/../react-native-codegen"
|
|
18
16
|
CODEGEN_CLI_PATH=""
|
|
19
17
|
|
|
20
18
|
error () {
|
|
@@ -23,15 +21,6 @@ error () {
|
|
|
23
21
|
exit 1
|
|
24
22
|
}
|
|
25
23
|
|
|
26
|
-
# Determine path to react-native-codegen
|
|
27
|
-
if [ -d "$CODEGEN_REPO_PATH" ]; then
|
|
28
|
-
CODEGEN_CLI_PATH=$(cd "$CODEGEN_REPO_PATH" && pwd)
|
|
29
|
-
elif [ -d "$CODEGEN_NPM_PATH" ]; then
|
|
30
|
-
CODEGEN_CLI_PATH=$(cd "$CODEGEN_NPM_PATH" && pwd)
|
|
31
|
-
else
|
|
32
|
-
error "error: Could not determine react-native-codegen location in $CODEGEN_REPO_PATH or $CODEGEN_NPM_PATH. Try running 'yarn install' or 'npm install' in your project root."
|
|
33
|
-
fi
|
|
34
|
-
|
|
35
24
|
find_node () {
|
|
36
25
|
NODE_BINARY="${NODE_BINARY:-$(command -v node || true)}"
|
|
37
26
|
if [ -z "$NODE_BINARY" ]; then
|
|
@@ -41,6 +30,13 @@ find_node () {
|
|
|
41
30
|
fi
|
|
42
31
|
}
|
|
43
32
|
|
|
33
|
+
find_codegen () {
|
|
34
|
+
CODEGEN_CLI_PATH=$("$NODE_BINARY" --print "require('path').dirname(require.resolve('react-native-codegen/package.json'))")
|
|
35
|
+
if ! [ -d "$CODEGEN_CLI_PATH" ]; then
|
|
36
|
+
error "error: Could not determine react-native-codegen location, using node module resolution. Try running 'yarn install' or 'npm install' in your project root."
|
|
37
|
+
fi
|
|
38
|
+
}
|
|
39
|
+
|
|
44
40
|
setup_dirs () {
|
|
45
41
|
set +e
|
|
46
42
|
rm -rf "$GENERATED_SRCS_DIR"
|
|
@@ -108,7 +104,7 @@ moveOutputs () {
|
|
|
108
104
|
mkdir -p "$RCT_SCRIPT_OUTPUT_DIR"
|
|
109
105
|
|
|
110
106
|
# Copy all output to output_dir
|
|
111
|
-
cp -R "$TEMP_OUTPUT_DIR
|
|
107
|
+
cp -R "$TEMP_OUTPUT_DIR/." "$RCT_SCRIPT_OUTPUT_DIR" || exit 1
|
|
112
108
|
echo "$LIBRARY_NAME output has been written to $RCT_SCRIPT_OUTPUT_DIR:" >> "${SCRIPT_OUTPUT_FILE_0}" 2>&1
|
|
113
109
|
ls -1 "$RCT_SCRIPT_OUTPUT_DIR" >> "${SCRIPT_OUTPUT_FILE_0}" 2>&1
|
|
114
110
|
}
|
|
@@ -116,6 +112,7 @@ moveOutputs () {
|
|
|
116
112
|
withCodgenDiscovery () {
|
|
117
113
|
setup_dirs
|
|
118
114
|
find_node
|
|
115
|
+
find_codegen
|
|
119
116
|
generateArtifacts
|
|
120
117
|
moveOutputs
|
|
121
118
|
}
|
|
@@ -123,6 +120,7 @@ withCodgenDiscovery () {
|
|
|
123
120
|
noCodegenDiscovery () {
|
|
124
121
|
setup_dirs
|
|
125
122
|
find_node
|
|
123
|
+
find_codegen
|
|
126
124
|
generateCodegenSchemaFromJavaScript
|
|
127
125
|
generateCodegenArtifactsFromSchema
|
|
128
126
|
moveOutputs
|
package/sdks/.hermesversion
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
hermes-2022-11-
|
|
1
|
+
hermes-2022-11-30-RNv0.71.0-1eb8f7ea3059a338205c302cea0f5a3057f93049
|
|
@@ -17,7 +17,7 @@ version = package['version']
|
|
|
17
17
|
|
|
18
18
|
# sdks/.hermesversion
|
|
19
19
|
hermestag_file = File.join(react_native_path, "sdks", ".hermesversion")
|
|
20
|
-
isInCI = ENV['
|
|
20
|
+
isInCI = ENV['REACT_NATIVE_CI'] === 'true'
|
|
21
21
|
|
|
22
22
|
source = {}
|
|
23
23
|
git = "https://github.com/facebook/hermes.git"
|
|
Binary file
|
|
Binary file
|
package/template/_eslintrc.js
CHANGED
package/template/ios/Podfile
CHANGED
|
@@ -1,11 +1,17 @@
|
|
|
1
1
|
require_relative '../node_modules/react-native/scripts/react_native_pods'
|
|
2
|
-
require_relative '../node_modules
|
|
2
|
+
require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules'
|
|
3
3
|
|
|
4
4
|
platform :ios, min_ios_version_supported
|
|
5
5
|
prepare_react_native_project!
|
|
6
6
|
|
|
7
7
|
flipper_config = ENV['NO_FLIPPER'] == "1" ? FlipperConfiguration.disabled : FlipperConfiguration.enabled
|
|
8
8
|
|
|
9
|
+
linkage = ENV['USE_FRAMEWORKS']
|
|
10
|
+
if linkage != nil
|
|
11
|
+
Pod::UI.puts "Configuring Pod with #{linkage}ally linked Frameworks".green
|
|
12
|
+
use_frameworks! :linkage => linkage.to_sym
|
|
13
|
+
end
|
|
14
|
+
|
|
9
15
|
target 'HelloWorld' do
|
|
10
16
|
config = use_native_modules!
|
|
11
17
|
|
package/template/package.json
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
},
|
|
12
12
|
"dependencies": {
|
|
13
13
|
"react": "18.2.0",
|
|
14
|
-
"react-native": "0.71.0-rc.
|
|
14
|
+
"react-native": "0.71.0-rc.4"
|
|
15
15
|
},
|
|
16
16
|
"devDependencies": {
|
|
17
17
|
"@babel/core": "^7.12.9",
|
|
@@ -22,12 +22,10 @@
|
|
|
22
22
|
"@types/jest": "^29.2.1",
|
|
23
23
|
"@types/react": "^18.0.24",
|
|
24
24
|
"@types/react-test-renderer": "^18.0.0",
|
|
25
|
-
"@typescript-eslint/eslint-plugin": "^5.37.0",
|
|
26
|
-
"@typescript-eslint/parser": "^5.37.0",
|
|
27
25
|
"babel-jest": "^29.2.1",
|
|
28
26
|
"eslint": "^8.19.0",
|
|
29
27
|
"jest": "^29.2.1",
|
|
30
|
-
"metro-react-native-babel-preset": "0.73.
|
|
28
|
+
"metro-react-native-babel-preset": "0.73.5",
|
|
31
29
|
"prettier": "^2.4.1",
|
|
32
30
|
"react-test-renderer": "18.2.0",
|
|
33
31
|
"typescript": "4.8.4"
|
|
@@ -86,9 +86,11 @@ export interface NativeMethods {
|
|
|
86
86
|
* _Can also be called with a relativeNativeNodeHandle but is deprecated._
|
|
87
87
|
*/
|
|
88
88
|
measureLayout(
|
|
89
|
-
relativeToNativeComponentRef:
|
|
89
|
+
relativeToNativeComponentRef:
|
|
90
|
+
| React.ElementRef<HostComponent<unknown>>
|
|
91
|
+
| number,
|
|
90
92
|
onSuccess: MeasureLayoutOnSuccessCallback,
|
|
91
|
-
onFail
|
|
93
|
+
onFail?: () => void,
|
|
92
94
|
): void;
|
|
93
95
|
|
|
94
96
|
/**
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
# Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
2
|
-
#
|
|
3
|
-
# This source code is licensed under the MIT license found in the
|
|
4
|
-
# LICENSE file in the root directory of this source tree.
|
|
5
|
-
|
|
6
|
-
require "json"
|
|
7
|
-
|
|
8
|
-
package = JSON.parse(File.read(File.join(__dir__, "..", "..", "package.json")))
|
|
9
|
-
version = package['version']
|
|
10
|
-
|
|
11
|
-
source = { :git => 'https://github.com/facebook/react-native.git' }
|
|
12
|
-
if version == '1000.0.0'
|
|
13
|
-
# This is an unpublished version, use the latest commit hash of the react-native repo, which we’re presumably in.
|
|
14
|
-
source[:commit] = `git rev-parse HEAD`.strip if system("git rev-parse --git-dir > /dev/null 2>&1")
|
|
15
|
-
else
|
|
16
|
-
source[:tag] = "v#{version}"
|
|
17
|
-
end
|
|
18
|
-
|
|
19
|
-
folly_compiler_flags = '-DFOLLY_NO_CONFIG -DFOLLY_MOBILE=1 -DFOLLY_USE_LIBCPP=1 -Wno-comma -Wno-shorten-64-to-32'
|
|
20
|
-
folly_version = '2021.07.22.00'
|
|
21
|
-
boost_compiler_flags = '-Wno-documentation'
|
|
22
|
-
|
|
23
|
-
Pod::Spec.new do |s|
|
|
24
|
-
s.name = "React-jsidynamic"
|
|
25
|
-
s.version = version
|
|
26
|
-
s.summary = "Provides support for converting between folly::dynamic and jsi::value"
|
|
27
|
-
s.homepage = "https://reactnative.dev/"
|
|
28
|
-
s.license = package["license"]
|
|
29
|
-
s.author = "Facebook, Inc. and its affiliates"
|
|
30
|
-
s.platforms = { :ios => "12.4" }
|
|
31
|
-
s.source = source
|
|
32
|
-
s.source_files = "jsi/JSIDynamic.{cpp,h}"
|
|
33
|
-
s.compiler_flags = folly_compiler_flags + ' ' + boost_compiler_flags
|
|
34
|
-
s.pod_target_xcconfig = { "HEADER_SEARCH_PATHS" => "\"$(PODS_ROOT)/boost\" \"$(PODS_ROOT)/RCT-Folly\" \"$(PODS_ROOT)/DoubleConversion\"" }
|
|
35
|
-
s.header_dir = 'jsi'
|
|
36
|
-
|
|
37
|
-
s.dependency "boost", "1.76.0"
|
|
38
|
-
s.dependency "DoubleConversion"
|
|
39
|
-
s.dependency "RCT-Folly", folly_version
|
|
40
|
-
s.dependency "glog"
|
|
41
|
-
s.dependency "React-jsi", version
|
|
42
|
-
end
|