diff --git a/docs/dev/setup.md b/docs/dev/setup.md index d7a6f3be26296185a5e84f5ef8153053729f31dc..ef3140d9913d44df020a70540604f676c445bd35 100644 --- a/docs/dev/setup.md +++ b/docs/dev/setup.md @@ -79,3 +79,16 @@ rustup update nightly rustup update stable rustup target add wasm32-unknown-unknown --toolchain nightly ``` + + +### Installing mold linker to decrease build time + +Mold (modern linker) (https://github.com/rui314/mold) decreases the build time. Install it through your system package for example then add the following to your `~/.cargo/config`: + +```toml +[target.x86_64-unknown-linux-gnu] +linker = "clang" +rustflags = ["-C", "link-arg=-fuse-ld=/usr/bin/mold"] +``` + +(see https://forum.duniter.org/t/decrease-duniter-build-time/10170 on the forum) \ No newline at end of file