fix(ios): strip the provider xcframework modulemaps - #553
Open
Imod7 wants to merge 7 commits into
Open
Conversation
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.
Related to #442
Description
The published
@parity/ios-providerxcframework ships amodule.modulemapin each slice. Xcode flattens every slice'sHeadersinto one include directory, so it collides with any other UniFFI xcframework in the same app and the release asset cannot be used. Staging now strips them, the way the host package already does, and bothpublish.shscripts refuse a framework that still carries one.New
ios/truapi-provider/scripts/stage-xcframework.sh, called byrebuild.sh, covered byscripts/lib/xcframework-staging.test.mjs. The module keeps resolving through the committedSources/truapi_providerFFI/include/module.modulemap, which is untouched. Docs only:Package.swiftand the README no longer say no release exists, andrebuild.shprintsTRUAPI_PROVIDER_USE_LOCAL_BINARY=1, the variable the binary target reads.Testing
The published asset is the defect, so the check stages it with the new script.
0.7.0diff -rbetween the two reports the two modulemaps and nothing else. The publish guard, run in isolation, exits 66 on the published tree and 0 on the staged one.npm run test:scriptspasses 39, four of them new.swift package dump-packageparses.Not run locally: building the framework from source needs Xcode, and
publish.shcreates a GitHub release. CI'sios-swiftjob runsrebuild.sh --sim-only, which now calls staging.The published
0.7.0asset stays unstripped. This fixes the next publish, not the last one.