Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[main] Enable -user-module-version for 6.0 #7263

Merged
merged 5 commits into from
May 29, 2024
Merged

Conversation

MaxDesiatov
Copy link
Member

@MaxDesiatov MaxDesiatov commented Jan 17, 2024

Summary:
#if canImport(LibFoo, _version: "1.2.3") is not currently supported by SwiftPM, as this feature was gated on .vNext, even though it landed before SwiftPM 5.10 branched off.

Steps To Reproduce:

  1. Build a package with // swift-tools-version: 6.0 and try to use #if canImport(LibFoo, _version: "1.2.3") for a dependency LibFoo.

Results:
The availability check won't work because -user-module-version option is not passed correctly to the build system.
rdar://121124842 fixed.

This was gated on `.vNext` previously, even though it was introduced before 5.10 branched off. It feels safe to enable this in 5.10.
@MaxDesiatov
Copy link
Member Author

@swift-ci test

1 similar comment
@MaxDesiatov
Copy link
Member Author

@swift-ci test

@MaxDesiatov MaxDesiatov changed the title Enable -user-module-version for 5.10 [main] Enable -user-module-version for 5.10 Jan 18, 2024
@MaxDesiatov MaxDesiatov changed the title [main] Enable -user-module-version for 5.10 [main] Enable -user-module-version for 5.11 Jan 19, 2024
@MaxDesiatov
Copy link
Member Author

@swift-ci test

@MaxDesiatov
Copy link
Member Author

@swift-ci test windows

@MaxDesiatov MaxDesiatov added the needs tests This change needs test coverage label Mar 4, 2024
@MaxDesiatov MaxDesiatov changed the title [main] Enable -user-module-version for 5.11 [main] Enable -user-module-version for 6.0 Mar 4, 2024
@MaxDesiatov
Copy link
Member Author

@swift-ci test

@bnbarham
Copy link
Contributor

@swift-ci please test Windows platform

@MaxDesiatov
Copy link
Member Author

@swift-ci test windows

@MaxDesiatov
Copy link
Member Author

@swift-ci test

@MaxDesiatov MaxDesiatov added build system Changes to interactions with build systems package manifests changes to package manifest APIs and removed needs tests This change needs test coverage labels May 29, 2024
@MaxDesiatov MaxDesiatov enabled auto-merge (squash) May 29, 2024 15:28
@MaxDesiatov
Copy link
Member Author

@swift-ci test linux

@MaxDesiatov MaxDesiatov merged commit a539996 into main May 29, 2024
5 checks passed
@MaxDesiatov MaxDesiatov deleted the maxd/user-module-version branch May 29, 2024 19:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug build system Changes to interactions with build systems package manifests changes to package manifest APIs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants