Skip to content

Commit f84514a

Browse files
msynowskifacebook-github-bot
authored andcommitted
Do not override (xc)framework's Info.plist files with RCTNewArchEnabled (#52520)
Summary: `new_architecture.rb` script looks for `Info.plist` files in IOS directory, and adds RCTNewArchEnabled field to each one, except for those explicitly excluded. Framework files should remain unchanged, so I've extended the excluded_info_plist dict. Modifying framework's Info.plist can break pod installation with errors like: ``` [!] An error occurred while processing the post-install hook of the Podfile. invalid byte sequence in UTF-8 ``` ## Changelog: <!-- Help reviewers and the release process by writing your own changelog entry. Pick one each for the category and type tags: [ANDROID|GENERAL|IOS|INTERNAL] [BREAKING|ADDED|CHANGED|DEPRECATED|REMOVED|FIXED|SECURITY] - Message For more details, see: https://reactnative.dev/contributing/changelogs-in-pull-requests --> [IOS] [FIXED] Fix overriding (xc)framework Info.plist files with RCTNewArchEnabled field Pull Request resolved: #52520 Test Plan: Add any .framework or .xcframework to the iOS directory, install pods. If *.(xc)framework/Info.plist remains unchanged it works as intended. Reviewed By: cortinico Differential Revision: D78731439 Pulled By: cipolleschi fbshipit-source-id: a04dfc0e282294e3e16d8292281f2c3369008551
1 parent 59101d6 commit f84514a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

packages/react-native/scripts/cocoapods/new_architecture.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ def self.set_RCTNewArchEnabled_in_info_plist(installer, new_arch_enabled)
162162
.uniq{ |p| p.path }
163163
.map{ |p| p.path }
164164

165-
excluded_info_plist = ["/Pods", "Tests", "metainternal", ".bundle", "build/", "DerivedData/"]
165+
excluded_info_plist = ["/Pods", "Tests", "metainternal", ".bundle", "build/", "DerivedData/", ".xcframework", ".framework"]
166166
projectPaths.each do |projectPath|
167167
projectFolderPath = File.dirname(projectPath)
168168
infoPlistFiles = `find #{projectFolderPath} -name "Info.plist"`

0 commit comments

Comments
 (0)