Closed kkebo closed 5 months ago
This issue didn't occur in swift-DEVELOPMENT-SNAPSHOT-2024-01-08-a and earlier, but occured in swift-DEVELOPMENT-SNAPSHOT-2024-01-11-a and later.
In addition to the -disallow-use-new-driver
flag, the swift-legacy-driver
command also works.
$ swiftly use main-snapshot-2024-01-18
Set the active toolchain to main-snapshot-2024-01-18 (was main-snapshot-2024-01-11)
$ mkdir foo
$ cd foo
$ swift package init --type executable
Creating executable package: foo
Creating Package.swift
Creating .gitignore
Creating Sources/
Creating Sources/main.swift
$ swift-legacy-driver build
Building for debugging...
[8/8] Linking foo
Build complete! (1.75s)
Swift 6.0 Development Snapshots still have this problem. Any chance of being cherry-picked to 6.0?
Swift 6.0 Development Snapshots still have this problem. Any chance of being cherry-picked to 6.0?
Yeah, will do.
Description
SSWG's swiftly installs a Swift toolchain under
$SWIFTLY_BIN_DIR
(e.g.$HOME/.local/bin
).In fact, they are just symbolic links to executables under
$SWIFTLY_HOME_DIR/toolchains/*/usr/bin
.Recently, the main snapshot toolchain began actively using the new swift-driver.
However, the new swift-driver doesn't seem to work properly when it's used through a symbolic link, such as the one swiftly installs.
related issue: https://github.com/swift-server/swiftly/issues/92
Reproduction
Prerequisites:
swiftly
is found in$PATH
Steps to reproduce:
Expected behavior
Environment
Additional information
After following "Steps to reproduce", you can success to build in the following two ways.
Thus, I believe that the combination of the new swift-driver and symbolic links is the cause.