diff --git a/packages/react-native/React-Core.podspec b/packages/react-native/React-Core.podspec index da75b42c0ac996..101b5e9cc10056 100644 --- a/packages/react-native/React-Core.podspec +++ b/packages/react-native/React-Core.podspec @@ -129,6 +129,8 @@ Pod::Spec.new do |s| s.dependency "Yoga" s.dependency "glog" + add_dependency(s, "RCTDeprecation") + if use_hermes s.dependency 'React-hermes' s.dependency 'hermes-engine' diff --git a/packages/react-native/ReactApple/Libraries/RCTFoundation/RCTDeprecation/RCTDeprecation.podspec b/packages/react-native/ReactApple/Libraries/RCTFoundation/RCTDeprecation/RCTDeprecation.podspec new file mode 100644 index 00000000000000..ea8b9044c8d3be --- /dev/null +++ b/packages/react-native/ReactApple/Libraries/RCTFoundation/RCTDeprecation/RCTDeprecation.podspec @@ -0,0 +1,25 @@ +# Copyright (c) Meta Platforms, Inc. and affiliates. +# +# This source code is licensed under the MIT license found in the +# LICENSE file in the root directory of this source tree. + +require "json" + +package = JSON.parse(File.read(File.join(__dir__, "..", "..", "..", "..", "package.json"))) +version = package['version'] + +Pod::Spec.new do |s| + s.name = "RCTDeprecation" + s.version = version + s.author = "Meta Platforms, Inc. and its affiliates" + s.license = package["license"] + s.homepage = "https://reactnative.dev/" + s.source = { :git => 'https://github.com/facebook/react-native.git', :tag => 'v#{version}' } + s.summary = "Macros for marking APIs as deprecated" + s.source_files = "Exported/*.h" + s.pod_target_xcconfig = { + "DEFINES_MODULE" => "YES", + "CLANG_CXX_LANGUAGE_STANDARD" => "c++20" + } + s.compiler_flags = "-Wnullable-to-nonnull-conversion -Wnullability-completeness" + end diff --git a/packages/react-native/package.json b/packages/react-native/package.json index 37f839703342b1..f80ea276738e13 100644 --- a/packages/react-native/package.json +++ b/packages/react-native/package.json @@ -48,6 +48,7 @@ "React.podspec", "React", "ReactAndroid", + "ReactApple", "ReactCommon", "README.md", "rn-get-polyfills.js", diff --git a/packages/react-native/scripts/react_native_pods.rb b/packages/react-native/scripts/react_native_pods.rb index ed040142261bfd..d14c7b2bb2fbd9 100644 --- a/packages/react-native/scripts/react_native_pods.rb +++ b/packages/react-native/scripts/react_native_pods.rb @@ -128,7 +128,8 @@ def use_react_native! ( pod 'React-utils', :path => "#{prefix}/ReactCommon/react/utils" pod 'React-Mapbuffer', :path => "#{prefix}/ReactCommon" pod 'React-jserrorhandler', :path => "#{prefix}/ReactCommon/jserrorhandler" - pod "React-nativeconfig", :path => "#{prefix}/ReactCommon" + pod 'React-nativeconfig', :path => "#{prefix}/ReactCommon" + pod 'RCTDeprecation', :path => "#{prefix}/ReactApple/Libraries/RCTFoundation/RCTDeprecation" if hermes_enabled setup_hermes!(:react_native_path => prefix) diff --git a/packages/rn-tester/Podfile.lock b/packages/rn-tester/Podfile.lock index 2d38f0181b3f63..7e4a271ffb1911 100644 --- a/packages/rn-tester/Podfile.lock +++ b/packages/rn-tester/Podfile.lock @@ -37,6 +37,7 @@ PODS: - DoubleConversion - fmt (= 9.1.0) - glog + - RCTDeprecation (1000.0.0) - RCTRequired (1000.0.0) - RCTTypeSafety (1000.0.0): - FBLazyVector (= 1000.0.0) @@ -80,6 +81,7 @@ PODS: - glog - hermes-engine - RCT-Folly (= 2023.08.07.00) + - RCTDeprecation - React-Core/Default (= 1000.0.0) - React-cxxreact - React-hermes @@ -94,6 +96,7 @@ PODS: - glog - hermes-engine - RCT-Folly (= 2023.08.07.00) + - RCTDeprecation - React-Core/Default - React-cxxreact - React-hermes @@ -108,6 +111,7 @@ PODS: - glog - hermes-engine - RCT-Folly (= 2023.08.07.00) + - RCTDeprecation - React-cxxreact - React-hermes - React-jsi @@ -121,6 +125,7 @@ PODS: - glog - hermes-engine - RCT-Folly (= 2023.08.07.00) + - RCTDeprecation - React-Core/Default (= 1000.0.0) - React-Core/RCTWebSocket (= 1000.0.0) - React-cxxreact @@ -137,6 +142,7 @@ PODS: - glog - hermes-engine - RCT-Folly (= 2023.08.07.00) + - RCTDeprecation - React-Core/Default - React-cxxreact - React-hermes @@ -151,6 +157,7 @@ PODS: - glog - hermes-engine - RCT-Folly (= 2023.08.07.00) + - RCTDeprecation - React-Core/Default - React-cxxreact - React-hermes @@ -165,6 +172,7 @@ PODS: - glog - hermes-engine - RCT-Folly (= 2023.08.07.00) + - RCTDeprecation - React-Core/Default - React-cxxreact - React-hermes @@ -179,6 +187,7 @@ PODS: - glog - hermes-engine - RCT-Folly (= 2023.08.07.00) + - RCTDeprecation - React-Core/Default - React-cxxreact - React-hermes @@ -193,6 +202,7 @@ PODS: - glog - hermes-engine - RCT-Folly (= 2023.08.07.00) + - RCTDeprecation - React-Core/Default - React-cxxreact - React-hermes @@ -207,6 +217,7 @@ PODS: - glog - hermes-engine - RCT-Folly (= 2023.08.07.00) + - RCTDeprecation - React-Core/Default - React-cxxreact - React-hermes @@ -221,6 +232,7 @@ PODS: - glog - hermes-engine - RCT-Folly (= 2023.08.07.00) + - RCTDeprecation - React-Core/Default - React-cxxreact - React-hermes @@ -235,6 +247,7 @@ PODS: - glog - hermes-engine - RCT-Folly (= 2023.08.07.00) + - RCTDeprecation - React-Core/Default - React-cxxreact - React-hermes @@ -249,6 +262,7 @@ PODS: - glog - hermes-engine - RCT-Folly (= 2023.08.07.00) + - RCTDeprecation - React-Core/Default - React-cxxreact - React-hermes @@ -263,6 +277,7 @@ PODS: - glog - hermes-engine - RCT-Folly (= 2023.08.07.00) + - RCTDeprecation - React-Core/Default - React-cxxreact - React-hermes @@ -277,6 +292,7 @@ PODS: - glog - hermes-engine - RCT-Folly (= 2023.08.07.00) + - RCTDeprecation - React-Core/Default (= 1000.0.0) - React-cxxreact - React-hermes @@ -888,6 +904,7 @@ PODS: - DoubleConversion - fmt (= 9.1.0) - glog + - hermes-engine - RCT-Folly (= 2023.08.07.00) - React-jsiexecutor (1000.0.0): - DoubleConversion @@ -1113,6 +1130,7 @@ DEPENDENCIES: - OCMock (~> 3.9.1) - RCT-Folly (from `../react-native/third-party-podspecs/RCT-Folly.podspec`) - RCT-Folly/Fabric (from `../react-native/third-party-podspecs/RCT-Folly.podspec`) + - RCTDeprecation (from `../react-native/ReactApple/Libraries/RCTFoundation/RCTDeprecation`) - RCTRequired (from `../react-native/Libraries/Required`) - RCTTypeSafety (from `../react-native/Libraries/TypeSafety`) - React (from `../react-native/`) @@ -1183,6 +1201,8 @@ EXTERNAL SOURCES: :tag: '' RCT-Folly: :podspec: "../react-native/third-party-podspecs/RCT-Folly.podspec" + RCTDeprecation: + :path: "../react-native/ReactApple/Libraries/RCTFoundation/RCTDeprecation" RCTRequired: :path: "../react-native/Libraries/Required" RCTTypeSafety: @@ -1281,15 +1301,16 @@ SPEC CHECKSUMS: FBReactNativeSpec: 03da6018f583d64c5944bc4afffb12368e3642a8 fmt: 4c2741a687cc09f0634a2e2c72a838b99f1ff120 glog: c5d68082e772fa1c511173d6b30a9de2c05a69a2 - hermes-engine: 2788dfc2ed3699d11b14e815f0c608fc8d770d6b + hermes-engine: 3cf266f7eba66a16bcc83d939def2899e6d1a717 OCMock: 9491e4bec59e0b267d52a9184ff5605995e74be8 RCT-Folly: 823c6f6ec910a75d4ad28898b4a11cdee140b92a + RCTDeprecation: 706a006feee48f95f8b956eb573bcac0894d917e RCTRequired: 82c56a03b3efd524bfdb581a906add903f78f978 RCTTypeSafety: 5f57d4ae5dfafc85a0f575d756c909b584722c52 React: cb6dc75e09f32aeddb4d8fb58a394a67219a92fe React-callinvoker: bae59cbd6affd712bbfc703839dad868ff35069d React-Codegen: 20baee7c8f2303bc5f34d9e72f93ca55de6cbde3 - React-Core: f09ea29184cc7f33015a0748588fcfe1d43b3dd1 + React-Core: aaf2be188dfb2c342bc504042a92bfff31e2048f React-CoreModules: ad1b7cb8efe5f3c7e88548b6ea6aad8507774471 React-cxxreact: 04bf6a12caa850f5d2c7bd6d66dfecd4741989b5 React-debug: 296b501a90c41f83961f58c6d96a01330d499da5 @@ -1299,7 +1320,7 @@ SPEC CHECKSUMS: React-hermes: f192759ffeb9714917e9c39850ac349d8ea982d8 React-ImageManager: 691c4a56320ab9ab10482cd6306b3a4da004b79c React-jserrorhandler: 79fb3a8860fb1ea22dc77765aac15775593d4f8f - React-jsi: 3c1d8048abf3eaca913944bd9835333bb7b415d4 + React-jsi: 81f4e5b414c992c16c02e22e975a45aeb2b166e4 React-jsiexecutor: 1212e26a01ce4de7443123f0ce090ec1affb3220 React-jsinspector: c867db3338992200616103b2f0ca6882c0c0482d React-logger: 8486d7a1d32b972414b1d34a93470ee2562c6ee2 @@ -1329,7 +1350,7 @@ SPEC CHECKSUMS: ReactCommon-Samples: cfc3383af93a741319e038977c2ae1082e4ff49e ScreenshotManager: 2b23b74d25f5e307f7b4d21173a61a3934e69475 SocketRocket: abac6f5de4d4d62d24e11868d7a2f427e0ef940d - Yoga: 455fa6867657b570a05655dd515c8c6588618fa8 + Yoga: dcc90b6f6863e467adabdd4f4bd963da1faddf1d PODFILE CHECKSUM: c0120ff99aea9c7141bc22179e0f6be99c81a601