From 59ba0cb92a807b6f46c8370062149e406443c4d0 Mon Sep 17 00:00:00 2001 From: Jiahao XU Date: Sat, 15 Jun 2024 10:02:21 +1000 Subject: [PATCH] Speedup compilation on windows (#1766) * Speedup compilation on windows Signed-off-by: Jiahao XU * Speedup CI on macOS Use lld Signed-off-by: Jiahao XU --------- Signed-off-by: Jiahao XU --- .cargo/config.toml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 .cargo/config.toml diff --git a/.cargo/config.toml b/.cargo/config.toml new file mode 100644 index 00000000..65dd5780 --- /dev/null +++ b/.cargo/config.toml @@ -0,0 +1,16 @@ +[target.x86_64-pc-windows-msvc] +rustflags = ["-C", "link-arg=-fuse-ld=lld"] +[target.x86_64-pc-windows-gnu] +rustflags = ["-C", "link-arg=-fuse-ld=lld"] + +[target.aarch64-pc-windows-msvc] +rustflags = ["-C", "link-arg=-fuse-ld=lld"] +[target.aarch64-pc-windows-gnu] +rustflags = ["-C", "link-arg=-fuse-ld=lld"] + +[target.x86_64-apple-darwin] +rustflags = ["-C", "link-arg=-fuse-ld=lld"] +[target.x86_64h-apple-darwin] +rustflags = ["-C", "link-arg=-fuse-ld=lld"] +[target.aarch64-apple-darwin] +rustflags = ["-C", "link-arg=-fuse-ld=lld"]