Skip to content

Fix ImageRequestParams.h not found in ReactCodegen with static frameworks - #60225

Open
intergalacticspacehighway wants to merge 1 commit into
mainfrom
@nishan/fix-reactcodegen-imagemanager-static-frameworks
Open

intergalacticspacehighway wants to merge 1 commit into
mainfrom
@nishan/fix-reactcodegen-imagemanager-static-frameworks

Conversation

@intergalacticspacehighway

@intergalacticspacehighway intergalacticspacehighway commented Nov 23, 2026 •

Copy link
Copy Markdown
Collaborator

Summary:

Since 0.89.0-rc.0, the iOS build fails with static frameworks when React Native is built from source and a codegen spec has an ImageSource prop. @react-native-community/slider, react-native-svg, and react-native-screens all hit this.

React_Fabric.framework/Headers/react/renderer/imagemanager/ImageManager.h:17:10:
fatal error: 'react/renderer/imagemanager/ImageRequestParams.h' file not found

Regressed by #58730, which made codegen emit umbrella includes. Generated Props.h now includes <React/ImageManager.h>. That umbrella includes ImageManager.h, which needs ImageRequestParams.h from React_ImageManager.framework. The ReactCodegen pod has no header search path for that framework. Library pods already get it from new_architecture.rb.

This change adds React-ImageManager to the ReactCodegen framework header search paths. The prebuilt core is not affected.

Changelog:

[IOS] [FIXED] - Fix ImageRequestParams.h not found in codegen with static frameworks

Test Plan:

Repro: https://github.com/intergalacticspacehighway/rn-static-frameworks-imagesource-repro (RN CLI app on 0.89.0-rc.2 with @react-native-community/slider@5.2.2).

USE_FRAMEWORKS=static RCT_USE_RN_DEP=0 RCT_USE_PREBUILT_RNCORE=0 bundle exec pod install
xcodebuild -workspace SliderRepro.xcworkspace -scheme SliderRepro \
  -configuration Release -sdk iphonesimulator -derivedDataPath build
  • Without this change: BUILD FAILED with the error above.
  • With this line applied to the 0.89.0-rc.2 template in the repro: BUILD SUCCEEDED. The template on main is the same.
  • jest packages/react-native/scripts/codegen/__tests__/generate-artifacts-executor-test.js: 52 passed. The 2 snapshots are updated for the new line.

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Nov 23, 2026
@intergalacticspacehighway
intergalacticspacehighway force-pushed the @nishan/fix-reactcodegen-imagemanager-static-frameworks branch from 042d666 to 26ca996 Compare November 23, 2026 08:36
…orks

With `use_frameworks!` and React Native built from source, generated
component code fails to compile when a spec has an `ImageSource` prop.
Generated `Props.h` includes `<React/ImageManager.h>`, which reaches
`ImageRequestParams.h` in `React_ImageManager.framework`. The
`ReactCodegen` pod has no header search path for that framework.
@intergalacticspacehighway
intergalacticspacehighway force-pushed the @nishan/fix-reactcodegen-imagemanager-static-frameworks branch from 26ca996 to 6860cf0 Compare November 23, 2026 08:37
@intergalacticspacehighway
intergalacticspacehighway marked this pull request as ready for review November 23, 2026 08:37
@facebook-github-tools facebook-github-tools Bot added the Shared with Meta Applied via automation to indicate that an Issue or Pull Request has been shared with the team. label Nov 23, 2026

This branch has not been deployed

No deployments
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. Shared with Meta Applied via automation to indicate that an Issue or Pull Request has been shared with the team.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant