Conversation
|
@artemcm, please run the CI on this. |
|
@swift-ci test |
|
Windows CI failure is unrelated, all pulls are failing on the Windows CI. |
|
@artemcm, now that the CI is working, would you run it again? |
|
@swift-ci test |
|
Rebased, need another CI run. |
|
@swift-ci test |
|
@swift-ci test |
|
@swift-ci test macos |
|
@swift-ci test |
|
@artemcm, can we go ahead and get this in before the upcoming branch? @al45tair once expressed interest in testing this more last summer in the linked Driver pull but hasn't responded since, and we have plenty of data that it is unlikely to break anything as it has been the default Unix archiver for SwiftPM for the last year and a half, swiftlang/swift-package-manager#6829. If you're okay with merging this, which requires approval from someone like you, please approve and I'll go ahead and merge this and the Driver pull, which doesn't require anything else. |
|
I'm honestly not sure this is a desirable change. As I observed previously, almost nobody uses I think we should be using the system librarian ( @compnerd, WDYT? |
I don't see why you think he'd agree with you, considering we switched SwiftPM to default to I am skeptical that there are any worthwhile differences in what |
Now that llvm-ar is installed by default in the toolchain, swiftlang/swift#62510, and a recent SPM change requires there to be an archiver in the toolchain/PATH, swiftlang/swift-package-manager#5761, use that bundled llvm-ar for all Unix platforms.
|
@swift-ci test |
cachemeifyoucan
left a comment
There was a problem hiding this comment.
I feel like using llvm-ar is totally fine but should we just symlink llvm-ar to ar on platforms what to use that as default instead?
|
Not sure what you mean, as we currently include llvm-ar in the Swift toolchain and SwiftPM defaults to using it for non-Windows/non-Darwin triples, falling back to looking for This pull simply changes the compiler to do the same, ie only look for llvm-ar when archiving static libraries for Unix platforms using the Swift compiler itself. If you want a completely different librarian when invoking SwiftPM, you can always provide an override to SwiftPM using As for platforms that want to use |
|
I mean if we are preferring I have no real objection of the function changed to use llvm-ar for creating static archive. |
There was a problem hiding this comment.
.a files are not in a standardised format, and llvm-ar does not necessarily create archives that are compatible with the system archiver. We should use the system archiver, unless we know we're using lld. (See Wikipedia)
We should not merge this.
|
Don't worry, I don't try to sneak pulls by people, will look at the underlying format and let you know. |
|
To be clear, I'm not trying to be awkward here; it is genuinely the case that AFAIK the most obvious problem areas involve indices (the thing that either |
Now that llvm-ar is installed by default in the toolchain, swiftlang/swift#62510, and a recent SwiftPM change requires there to be an archiver in the toolchain/PATH, swiftlang/swift-package-manager#5761, use that bundled llvm-ar for all Unix platforms.
This is the Swift translation of swiftlang/swift#62800.