diff --git a/packages/react-native/ReactCommon/React-rncore.podspec b/packages/react-native/ReactCommon/React-rncore.podspec index 88ae8f51bcfbaa..cd00efd8875948 100644 --- a/packages/react-native/ReactCommon/React-rncore.podspec +++ b/packages/react-native/ReactCommon/React-rncore.podspec @@ -16,7 +16,14 @@ else source[:tag] = "v#{version}" end -react_native_path = ".." +# We are using to different paths for react native because of the way how js_srcs_dir and output_dir options are used +# output_dir option usage was introduced in D43304641, React-rncore.podspec is the only podspec in the project that uses this option +# We should rethink this approach in T148704916 + +# Relative path to react native from iOS project root (e.g. /../node_modules/react-native) +react_native_dependency_path = ENV['REACT_NATIVE_PATH'] +# Relative path to react native from current podspec +react_native_sources_path = '..' Pod::Spec.new do |s| s.name = "React-rncore" @@ -33,10 +40,10 @@ Pod::Spec.new do |s| use_react_native_codegen!(s, { - :react_native_path => react_native_path, - :js_srcs_dir => "#{react_native_path}/Libraries", + :react_native_path => react_native_sources_path, + :js_srcs_dir => "#{react_native_sources_path}/Libraries", :library_name => "rncore", :library_type => "components", - :output_dir => "#{react_native_path}/react-native/ReactCommon" + :output_dir => "#{react_native_dependency_path}/ReactCommon" }) end diff --git a/packages/rn-tester/Podfile.lock b/packages/rn-tester/Podfile.lock index be0ec11b28e079..61d109df592cb7 100644 --- a/packages/rn-tester/Podfile.lock +++ b/packages/rn-tester/Podfile.lock @@ -1015,7 +1015,7 @@ SPEC CHECKSUMS: FlipperKit: 2efad7007d6745a3f95e4034d547be637f89d3f6 fmt: ff9d55029c625d3757ed641535fd4a75fedc7ce9 glog: 04b94705f318337d7ead9e6d17c019bd9b1f6b1b - hermes-engine: d4e3147fcec14fb95d56cad45f03f126e725a098 + hermes-engine: 23974109d4ab9be57257a23579a564c53f86abc3 libevent: 4049cae6c81cdb3654a443be001fb9bdceff7913 OCMock: 9491e4bec59e0b267d52a9184ff5605995e74be8 OpenSSL-Universal: ebc357f1e6bc71fa463ccb2fe676756aff50e88c