Skip to content

Correctly propagate RN_SERIALIZABLE_STATE to 3rd party CMake targets#51619

Closed
cortinico wants to merge 1 commit into
facebook:mainfrom
cortinico:export-D75441245
Closed

Correctly propagate RN_SERIALIZABLE_STATE to 3rd party CMake targets#51619
cortinico wants to merge 1 commit into
facebook:mainfrom
cortinico:export-D75441245

Conversation

@cortinico
Copy link
Copy Markdown
Contributor

Summary:
RNTester Android is currently instacrashing in OSS due to 3rd-party packages not having the RN_SERIALIZABLE_STATE definition.
That's because the INTERFACE definition is not properly propagated on the prefab boundaries.

This was happening for react-native-popup-menu-android and react-native-test-library and will also happen for Codegen libraries.

This fixes it. 3p developers with custom CMake files will also have to use the target_compile_reactnative_options functions to make sure the compilation flag are properly populated.

Changelog:
[Android] [Changed] - Correctly propagate RN_SERIALIZABLE_STATE to 3rd party CMake targets

Differential Revision: D75441245

Summary:
RNTester Android is currently instacrashing in OSS due to 3rd-party packages not having the `RN_SERIALIZABLE_STATE` definition.
That's because the `INTERFACE` definition is not properly propagated on the prefab boundaries.

This was happening for `react-native-popup-menu-android` and `react-native-test-library` and will also happen for Codegen libraries.

This fixes it. 3p developers with custom CMake files will also have to use the `target_compile_reactnative_options` functions to make sure the compilation flag are properly populated.

Changelog:
[Android] [Changed] - Correctly propagate RN_SERIALIZABLE_STATE to 3rd party CMake targets

Differential Revision: D75441245
@facebook-github-bot facebook-github-bot added CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. p: Facebook Partner: Facebook Partner labels May 27, 2025
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request was exported from Phabricator. Differential Revision: D75441245

@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request has been merged in c059ae1.

@react-native-bot
Copy link
Copy Markdown
Collaborator

This pull request was successfully merged by @cortinico in c059ae1

When will my fix make it into a release? | How to file a pick request?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported Merged This PR has been merged. p: Facebook Partner: Facebook Partner

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants