Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[iOS][Cocoapods] Make RNM work with use_frameworks #1967

Draft
wants to merge 2 commits into
base: 0.73-stable
Choose a base branch
from

Conversation

cipolleschi
Copy link

@cipolleschi cipolleschi commented Nov 2, 2023

Please select one of the following

  • I am removing an existing difference between facebook/react-native and microsoft/react-native-macos 👍
  • I am cherry-picking a change from Facebook's react-native into microsoft/react-native-macos 👍
  • I am making a fix / change for the macOS implementation of react-native
  • I am making a change required for Microsoft usage of react-native

Summary:

This change makes react-native-mac build with both the new and the old architecture using use_frameworks! and static linking.

Changelog:

[iOS][Added] - Support for use_frameworks! in both architecture with static linking

Test Plan:

Tested locally with RNTester

@cipolleschi cipolleschi requested a review from a team as a code owner November 2, 2023 19:29
@cipolleschi cipolleschi marked this pull request as draft November 2, 2023 19:30
@cipolleschi cipolleschi force-pushed the cipolleschi/macos-use_frameworks branch from c5c99d2 to 52c075e Compare November 2, 2023 19:43
@cipolleschi
Copy link
Author

@microsoft-github-policy-service agree [company="Meta"]

@cipolleschi
Copy link
Author

@microsoft-github-policy-service agree company="Meta"

cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 7, 2023
Summary:
In order to make the infra scalable and avoid a maintenance nightmare for macOS and future platform, we are introducing this function that automate adding a dependency to a podspec and it generates the required search paths.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: D51027343
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 7, 2023
Summary:
React-Core does not depends on any bit of ReactCommon, React-RCTFabric or React-NativeModuleApple, so I'm cleaning that up.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: D51030115
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 7, 2023
Summary:
This change migrate React-RCTBlob to the new add_dependency to improve its compatibility with macOS and to remove some maintenance burden.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: D51030365
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 7, 2023
Summary:
This change expose a missing function to create Header Search Paths when a podspec can't depend on another one explicitly.
This also migrate the ruby code to this new function.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: D51068390
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 7, 2023
Summary:
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

In order to make the infra scalable and avoid a maintenance nightmare for macOS and future platform, we are introducing this function that should factor out the platforms from the generation of header search paths.

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: D51026356
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 7, 2023
Summary:
In order to make the infra scalable and avoid a maintenance nightmare for macOS and future platform, we are introducing this function that automate adding a dependency to a podspec and it generates the required search paths.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: D51027343
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 7, 2023
Summary:
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

In order to make the infra scalable and avoid a maintenance nightmare for macOS and future platform, we are introducing this function that should factor out the platforms from the generation of header search paths.

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: D51026356
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 7, 2023
…AppDelegate

Summary:
This change expose a new API to react_native_pod to add dependencies that automatically configure their search paths when using frameworksa and with multiple Apple platforms.
It also migrates React-RCTAppDelegate to this new mechanism to test that it works.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: D51029484
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 7, 2023
Summary:
React-Core does not depends on any bit of ReactCommon, React-RCTFabric or React-NativeModuleApple, so I'm cleaning that up.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: D51030115
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 7, 2023
Summary:
This change migrate React-RCTBlob to the new add_dependency to improve its compatibility with macOS and to remove some maintenance burden.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: D51030365
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 7, 2023
Summary:
This change expose a missing function to create Header Search Paths when a podspec can't depend on another one explicitly.
This also migrate the ruby code to this new function.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: D51068390
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 7, 2023
Summary:
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

In order to make the infra scalable and avoid a maintenance nightmare for macOS and future platform, we are introducing this function that should factor out the platforms from the generation of header search paths.

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: D51026356
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 7, 2023
Summary:
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

In order to make the infra scalable and avoid a maintenance nightmare for macOS and future platform, we are introducing this function that should factor out the platforms from the generation of header search paths.

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: D51026356

fbshipit-source-id: 1e0d508481fd83a80eaf8afb85fff84c019e2b3f
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 7, 2023
Summary:
In order to make the infra scalable and avoid a maintenance nightmare for macOS and future platform, we are introducing this function that automate adding a dependency to a podspec and it generates the required search paths.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: https://internalfb.com/D51027343

