Skip to content

Commit ec49ec8

Browse files
committed
script/linux: Show recommended Wild config fragment
1 parent b3ed2b1 commit ec49ec8

File tree

1 file changed

+17
-6
lines changed

1 file changed

+17
-6
lines changed

script/linux

Lines changed: 17 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,23 @@ fi
1111
function finalize {
1212
# after packages install (curl, etc), get the rust toolchain
1313
which rustup > /dev/null 2>&1 || curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
14-
# verify the mold situation
15-
if ! command -v mold >/dev/null 2>&1; then
16-
echo "Warning: Mold binaries are unavailable on your system." >&2
17-
echo " Builds will be slower without mold. Try: script/install-mold" >&2
18-
fi
19-
echo "Finished installing Linux dependencies with script/linux"
14+
cat <<EOF
15+
Note: It's recommended to install and configure Wild or Mold for faster builds.
16+
Run script/install-wild or script/install-mold.
17+
Then add these lines to your ~/.cargo/config.toml:
18+
19+
[target.x86_64-unknown-linux-gnu]
20+
linker = "clang"
21+
rustflags = ["-C", "link-arg=--ld-path=wild"]
22+
23+
[target.aarch64-unknown-linux-gnu]
24+
linker = "clang"
25+
rustflags = ["-C", "link-arg=--ld-path=wild"]
26+
27+
28+
29+
Finished installing Linux dependencies with script/linux
30+
EOF
2031
}
2132

2233
# Ubuntu, Debian, Mint, Kali, Pop!_OS, Raspbian, etc.

0 commit comments

Comments
 (0)