react-native 0.71.0-rc.1 → 0.71.0-rc.2
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/React/Base/RCTVersion.m +1 -1
- package/ReactAndroid/gradle.properties +1 -1
- package/ReactAndroid/src/main/java/com/facebook/react/modules/systeminfo/ReactNativeVersion.java +1 -1
- package/ReactCommon/cxxreact/ReactNativeVersion.h +1 -1
- package/package.json +1 -1
- package/scripts/cocoapods/jsengine.rb +19 -10
- package/scripts/react_native_pods.rb +2 -1
- package/template/package.json +1 -1
package/React/Base/RCTVersion.m
CHANGED
package/package.json
CHANGED
|
@@ -37,7 +37,7 @@ end
|
|
|
37
37
|
|
|
38
38
|
def add_copy_hermes_framework_script_phase(installer, react_native_path)
|
|
39
39
|
utils_dir = File.join(react_native_path, "sdks", "hermes-engine", "utils")
|
|
40
|
-
phase_name = "[RN]Copy Hermes
|
|
40
|
+
phase_name = "[RN] Copy Hermes Framework"
|
|
41
41
|
project = installer.generated_aggregate_targets.first.user_project
|
|
42
42
|
target = project.targets.first
|
|
43
43
|
if target.shell_script_build_phases.none? { |phase| phase.name == phase_name }
|
|
@@ -49,9 +49,14 @@ end
|
|
|
49
49
|
|
|
50
50
|
def remove_copy_hermes_framework_script_phase(installer, react_native_path)
|
|
51
51
|
utils_dir = File.join(react_native_path, "sdks", "hermes-engine", "utils")
|
|
52
|
-
phase_name = "[RN]Copy Hermes
|
|
52
|
+
phase_name = "[RN] Copy Hermes Framework"
|
|
53
53
|
project = installer.generated_aggregate_targets.first.user_project
|
|
54
|
-
project.
|
|
54
|
+
target = project.native_targets.first
|
|
55
|
+
target.shell_script_build_phases.each do |phase|
|
|
56
|
+
if phase.name == phase_name
|
|
57
|
+
target.build_phases.delete(phase)
|
|
58
|
+
end
|
|
59
|
+
end
|
|
55
60
|
project.save()
|
|
56
61
|
end
|
|
57
62
|
|
|
@@ -59,14 +64,18 @@ def remove_hermesc_build_dir(react_native_path)
|
|
|
59
64
|
%x(rm -rf #{react_native_path}/sdks/hermes-engine/build_host_hermesc)
|
|
60
65
|
end
|
|
61
66
|
|
|
62
|
-
def is_building_hermes_from_source(react_native_version)
|
|
63
|
-
|
|
64
|
-
has_tarball = ENV['HERMES_ENGINE_TARBALL_PATH'] != nil
|
|
65
|
-
|
|
66
|
-
# this is the same logic in the hermes-engine.podspec
|
|
67
|
-
if has_tarball || is_nightly
|
|
67
|
+
def is_building_hermes_from_source(react_native_version, react_native_path)
|
|
68
|
+
if ENV['HERMES_ENGINE_TARBALL_PATH'] != nil
|
|
68
69
|
return false
|
|
69
70
|
end
|
|
70
71
|
|
|
71
|
-
|
|
72
|
+
isInMain = react_native_version.include?('1000.0.0')
|
|
73
|
+
|
|
74
|
+
hermestag_file = File.join(react_native_path, "sdks", ".hermesversion")
|
|
75
|
+
isInCI = ENV['CI'] === 'true'
|
|
76
|
+
|
|
77
|
+
isReleaseBranch = File.exist?(hermestag_file) && isInCI
|
|
78
|
+
|
|
79
|
+
|
|
80
|
+
return isInMain || isReleaseBranch
|
|
72
81
|
end
|
|
@@ -205,10 +205,11 @@ def react_native_post_install(installer, react_native_path = "../node_modules/re
|
|
|
205
205
|
package = JSON.parse(File.read(File.join(react_native_path, "package.json")))
|
|
206
206
|
version = package['version']
|
|
207
207
|
|
|
208
|
-
if ReactNativePodsUtils.has_pod(installer, 'hermes-engine') && is_building_hermes_from_source(version)
|
|
208
|
+
if ReactNativePodsUtils.has_pod(installer, 'hermes-engine') && is_building_hermes_from_source(version, react_native_path)
|
|
209
209
|
add_copy_hermes_framework_script_phase(installer, react_native_path)
|
|
210
210
|
else
|
|
211
211
|
remove_copy_hermes_framework_script_phase(installer, react_native_path)
|
|
212
|
+
remove_hermesc_build_dir(react_native_path)
|
|
212
213
|
end
|
|
213
214
|
|
|
214
215
|
ReactNativePodsUtils.exclude_i386_architecture_while_using_hermes(installer)
|