You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If the same Static Linux SDK has already been installed, swift run build-swiftly-release always fails.
Swift SDK bundle archive successfully downloaded from `https://download.swift.org/swift-6.0.3-release/static-sdk/swift-6.0.3-RELEASE/swift-6.0.3-RELEASE_static-linux-0.0.1.artifactbundle.tar.gz`.
Verifying if checksum of the downloaded archive is valid...
Downloaded archive has a valid checksum.
Swift SDK bundle at `https://download.swift.org/swift-6.0.3-release/static-sdk/swift-6.0.3-RELEASE/swift-6.0.3-RELEASE_static-linux-0.0.1.artifactbundle.tar.gz` is assumed to be an archive, unpacking...
Error: Swift SDK bundle with name `swift-6.0.3-RELEASE_static-linux-0.0.1.artifactbundle` is already installed. Can't install a new bundle with the same name.
Error: /home/kebo/.local/share/swiftly/toolchains/6.0.3/usr/bin/swift exited with non-zero status: 1
Full log:
$ swift --version ; uname -aSwift version 6.0.3 (swift-6.0.3-RELEASE)Target: aarch64-unknown-linux-gnuLinux Raspberry-beetle 6.6.74+rpt-rpi-2712 #1 SMP PREEMPT Debian 1:6.6.74-1+rpt1 (2025-01-27) aarch64 GNU/Linux
$ swift sdk listDEVELOPMENT-SNAPSHOT-2025-03-17-a-wasm32-unknown-wasiswift-6.0.3-RELEASE_static-linux-0.0.1
$ swift run build-swiftly-release --skip 1.0.0-devwarning: 'swift-algorithms': found 1 file(s) which are unhandled; explicitly declare them as resources or exclude from the target /home/kebo/swiftly/.build/checkouts/swift-algorithms/Sources/Algorithms/Documentation.docc Building for debugging... [507/507] Linking swift-openapi-generator-tool Build of product 'swift-openapi-generator' complete! (62.19s) warning: 'swiftly': found 1 file(s) which are unhandled; explicitly declare them as resources or exclude from the target /home/kebo/swiftly/Tools/build-swiftly-release/musl-clang Building for debugging... /home/kebo/swiftly/Tools/build-swiftly-release/BuildSwiftlyRelease.swift:299:29: warning: result of call to 'changeCurrentDirectoryPath' is unused 297 | 298 | let cwd = FileManager.default.currentDirectoryPath 299 | FileManager.default.changeCurrentDirectoryPath(libArchivePath) | `- warning: result of call to 'changeCurrentDirectoryPath' is unused 300 | 301 | let swiftVerRegex: Regex<(Substring, Substring)> = try! Regex("Swift version (\\d+\\.\\d+\\.\\d+) ") /home/kebo/swiftly/Tools/build-swiftly-release/BuildSwiftlyRelease.swift:360:29: warning: result of call to 'changeCurrentDirectoryPath' is unused 358 | try runProgram(make, "install") 359 | 360 | FileManager.default.changeCurrentDirectoryPath(cwd) | `- warning: result of call to 'changeCurrentDirectoryPath' is unused 361 | 362 | try runProgram(swift, "build", "--swift-sdk", "\(arch)-swift-linux-musl", "--product=swiftly", "--pkg-config-path=\(pkgConfigPath)/lib/pkgconfig", "--static-swift-stdlib", "--configuration=release") [59/59] Linking build-swiftly-release Build of product 'build-swiftly-release' complete! (81.47s) getent passwd /bin/bash -c which which getent passwd /bin/bash -c which curl getent passwd /bin/bash -c which which getent passwd /bin/bash -c which tar getent passwd /bin/bash -c which which getent passwd /bin/bash -c which make getent passwd /bin/bash -c which which getent passwd /bin/bash -c which git getent passwd /bin/bash -c which which getent passwd /bin/bash -c which strip getent passwd /bin/bash -c which which getent passwd /bin/bash -c which sha256sum getent passwd /bin/bash -c which which getent passwd /bin/bash -c which swift /home/kebo/.local/share/swiftly/toolchains/6.0.3/usr/bin/swift package reset /usr/bin/curl -o /home/kebo/swiftly/.build/checkouts/libarchive-3.7.4.tar.gz --remote-name --location https://github.com/libarchive/libarchive/releases/download/v3.7.4/libarchive-3.7.4.tar.gz % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0 100 7464k 100 7464k 0 0 5592k 0 0:00:01 0:00:01 --:--:-- 11.6M Warning: Got more output options than URLs /usr/bin/sha256sum /home/kebo/swiftly/.build/checkouts/libarchive-3.7.4.tar.gz /usr/bin/tar --directory=/home/kebo/swiftly/.build/checkouts -xzf /home/kebo/swiftly/.build/checkouts/libarchive-3.7.4.tar.gz /home/kebo/.local/share/swiftly/toolchains/6.0.3/usr/bin/swift --version /usr/bin/curl https://www.swift.org/api/v1/install/releases.json % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 34754 100 34754 0 0 58007 0 --:--:-- --:--:-- --:--:-- 57923 /home/kebo/.local/share/swiftly/toolchains/6.0.3/usr/bin/swift sdk install https://download.swift.org/swift-6.0.3-release/static-sdk/swift-6.0.3-RELEASE/swift-6.0.3-RELEASE_static-linux-0.0.1.artifactbundle.tar.gz --checksum 67f765e0030e661a7450f7e4877cfe008db4f57f177d5a08a6e26fd661cdd0bd Downloading a Swift SDK bundle archive from `https://download.swift.org/swift-6.0.3-release/static-sdk/swift-6.0.3-RELEASE/swift-6.0.3-RELEASE_static-linux-0.0.1.artifactbundle.tar.gz`... Downloading 100% [======================================================================================================================================================================] Downloading swift-6.0.3-RELEASE_static-linux-0.0.1.artifactbundle.tar.gz Swift SDK bundle archive successfully downloaded from `https://download.swift.org/swift-6.0.3-release/static-sdk/swift-6.0.3-RELEASE/swift-6.0.3-RELEASE_static-linux-0.0.1.artifactbundle.tar.gz`. Verifying if checksum of the downloaded archive is valid... Downloaded archive has a valid checksum. Swift SDK bundle at `https://download.swift.org/swift-6.0.3-release/static-sdk/swift-6.0.3-RELEASE/swift-6.0.3-RELEASE_static-linux-0.0.1.artifactbundle.tar.gz` is assumed to be an archive, unpacking... Error: Swift SDK bundle with name `swift-6.0.3-RELEASE_static-linux-0.0.1.artifactbundle` is already installed. Can't install a new bundle with the same name. Error: /home/kebo/.local/share/swiftly/toolchains/6.0.3/usr/bin/swift exited with non-zero status: 1
The build script does make some assumptions here, one of them being that it has control over the installed SDK's. PR's are welcome to make it more resilient when running on a dev machine where things like an SDK is already installed.
In retrospect, I believe that there is a way that one can pass a untarred SDK path directly to swift build and maybe that's the way that this script should work so that it doesn't impact the user's environment.
In retrospect, I believe that there is a way that one can pass a untarred SDK path directly to swift build and maybe that's the way that this script should work so that it doesn't impact the user's environment.
FYI, you can pass --swift-sdks-path to the swift build invocation to tell it where your Swift SDKs are at. So if you download the static SDK locally in some temp folder, you can do:
swift build --swift-sdks-path /path/to/tmp/directory --swift-sdk <arch>-swift-linux-musl
If the same Static Linux SDK has already been installed,
swift run build-swiftly-release
always fails.Full log:
swiftly release/1.0 branch 400e6a9
The text was updated successfully, but these errors were encountered: