Skip to content

Commit b611516

Browse files
committed
Recommend per-user configuration of Wild or Mold
1 parent 15dcece commit b611516

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

docs/src/development/linux.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,21 @@ Clone down the [Zed repository](https://github.com/zed-industries/zed).
2020

2121
If you are looking to develop Zed collaboration features using a local collaboration server, please see: [Local Collaboration](./local-collaboration.md) docs.
2222

23+
### Linkers {#linker}
24+
25+
On most Linux distributions, the default linker is GNU ld. Newer linkers, especially [Wild](https://github.com/davidlattimore/wild) and [Mold](https://github.com/rui314/mold) can significantly improve clean and incremental build time.
26+
27+
At present Zed uses Mold in CI because it's more mature. For local development Wild is recommended because it's 5-20% faster.
28+
29+
To use Wild as your default, add these lines to your `~/.cargo/config.toml`:
30+
31+
32+
```toml
33+
[target.x86_64-unknown-linux-gnu]
34+
linker = "clang"
35+
rustflags = ["-C", "link-arg=--ld-path=wild"]
36+
```
37+
2338
## Building from source
2439

2540
Once the dependencies are installed, you can build Zed using [Cargo](https://doc.rust-lang.org/cargo/).

0 commit comments

Comments
 (0)