Skip to content

Fix build error on iOS with use_frameworks - #612

Merged
wcandillon merged 1 commit into
wcandillon:mainfrom
Critteros:fix/ios-use-frameworks-header-paths
Nov 6, 2026
Merged

wcandillon merged 1 commit into
wcandillon:mainfrom
Critteros:fix/ios-use-frameworks-header-paths

Conversation

@Critteros

Copy link
Copy Markdown
Contributor

Apps that use use_frameworks! do not compile. Some apps need it, for example apps with Firebase.

cpp/rnwgpu/RNWebGPUManager.h:5:10: fatal error: 'GPU.h' file not found

Cause: the sources include headers from other folders by file name only (#include "GPU.h"). Without frameworks, CocoaPods copies all headers into one flat folder (Pods/Headers/Private), and these includes resolve there. With frameworks, CocoaPods does not make that folder. Xcode's header map could also find them, but #438 turned it off to stop Skia headers from leaking in.

Fix: add each source folder that holds headers to HEADER_SEARCH_PATHS. It is the same list as internalHeaderDirs in Package.swift

Sources include headers from other folders by bare name ("GPU.h").
use_frameworks! drops Pods/Headers/Private and the header map is
off (wcandillon#438), so those includes failed with "file not found". Put
every folder of internalHeaderDirs on HEADER_SEARCH_PATHS, the
same list the Swift package uses.
@wcandillon
wcandillon self-requested a review November 6, 2026 16:38
@wcandillon
wcandillon merged commit 88546a3 into wcandillon:main Nov 6, 2026
6 checks passed
@wcandillon

Copy link
Copy Markdown
Owner

Thank You 💚

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.

2 participants