fbshipit-source-id: 687af2f61501d724e546c4de1f365b3edd61afa1
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 8, 2023
…AppDelegate (facebook#41355)

Summary:
Pull Request resolved: facebook#41355

This change expose a new API to react_native_pod to add dependencies that automatically configure their search paths when using frameworksa and with multiple Apple platforms.
It also migrates React-RCTAppDelegate to this new mechanism to test that it works.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: https://internalfb.com/D51029484

fbshipit-source-id: ff39bb51a0b76c5139dc7f174ea49df7b2d54df4
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 8, 2023
Summary:
React-Core does not depends on any bit of ReactCommon, React-RCTFabric or React-NativeModuleApple, so I'm cleaning that up.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: D51030115

fbshipit-source-id: c770d922cb43fcbd147a8ed3d3b394f8edc95f13
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 8, 2023
Summary:
This change migrate React-RCTBlob to the new add_dependency to improve its compatibility with macOS and to remove some maintenance burden.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: D51030365

fbshipit-source-id: a13c5acd65807847a2c9f780b65f9be5e3a034f7
cipolleschi pushed a commit to cipolleschi/react-native that referenced this pull request Nov 8, 2023
Summary:
This change expose a missing function to create Header Search Paths when a podspec can't depend on another one explicitly.
This also migrate the ruby code to this new function.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Differential Revision: D51068390

fbshipit-source-id: c8fcc4d83ce6b8ac10563b0a62a8fe6fd3f799ba
cipolleschi added a commit to cipolleschi/react-native that referenced this pull request Nov 8, 2023
Summary:
Pull Request resolved: facebook#41359

This change migrates the remaining podspecs to the new functions, so we do not depend on hardcoded values anymore and we can scale the solution to other platforms.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51068403

fbshipit-source-id: ca69263265404fc3fe2f5ca7a0f7e31f8ec54568
facebook-github-bot pushed a commit to facebook/react-native that referenced this pull request Nov 8, 2023
Summary:
Pull Request resolved: #41353

Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

In order to make the infra scalable and avoid a maintenance nightmare for macOS and future platform, we are introducing this function that should factor out the platforms from the generation of header search paths.

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51026356

fbshipit-source-id: 7cf03601d94d7680f3fdfcaf52b2fd6bcd48c5b4
facebook-github-bot pushed a commit to facebook/react-native that referenced this pull request Nov 8, 2023
Summary:
Pull Request resolved: #41354

In order to make the infra scalable and avoid a maintenance nightmare for macOS and future platform, we are introducing this function that automate adding a dependency to a podspec and it generates the required search paths.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51027343

fbshipit-source-id: 33ac4c07112eacb08067220397e38db0a19240fb
facebook-github-bot pushed a commit to facebook/react-native that referenced this pull request Nov 8, 2023
…AppDelegate (#41355)

Summary:
Pull Request resolved: #41355

This change expose a new API to react_native_pod to add dependencies that automatically configure their search paths when using frameworksa and with multiple Apple platforms.
It also migrates React-RCTAppDelegate to this new mechanism to test that it works.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51029484

fbshipit-source-id: 77dfe85419d495f7327a2f484d33f9ed8701e00d
facebook-github-bot pushed a commit to facebook/react-native that referenced this pull request Nov 8, 2023
Summary:
Pull Request resolved: #41356

React-Core does not depends on any bit of ReactCommon, React-RCTFabric or React-NativeModuleApple, so I'm cleaning that up.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51030115

fbshipit-source-id: f87dbfe99e90d52cf8c07057be22cd024e38db42
facebook-github-bot pushed a commit to facebook/react-native that referenced this pull request Nov 8, 2023
Summary:
Pull Request resolved: #41357

This change migrate React-RCTBlob to the new add_dependency to improve its compatibility with macOS and to remove some maintenance burden.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51030365

fbshipit-source-id: c4b9037d6d0223052d659c04a1f494508944ed2a
facebook-github-bot pushed a commit to facebook/react-native that referenced this pull request Nov 8, 2023
…41358)

Summary:
Pull Request resolved: #41358

This change expose a missing function to create Header Search Paths when a podspec can't depend on another one explicitly.
This also migrate the ruby code to this new function.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51068390

fbshipit-source-id: ba9e09cd2f0671a9f3f00cc72496a0d5682eeb90
facebook-github-bot pushed a commit to facebook/react-native that referenced this pull request Nov 8, 2023
Summary:
Pull Request resolved: #41359

This change migrates the remaining podspecs to the new functions, so we do not depend on hardcoded values anymore and we can scale the solution to other platforms.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51068403

fbshipit-source-id: 4c0455543363ccf4272d5e8590a7c663d9c33e8b
cipolleschi added a commit to facebook/react-native that referenced this pull request Nov 8, 2023
Summary:
Pull Request resolved: #41353

Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

In order to make the infra scalable and avoid a maintenance nightmare for macOS and future platform, we are introducing this function that should factor out the platforms from the generation of header search paths.

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51026356

fbshipit-source-id: 7cf03601d94d7680f3fdfcaf52b2fd6bcd48c5b4
cipolleschi added a commit to facebook/react-native that referenced this pull request Nov 8, 2023
Summary:
Pull Request resolved: #41354

In order to make the infra scalable and avoid a maintenance nightmare for macOS and future platform, we are introducing this function that automate adding a dependency to a podspec and it generates the required search paths.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51027343

fbshipit-source-id: 33ac4c07112eacb08067220397e38db0a19240fb
cipolleschi added a commit to facebook/react-native that referenced this pull request Nov 8, 2023
…AppDelegate (#41355)

Summary:
Pull Request resolved: #41355

This change expose a new API to react_native_pod to add dependencies that automatically configure their search paths when using frameworksa and with multiple Apple platforms.
It also migrates React-RCTAppDelegate to this new mechanism to test that it works.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51029484

fbshipit-source-id: 77dfe85419d495f7327a2f484d33f9ed8701e00d
cipolleschi added a commit to facebook/react-native that referenced this pull request Nov 8, 2023
Summary:
Pull Request resolved: #41356

React-Core does not depends on any bit of ReactCommon, React-RCTFabric or React-NativeModuleApple, so I'm cleaning that up.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51030115

fbshipit-source-id: f87dbfe99e90d52cf8c07057be22cd024e38db42
cipolleschi added a commit to facebook/react-native that referenced this pull request Nov 8, 2023
Summary:
Pull Request resolved: #41357

This change migrate React-RCTBlob to the new add_dependency to improve its compatibility with macOS and to remove some maintenance burden.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51030365

fbshipit-source-id: c4b9037d6d0223052d659c04a1f494508944ed2a
cipolleschi added a commit to facebook/react-native that referenced this pull request Nov 8, 2023
…41358)

Summary:
Pull Request resolved: #41358

This change expose a missing function to create Header Search Paths when a podspec can't depend on another one explicitly.
This also migrate the ruby code to this new function.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51068390

fbshipit-source-id: ba9e09cd2f0671a9f3f00cc72496a0d5682eeb90
cipolleschi added a commit to facebook/react-native that referenced this pull request Nov 8, 2023
Summary:
Pull Request resolved: #41359

This change migrates the remaining podspecs to the new functions, so we do not depend on hardcoded values anymore and we can scale the solution to other platforms.

Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51068403

fbshipit-source-id: 4c0455543363ccf4272d5e8590a7c663d9c33e8b
@cipolleschi
Copy link
Author

facebook#41353 landed and I created facebook#41380 against 0.73.

Once that is merged into the stable branch and react-native-macos is synched with that branch, this pr will just a change in react_native_pods.rb#L70:

def prepare_react_native_project!
  # Temporary solution to suppress duplicated GUID error.
  # Can be removed once we move to generate files outside pod install.
  install! 'cocoapods', :deterministic_uuids => false

  ReactNativePodsUtils.create_xcode_env_if_missing
end

+ $RN_PLATFORMS = ['iOS', 'MacOS']

Othinn pushed a commit to Othinn/react-native that referenced this pull request Jan 9, 2024
Summary:
Pull Request resolved: facebook#41353

Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

In order to make the infra scalable and avoid a maintenance nightmare for macOS and future platform, we are introducing this function that should factor out the platforms from the generation of header search paths.

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51026356

fbshipit-source-id: 7cf03601d94d7680f3fdfcaf52b2fd6bcd48c5b4
Othinn pushed a commit to Othinn/react-native that referenced this pull request Jan 9, 2024
Summary:
Pull Request resolved: facebook#41354

In order to make the infra scalable and avoid a maintenance nightmare for macOS and future platform, we are introducing this function that automate adding a dependency to a podspec and it generates the required search paths.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51027343

fbshipit-source-id: 33ac4c07112eacb08067220397e38db0a19240fb
Othinn pushed a commit to Othinn/react-native that referenced this pull request Jan 9, 2024
…AppDelegate (facebook#41355)

Summary:
Pull Request resolved: facebook#41355

This change expose a new API to react_native_pod to add dependencies that automatically configure their search paths when using frameworksa and with multiple Apple platforms.
It also migrates React-RCTAppDelegate to this new mechanism to test that it works.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51029484

fbshipit-source-id: 77dfe85419d495f7327a2f484d33f9ed8701e00d
Othinn pushed a commit to Othinn/react-native that referenced this pull request Jan 9, 2024
Summary:
Pull Request resolved: facebook#41356

React-Core does not depends on any bit of ReactCommon, React-RCTFabric or React-NativeModuleApple, so I'm cleaning that up.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51030115

fbshipit-source-id: f87dbfe99e90d52cf8c07057be22cd024e38db42
Othinn pushed a commit to Othinn/react-native that referenced this pull request Jan 9, 2024
Summary:
Pull Request resolved: facebook#41357

This change migrate React-RCTBlob to the new add_dependency to improve its compatibility with macOS and to remove some maintenance burden.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51030365

fbshipit-source-id: c4b9037d6d0223052d659c04a1f494508944ed2a
Othinn pushed a commit to Othinn/react-native that referenced this pull request Jan 9, 2024
…acebook#41358)

Summary:
Pull Request resolved: facebook#41358

This change expose a missing function to create Header Search Paths when a podspec can't depend on another one explicitly.
This also migrate the ruby code to this new function.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51068390

fbshipit-source-id: ba9e09cd2f0671a9f3f00cc72496a0d5682eeb90
Othinn pushed a commit to Othinn/react-native that referenced this pull request Jan 9, 2024
Summary:
Pull Request resolved: facebook#41359

This change migrates the remaining podspecs to the new functions, so we do not depend on hardcoded values anymore and we can scale the solution to other platforms.

## Context
Last week I helped macOS to work with static framework.
When multiple platforms are specified, frameworks are build in two variants, the iOS and macOS one.

This break all the HEADER_SEARCH_PATHS as now we have to properly specify the base folder from which the search path is generated.
See also [this PR](microsoft#1967) where I manually make MacOS work with `use_framewroks!`

## Changelog:
[Internal] - Add helper function to create header_search_path

Reviewed By: shwanton

Differential Revision: D51068403

fbshipit-source-id: 4c0455543363ccf4272d5e8590a7c663d9c33e8b
@Saadnajmi
Copy link
Collaborator

facebook#41353 landed and I created facebook#41380 against 0.73.

Once that is merged into the stable branch and react-native-macos is synched with that branch, this pr will just a change in react_native_pods.rb#L70:

def prepare_react_native_project!
  # Temporary solution to suppress duplicated GUID error.
  # Can be removed once we move to generate files outside pod install.
  install! 'cocoapods', :deterministic_uuids => false

  ReactNativePodsUtils.create_xcode_env_if_missing
end

+ $RN_PLATFORMS = ['iOS', 'MacOS']

I think we've merged both commits, so I'll try to put up a PR in the coming weeks to add the support. It's lower priority for me right now, so it might be a bit :/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants