Skip to content

Commit 3bbf558

Browse files
authored
Merge pull request #229 from rust-lang/compile-perf
Improve compilation performance
2 parents 040c9a2 + a79b9ef commit 3bbf558

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

Cargo.toml

+3
Original file line numberDiff line numberDiff line change
@@ -66,3 +66,6 @@ thread_local = "1.1.8"
6666

6767
[profile.release]
6868
debug = 1
69+
70+
[profile.dev.package.sqlx-macros]
71+
opt-level = 3

docs/development.md

+10
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,16 @@ Everytime you want to run bors:
6868
- Configure the webhook URL for your app to point to `<address>/github`.
6969
- Try `@bors ping` on some PR on the test repository :)
7070

71+
## Faster compilation
72+
Bors has a lot of dependencies and can be fairly slow to compile. If you want to improve compilation speed, you could use a faster linker, e.g. LLD.
73+
74+
To do that, install it (e.g. using `sudo apt install lld`) and then put this:
75+
```toml
76+
[build]
77+
rustflags = ["-C", "link-arg=-fuse-ld=lld"]
78+
```
79+
into `.cargo/config.toml`.
80+
7181
## Database
7282
You must have `sqlx-cli` installed for the following commands to work.
7383
```console

0 commit comments

Comments
 (0)