Skip to content

Commit 92cd260

Browse files
authored
Windows - Set linker = "lld-link" (#3406)
# Description of Changes See the inline comments for the motivation. This was originally introduced to our Windows CI in #3351. This PR moves it from CI to general Windows target builds, since it seems like Windows builds are now generally having this issue. # API and ABI breaking changes None # Expected complexity level and risk 1 # Testing - [x] Windows CI still passes --------- Co-authored-by: Zeke Foppa <[email protected]>
1 parent b7efd17 commit 92cd260

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

.cargo/config.toml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,10 @@ rustflags = ["--cfg", "tokio_unstable"]
33

44
[alias]
55
bump-versions = "run -p upgrade-version --"
6+
7+
[target.x86_64-pc-windows-msvc]
8+
# Use a different linker. Otherwise, the build fails with some obscure linker error that
9+
# seems to be a result of us producing a massive PDB file.
10+
# I (@bfops) tried a variety of other link options besides switching linkers, but this
11+
# seems to be the only thing that worked.
12+
linker = "lld-link"

.github/workflows/ci.yml

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -58,12 +58,6 @@ jobs:
5858
$ErrorActionPreference = 'Stop'
5959
$PSNativeCommandUseErrorActionPreference = $true
6060
61-
# Use a different linker. Otherwise, the build fails with some obscure linker error that
62-
# seems to be a result of us producing a massive PDB file.
63-
# I (@bfops) tried a variety of other link options besides switching linkers, but this
64-
# seems to be the only thing that worked.
65-
$env:RUSTFLAGS='-Clinker=lld-link'
66-
6761
cargo build -p spacetimedb-cli -p spacetimedb-standalone -p spacetimedb-update
6862
Start-Process target/debug/spacetimedb-cli.exe -ArgumentList 'start --pg-port 5432'
6963
cd modules

0 commit comments

Comments
 (0)