Skip to content

Commit a7b0385

Browse files
committed
Use Wild only on x86_64 debug builds
1 parent 3804e2e commit a7b0385

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

.cargo/config.toml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,19 @@ rustflags = ["-C", "symbol-mangling-version=v0", "--cfg", "tokio_unstable"]
55
[alias]
66
xtask = "run --package xtask --"
77

8-
[target.x86_64-unknown-linux-gnu]
8+
[target.'(cfg(all(debug_assertions, target_arch = "x86_64", target_os = "linux"))']
9+
# Wild is not yet considered ready for production use, but it is faster, so use it
10+
# only for debug builds.
911
linker = "clang"
1012
rustflags = ["-C", "link-arg=--ld-path=wild"]
1113

14+
[target.'(cfg(all(not(debug_assertions), target_arch = "x86_64", target_os = "linux"))']
15+
linker = "clang"
16+
rustflags = ["-C", "link-arg=-fuse-ld=mold"]
17+
1218
[target.aarch64-unknown-linux-gnu]
1319
linker = "clang"
14-
rustflags = ["-C", "link-arg=--ld-path=wild"]
20+
rustflags = ["-C", "link-arg=-fuse-ld=mold"]
1521

1622
[target.'cfg(target_os = "windows")']
1723
rustflags = [

0 commit comments

Comments
 (0)