rustc will use rust-lld by default on x86_64-unknown-linux-gnu on nightly to significantly reduce linking times.

  • BB_C@programming.dev
    link
    fedilink
    arrow-up
    0
    ·
    6 months ago

    Good. But a lot of us do this already:

    [target.x86_64-unknown-linux-gnu]
    linker = "clang" # for mold
    rustflags = ["-c", "link-arg=-fuse-ld=/usr/bin/mold"]
    
    [target.x86_64-unknown-linux-musl]
    rustflags = ["-Z", "gcc-ld=lld"]