fix: compilation on x86_64-swift-linux-musl#271
Merged
Conversation
Owner
|
Thank you for the PR. The PR you submitted to ObjectArchiveKit has already been merged, and a new version has been released. |
Contributor
Author
|
Should I bump ObjectArchiveKit and then update my PR to MachOKit? |
Contributor
Author
|
@p-x9 I also bumped ObjectArchiveKit to 0.5.0 to have consistent PR, that adds support for cross-compilation. Can you make, please, a release of MachOKit, after currnt PR will be merged? |
e95d846 to
21d0ae1
Compare
Owner
|
Sorry for the delayed response—I’ve been quite busy. Thank you for updating the version and fixing the CI as well. |
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 building for
x86_64-swift-linux-musl:the build failed with
no such module 'Crypto'error:That happens when cross-compiling on macOS to linux due to the reason, that
#if (os(macOS) || os(iOS) || os(watchOS) || os(tvOS)) && canImport(CommonCrypto)evaluates on macOs, so the
swift-cryptowon't be added as a dependency. So we have to declare the packageswift-cryptounconditionally, conditionally link the product for linux platforms.Note: the
x86_64-swift-linux-musltoolchain is installed viaswiftly; the active toolchain should also be managed byswiftly >= 6.3.0as on lower versions there was a compiler crash. For validating build onx86_64-swift-linux-muslthe patch from p-x9/ObjectArchiveKit#5 is also required.