Fix Dynamic framework build and resolve circular dependency for JSC (#54421)

Summary:
OSS community shared with me that we have a circular dependency in React-utils.podspec that prevent them from building with JSC.
While fixing it, I realized that the dynamic framework build was broken. So I fixed them both.

## Changelog:
[iOS][Fixed] - Fixed build with dynamic frameworks

Pull Request resolved: https://github.com/facebook/react-native/pull/54421

Test Plan: Build RNTester locally with USE_FRAMEWORKS=dynamic

Reviewed By: javache

Differential Revision: D86309592

Pulled By: cipolleschi

fbshipit-source-id: f2995332ae135ce951480b353df7d597ff8a85ec
This commit is contained in:
Riccardo Cipolleschi authored and meta-codesync[bot] committed 2025-11-05 13:22:17 -08:00
1 parent ef6f3f6032
commit 1033dbd1da
7 files changed
+12 -1

No files matched your search

@@ -61,6 +61,7 @@ Pod::Spec.new do |s|
add_dependency(s, "React-RCTFBReactNativeSpec")
add_dependency(s, "ReactCommon", :subspec => "turbomodule/core", :additional_framework_paths => ["react/nativemodule/core"])
add_dependency(s, "React-NativeModulesApple")
add_dependency(s, "React-utils", :additional_framework_paths => ["react/utils/platform/ios"])
add_rn_third_party_dependencies(s)
add_rncore_dependency(s)
@@ -56,6 +56,7 @@ Pod::Spec.new do |s|
add_dependency(s, "React-RuntimeCore")
add_dependency(s, "React-RuntimeApple")
add_dependency(s, "React-utils", :additional_framework_paths => ["react/utils/platform/ios"])
if use_third_party_jsc()
s.exclude_files = ["RCTHermesInstanceFactory.{mm,h}", "RCTJscInstanceFactory.{mm,h}"]
@@ -44,6 +44,7 @@ Pod::Spec.new do |s|
s.dependency "React-logger", version
s.dependency "React-debug", version
s.dependency "React-timing", version
add_dependency(s, "React-utils", :additional_framework_paths => ["react/utils/platform/ios"])
s.resource_bundles = {'React-cxxreact_privacy' => 'PrivacyInfo.xcprivacy'}
@@ -37,6 +37,7 @@ Pod::Spec.new do |s|
add_dependency(s, "React-jsinspector", :framework_name => 'jsinspector_modern')
add_dependency(s, "React-jsinspectorcdp", :framework_name => 'jsinspector_moderncdp')
add_dependency(s, "React-jsinspectortracing", :framework_name => 'jsinspector_moderntracing')
add_dependency(s, "React-utils", :additional_framework_paths => ["react/utils/platform/ios"])
if use_hermes()
s.dependency 'hermes-engine'
end
@@ -48,6 +48,10 @@ Pod::Spec.new do |s|
s.dependency "React-oscompat"
s.dependency "React-timing"
if use_hermes()
s.dependency "hermes-engine"
end
add_rn_third_party_dependencies(s)
add_rncore_dependency(s)
end
@@ -42,6 +42,7 @@ Pod::Spec.new do |s|
add_dependency(s, "React-jsinspector", :framework_name => 'jsinspector_modern')
add_dependency(s, "React-jsinspectorcdp", :framework_name => 'jsinspector_moderncdp')
add_dependency(s, "React-jsinspectortracing", :framework_name => 'jsinspector_moderntracing')
add_dependency(s, "React-utils", :additional_framework_paths => ["react/utils/platform/ios"])
add_rn_third_party_dependencies(s)
add_rncore_dependency(s)
@@ -47,7 +47,9 @@ Pod::Spec.new do |s|
s.dependency "React-jsi", version
depend_on_js_engine(s)
if use_hermes()
s.dependency "hermes-engine"
end
add_rn_third_party_dependencies(s)
add_rncore_dependency(s)