Skip to content

Commit

Permalink
Use a single codegen-unit for compilation
Browse files Browse the repository at this point in the history
as suggested in
https://nnethercote.github.io/perf-book/build-configuration.html#codegen-units

to achieve reproducible builds.
It can also enhance optimizations of the produced binary.

Fixes pop-os#230

This patch was done while working on reproducible builds for openSUSE, sponsored by the NLnet NGI0 fund.
  • Loading branch information
bmwiedemann committed Jul 31, 2024
1 parent e44d6cd commit 57366bb
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ serde_json.workspace = true
serde_with.workspace = true

[profile.release]
codegen-units = 1
lto = "fat"
panic = "abort"

Expand Down

0 comments on commit 57366bb

Please sign in to comment.