mirror of
https://github.com/LemmyNet/lemmy.git
synced 2025-01-10 09:05:26 +00:00
Running cargo-wizard to speed up compilation times.
This commit is contained in:
parent
7585aac446
commit
859356db3f
2 changed files with 8 additions and 2 deletions
2
.cargo/config.toml
Normal file
2
.cargo/config.toml
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
[build]
|
||||||
|
rustflags = ["-Clink-arg=-fuse-ld=lld", "-Zthreads=16", "-Ctarget-cpu=native"]
|
|
@ -24,17 +24,21 @@ doctest = false
|
||||||
[lints]
|
[lints]
|
||||||
workspace = true
|
workspace = true
|
||||||
|
|
||||||
|
cargo-features = ["codegen-backend"]
|
||||||
|
|
||||||
# See https://github.com/johnthagen/min-sized-rust for additional optimizations
|
# See https://github.com/johnthagen/min-sized-rust for additional optimizations
|
||||||
[profile.release]
|
[profile.release]
|
||||||
debug = 0
|
debug = false
|
||||||
lto = "fat"
|
lto = true
|
||||||
opt-level = 3 # Optimize for speed, not size.
|
opt-level = 3 # Optimize for speed, not size.
|
||||||
codegen-units = 1 # Reduce parallel code generation.
|
codegen-units = 1 # Reduce parallel code generation.
|
||||||
|
panic = "abort"
|
||||||
|
|
||||||
# This profile significantly speeds up build time. If debug info is needed you can comment the line
|
# This profile significantly speeds up build time. If debug info is needed you can comment the line
|
||||||
# out temporarily, but make sure to leave this in the main branch.
|
# out temporarily, but make sure to leave this in the main branch.
|
||||||
[profile.dev]
|
[profile.dev]
|
||||||
debug = 0
|
debug = 0
|
||||||
|
codegen-backend = "cranelift"
|
||||||
|
|
||||||
[features]
|
[features]
|
||||||
json-log = ["tracing-subscriber/json"]
|
json-log = ["tracing-subscriber/json"]
|
||||||
|
|
Loading…
Reference in a new issue