Fix PIF MODULEMAP_PATH when a package has a hand-authored module map#10065
Merged
Conversation
Contributor
Author
|
@swift-ci test |
pmattos
approved these changes
May 15, 2026
Contributor
|
For reference: follow-up to our previous fix in |
jakepetroules
approved these changes
May 15, 2026
Contributor
|
Windows failure looks legitimate: |
Contributor
This looks more like a path separator issue with the test. The actual is The expected has a single it's the same with the second expectation failure. |
98d8360 to
64dcc84
Compare
Contributor
Author
|
@swift-ci test |
Contributor
Author
|
@swift-ci test windows |
Contributor
Author
|
@swift-ci test macOS |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
When a target had a hand-authored module map, the PIF was correctly imparting the custom path to clients via OTHER_CFLAGS, but was incorrectly setting MODULEMAP_PATH to the path which would have been used if the build system had generated one. This doesn't impact compilation, but when symbol graph extraction was enabled it caused clang -extractapi to try to load the module map from the wrong path, failing the build.
This PR refactors the modulemap path computation so that it is explicitly assigned once along every path, fixing the original issue and hopefully making the code a bit clearer so it's easier to understand going forward.
rdar://173020089