-
Notifications
You must be signed in to change notification settings - Fork 16
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
Unable to create Bookworm SDK (unclear documentation) #189
Comments
Looks like you have a typo in your tag name. It should be:
Without the last |
Hi @dscreve, would you be able to confirm that the issue is resolved for you when using the proposed tag name? |
Hello, This works fine, but If I use an amd64 image on Mac M1, it does not works. Only arm64 image works. I have created an amd64 Linux image from with this docker file : Then, use this command : And I have the following error messages : If I go into the Bundles/6.0.3-bookworm-amd64.artifactbundle/6.0.3-bookworm-amd64 directory, I have a directory named And I don't know if Glibc has been selected instead of Musl David |
@dscreve you have to provide the --target param as well: If your container arch doesn't match the target arch it will certainly have issues. So, the full command should be:
|
Thanks ! this works fine for sdk creation. What are the accepted values for --parameters ? readme.md documentation seems to be outdated and incomplete. Now, I try to compile a project on my Mac using x86-64 and aarch64 SDK. I get some warnings : warning: libc not found for 'x86_64-unknown-linux-gnu'; C stdlib may be unavailable And when compiling, I get compilation errors : any idea how to fix it ? David |
Um....I think that CryptoKit is not available on Linux platforms...am I correct @MaxDesiatov ? |
You should use swift-crypto instead, which will switch between CryptoKit and the OSS shims over BoringSSL, depending on the OS you're targeting. |
You can ignore these warnings:
#185 should fix this warning
swiftlang/swift#76545 should fix this warning |
You are right ! I will fix this. |
Thanks for checking! I'll keep this open as a reminder for documentation improvements. |
I replaced CryptoKit with swift-crypto, but still have the issue : import Crypto Any idea ? |
Does it build on macOS without cross compilation that way? If not, I'd say this is specific to your package and is not caused by Swift SDK Generator. First thing to look for would be target/product dependencies not specified in |
I think I have fixed this, but I cannot check because I have a compiler crash. |
Would you mind linking to the crash bugreport here? |
Actually it is related to the use of CryptoKit that I missed and that cause compiler error because it use static method of CryptoKit. Issue was encountered in standard linux compilation. That's not related to SDK usage. |
Good news : Everything is compiling now...but I'm linking against libcrypto (openSSL) and it does not work. I have installed libssl-dev in docker Image as below : But I don't know how to tell him to add it in the generated SDK and I have the following error : I have openSSL installed on the Mac, and It seems to try to look in the Mac library : I have created another issue for that. |
Just enter the following command :
$> swift run swift-sdk-generator make-linux-sdk --with-docker --from-container-image swift:6.0.3-bookworm:latest --sdk-name 6.0.3-bookworm
Result :
warning: failed to retrieve search paths with pkg-config; maybe pkg-config is not installed
warning: couldn't find pc file for sqlite3
Building for debugging...
[1/1] Write swift-version--58304C5D6DBC2206.txt
Build of product 'swift-sdk-generator' complete! (2.18s)
2025-02-25T19:48:51+0100 info org.swift.swift-sdk-generator : [SwiftSDKGenerator] Downloading required toolchain packages...
2025-02-25T19:48:51+0100 info org.swift.swift-sdk-generator : [SwiftSDKGenerator] Using downloaded artifacts from cache
2025-02-25T19:48:51+0100 info org.swift.swift-sdk-generator : [SwiftSDKGenerator] Launching a container to extract the Swift SDK for the target triple...
Error: process exited non-zero: exit(125)
The text was updated successfully, but these errors were encountered: