Commit Graph

19 Commits

Author SHA1 Message Date
Christian Falch 4c9431adda Update podspecs to use the ReactNativeDependencies or build from source (#49968)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/49968

Updates all the core podspec to use the new `ReactNativeDependencies` podspec

## Changelog:

[INTERNAL] - Updates Modules in core to use the new dependencies.

Test Plan:
 Run Rn-Tester and  verify that it works as expected both building deps from source and using prebuilt tarballs
 Add third-party library (react-native-reanimated) and perform the same tests to verify that it works with the changed podspec and utilities

Reviewed By: cortinico

Differential Revision: D71032639

Pulled By: cipolleschi

fbshipit-source-id: e53179a8c1b47ee2b945f5cb5dfaf3f6f2755af2
2025-03-13 08:40:14 -07:00
Oskar Kwaśniewski e7de582798 feat(iOS): centralize JS engine dependency configuration (#49297)
Summary:
> [!NOTE]
> This PR is part of JavaScriptCore Extraction to this repository: https://github.com/react-native-community/javascriptcore

This PR centralizes the setup of js engine dependencies which need to be defined when building with dynamic frameworks. This will allow us to change linked framework if using a third party one in the future

## Changelog:

[INTERNAL] [CHANGED] - centralize JS engine dependency configuration

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

Test Plan: CI Green (Build needs to go properly)

Reviewed By: javache

Differential Revision: D69396641

Pulled By: cipolleschi

fbshipit-source-id: deedd12084f563f73f12f8617fdca0a6d680bf5a
2025-02-11 10:03:07 -08:00
Riccardo Cipolleschi 6e2ba742ff Factor out the CXX language standard in a separate const (#45374)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/45374

This change factors out the language standard in a separate constant so we can easily control it from a single place.

There are only 2 exception to this:
1. hermes-engine: the podspec is used in CI and it has no access to the rct_cxx_language_standard variable
2. Yoga: it can be used as a separate pod, outside of React Native, so it makes sense to leave it alone.

This change also fixes a problem where, in some setup, the language was set to C++14

## Changelog
[Internal] - Refactor Cxx language standard in a single constant

Reviewed By: dmytrorykun, blakef

Differential Revision: D59629061

fbshipit-source-id: 41eac64e47c14e239d8ee78bd88ea30af244d695
2024-07-11 05:25:38 -07:00
Dmitry Rykun 6549216b76 Rename React-Codegen to ReactCodegen
Summary:
This diff renames React-Codegen to ReactCodegen. This way we'll no longer have to try both
```
#include <React-Codegen/MyModule.h>
```
and additionally
```
#include <React_Codegen/MyModule.h>
```
for cases with `use_frameworks`.

Changelog: [iOS][Breaking] - Rename React-Codegen to ReactCodegen

Reviewed By: cipolleschi

Differential Revision: D54068492

fbshipit-source-id: dab8ea2034d299266482929061caa14397421445
2024-02-22 09:52:48 -08:00
Riccardo Cipolleschi 1204696f08 Defragment Codegen in OSS between Old and New Architecture (#41500)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/41500

Right now, the old architecture uses Codegen in a slightly different way w.r.t. the New Architecture.
In the Old Architecture, codegen is used to generate some basic TM and components that are part of Core.

Both architectures use the same scripts that actually generates the code, but they are invoked differently.

This is causing some maintenance costs that we would like to reduce.

## Changelog:
[Internal] - Defragment how Codegen is run between old and new architecture

Reviewed By: dmytrorykun

Differential Revision: D51349874

fbshipit-source-id: 188d3ed436a30a77bd42a26306d4a08666d3a00b
2023-11-17 04:17:58 -08:00
Kudo Chien b9f0bdd12d Remove xcode 15 workaround for boost (#39555)
Summary:
Remove Xcode 15 `_LIBCPP_ENABLE_CXX17_REMOVED_UNARY_BINARY_FUNCTION` workaround for boost. If we update boost, we don't need the workaround anymore.
This PR is based on https://github.com/facebook/react-native/issues/39552. Not sure how Meta internally deal with stacked PRs. This PR just adds a new commit based on https://github.com/facebook/react-native/issues/39552 anyway.

## Changelog:

[IOS][CHANGED] - Remove Xcode 15 `_LIBCPP_ENABLE_CXX17_REMOVED_UNARY_BINARY_FUNCTION` workaround for boost

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

Test Plan: RNTester + Xcode 15

Reviewed By: cortinico

Differential Revision: D49454494

Pulled By: cipolleschi

fbshipit-source-id: aacabaa130b61598cf8bd206fdbb96d3b50ba74f
2023-09-20 06:03:54 -07:00
Nick Gerleman 17154a661f C++ 20 all the things (#39454)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/39454

1. Build with C++ 20 everywhere.
2. Update folly in OSS build to avoid a warning, and let us opt out of heavy bits required for supporting coroutines (we are still more than a year behind).
3. Update the folly podspec for the new version of folly
4. Update the many, many, copy/pasted header search paths for folly dependencies to be able to resolve fmt, now exposed to folly headers
4. Replaces a deprecated atomic usage with equivalent.
5. Fixes a deprecated implicit capturing `this` by value in lambda (same behavior, added a TODO because it seems sus)

Changelog: [Internal]

Reviewed By: sammy-SC

Differential Revision: D49271685

fbshipit-source-id: 16610f7bcd1032d5796cc11f1cfa92a33d8c2593
2023-09-15 01:17:55 -07:00
Saad Najmi 1b78da8b43 min_ios_version_supported -> min_supported_versions (#39310)
Summary:
## Summary:

One of the most common diffs we have in React Native macOS is simply extending the `platforms` key Inside every pod spec to include macOS. React Native tvOS does the same to add tvOS. In the future, React Native may support visionOS, at which point we do the same thing again. Let's define a `min_supported_versions` hash that can be overridden at one place that is extensible to more platforms, instead of just specifying `min_ios_version_supported`.

Note: In doing this change, I have set it that `React-Hermes.podspec` doesn't build for macOS anymore. I think this is safe, since anyone using Hermes on macOS was probably using React Native macOS where we already have a diff to add macOS back?

## Changelog:

[IOS] [CHANGED] - Add min_supported_versions helper to cocoa pods scripts

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

Test Plan: CI should pass.

Reviewed By: NickGerleman

Differential Revision: D49014109

Pulled By: dmytrorykun

fbshipit-source-id: d44fc7b750c70cc263a2c89502c022a0db9a4771
2023-09-07 03:16:23 -07:00
Riccardo Cipolleschi 610b14e4f3 Move min ios version to 13.4 for OSS (#36795)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/36795

This change bump the min iOS version for React Native to 13.4, to align with company guidelines.

## Changelog:
[iOS][Changed] - Moved the min iOS version to 13.4

Reviewed By: cortinico

Differential Revision: D44634663

fbshipit-source-id: 035e8fcbb395f7394f8253e3ec485ad9937531c2
2023-04-06 12:07:26 -07:00
Ruslan Lesiutin 714b502b0c | RN Monorepo | Migrate to package (#36434)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/36434

Changelog: [Internal]

This is a squashed stack of 18 commits, starting from D43202126

allow-large-files

Reviewed By: cortinico

Differential Revision: D43977381

fbshipit-source-id: 0da552ddb85f2f61a0be0ef071915b35f3f8555c
2023-03-17 05:03:25 -07:00
Christoph Purrer 19d65a2baf Update .podspec license information (#35245)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/35245

Changelog: [Internal]

Reviewed By: cipolleschi

Differential Revision: D41084913

fbshipit-source-id: a4ba31a19ffe515aa4e7c5a6e273a8cc4b6bc42d
2022-11-07 09:52:52 -08:00
Christoph Purrer 089684ee56 Remove remaining TV_OS fragments (#35110)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/35110

Changelog:
[General][Fixed] Remove remaining TV_OS fragments

Reviewed By: shwanton

Differential Revision: D40775881

fbshipit-source-id: 122ff8737de35689ee0951b068997ee546c7019c
2022-10-28 02:50:49 -07:00
Riccardo Cipolleschi 82e9c6ad61 Simplify the dependencies migration for new libraries (#34619)
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/34619

When it comes to migrate existing libraries, users needs to update their .podspec files with a bunch [of changes](https://reactnative.dev/docs/0.69/new-architecture-library-ios#add-folly-and-other-dependencies).
This diff groups those changes in a single function, so that contributors can just invoke that function to prepare their dependencies.

## Changelog

[iOS][Changed] - Add function to simplify podspecs

Reviewed By: cortinico

Differential Revision: D39312203

fbshipit-source-id: ed631839e07d472a1fdcba33310f9b1d94fe2fd7
2022-09-09 04:25:56 -07:00
Luis Santana 68f3a42fc7 bump RTC-Folly to 2021.07.22 (#33841)
Summary:
Bumping RTC-Folly version used to address CVE-2022-24440.

## Changelog

<!-- Help reviewers and the release process by writing your own changelog entry. For an example, see:
https://github.com/facebook/react-native/wiki/Changelog
-->

[General][Security] - Bump RTC-Folly to 2021-07-22

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

Reviewed By: Andjeliko, philIip

Differential Revision: D36425598

Pulled By: cortinico

fbshipit-source-id: d38c5f020dbecf794b10f12ed2da30e1825071af
2022-06-21 12:36:43 -07:00
Phillip Pan 982ca30de0 bump iOS and tvOS from 11.0 to 12.4 in cocoapods
Summary:
Changelog: [iOS][Deprecated] Deprecating support for iOS/tvOS SDK 11.0, 12.4+ is now required

allow-large-files

Reviewed By: sammy-SC

Differential Revision: D34547333

fbshipit-source-id: a24bb09d03939a092de4198efb1aa4a44c69f718
2022-03-16 21:08:01 -07:00
Kudo Chien a6c2846b37 Fix ios build error when use_frameworks is on and fabric is off (v2) (#33409)
Summary:
alternative solution for https://github.com/facebook/react-native/issues/33379

> when `use_frameworks!` is on, there are errors like:
> ```
> 'FBReactNativeSpec/FBReactNativeSpec.h' file not found
> #import <FBReactNativeSpec/FBReactNativeSpec.h>
> ```
> this error may come from from https://github.com/facebook/react-native/commit/f7e4c07c84b6 regression.
>
> when `use_frameworks!` is on, xcode will search headers from framework directories, the correct imports would be `#import <React_Codegen/FBReactNativeSpec/FBReactNativeSpec.h>` (xcode will transform dash to underscore, so it is `React_Codegen` but not `React-Codegen`). in the other hand, when `use_frameworks!` is off, the correct import is `#import <React-Codegen/FBReactNativeSpec/FBReactNativeSpec.h>`.
>
>
> this fix is specific for old architecture (fabric is off).
>
> when fabric is on, there are other errors from duplicated headers when copying to build folder. [the reason is that framework build would try to flatten headers](https://mkonrad.net/2015/03/29/xcode-static-libraries-preserving-header-directory-structure.html). we have `primitives.h` in different folders and they would be flattened into `React_Fabric.framework/Headers`. to be honest, i don't know how to deal with the problem in the meantime,  maybe subspecs are not enough, we should separate them from subspecs to dedicated podspecs so that we can have these targets as different frameworks.

in this alternative fix, i try to add `React-Codegen/React_Codegen.framework/Headers` into header search paths and make original `#import <FBReactNativeSpec/FBReactNativeSpec.h>` reachable.

[this change](https://github.com/facebook/react-native/commit/7a0398c331f22abc619a64b444ec7153357b0a30) in the pr is just a workaround to solve breaking in latest main branch and this is not important to the `use_frameworks!` fix at all. this breaking was coming from https://github.com/facebook/react-native/commit/180495159517dc0bfa103621e5ff62fc04cb3c8b.

## Changelog

[iOS] [Fixed] - Fix iOS build error when Podfile `use_frameworks!` is on and Fabric is off

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

Test Plan:
verify with rn-tester
1. change `fabric_enabled` to false in `packages/rn-tester/Podfile`
2. `USE_FRAMEWORKS=1 pod install`
3. build rn-tester in xcode

Reviewed By: dmitryrykun

Differential Revision: D34817041

Pulled By: cortinico

fbshipit-source-id: 4d1a610e99a807793eb3f64461e0d735c0a9ca9c
2022-03-11 09:08:07 -08:00
Samuel Susla c2e4ae39b8 Add support for C++17 in OSS
Summary: changelog: Add support for C++17

Reviewed By: cortinico

Differential Revision: D34612257

fbshipit-source-id: 88a0307a750f2e0793a639b7a2b670a4571332fe
2022-03-04 07:25:59 -08:00
Andres Suarez 8bd3edec88 Update copyright headers from Facebook to Meta
Reviewed By: aaronabramov

Differential Revision: D33367752

fbshipit-source-id: 4ce94d184485e5ee0a62cf67ad2d3ba16e285c8f
2021-12-30 15:11:21 -08:00
Sota Ogo d29f3d2a6b Add a simple fabric component example
Summary:
This diff adds a very simple example to show the use of new architecture in a component.

Changelog: [internal]

Reviewed By: cortinico

Differential Revision: D32045059

fbshipit-source-id: f388bfb765241122de425fbef61cea0620cd31ac
2021-11-17 16:01:55 -08:00