[RCTImageLoader] Make C++ requirement opt-in #27731
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Note that this is the back ported version of #27730, so the description is the same.
Summary
When building as a framework these headers get automatically added to the framework umbrella header for React-Core. Instead of converting all the React sources to ObjC++ files and still forcing external users that build native source (and link against a framework build) to also compile as ObjC++, this makes the attribution related methods that were added in fdcdca4 opt-in to ObjC++ builds.
This is also the reason for the current failure of the CI
test_ios_frameworks
run.Changelog
I’m unsure if this change really warrants an entry in the CHANGELOG, as it’s more of an amendment of the (afaik) unreleased change.
[iOS] [Fixed] - Make framework builds work again by making
RCTImageLoader
C++ requirement opt-inTest Plan
I tested static and dynamic (framework) builds and ran the test suite.
This change should make the
test_ios_frameworks
CI run build again, but it may still fail overall as in my local testing one of the tests leads to a segfault (which I will try to address separately).