Add back the folly_compiler_flags for backward compatibility (#50875)

Summary:
Some libraries still use the `folly_flags` method provided by our infra. When updating how folly should be installed in an app, we removed that function.
We are putting it back as deprecated, to avoid unnecessary breaking changes in libraries

## Changelog:
[iOS][Fixed] - Put back the `folly_compiler_flag` function to make libraries install pods

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

Test Plan: Tested locally in a nightly app, using the react-native-exit-app library which still uses these flags

Reviewed By: cortinico

Differential Revision: D73512830

Pulled By: cipolleschi

fbshipit-source-id: 28f099064e93ecd5a5a6a7b82e3f7e9db4d35cb9
This commit is contained in:
Riccardo Cipolleschi
2025-04-23 12:15:49 -07:00
committed by Facebook GitHub Bot
parent 3f41fe2948
commit 3b17cdb643
@@ -145,6 +145,12 @@ class NewArchitectureHelper
return package["version"]
end
# Deprecated method. This has been restored because some libraries (e.g. react-native-exit-app) still use it.
def self.folly_compiler_flags
folly_config = Helpers::Constants.folly_config
return folly_config[:compiler_flags]
end
def self.new_arch_enabled
return ENV["RCT_NEW_ARCH_ENABLED"] == '0' ? false : true
end