From 26eec4bef4fe41a9950671d0d5021872c9afffe9 Mon Sep 17 00:00:00 2001 From: Will Jones Date: Fri, 16 Feb 2024 15:54:12 -0800 Subject: [PATCH] fix: use static C runtime on Windows (#979) We depend on C static runtime, but not all Windows machines have that. So might be worth statically linking it. https://github.com/reorproject/reor/issues/36#issuecomment-1948876463 --- .cargo/config.toml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.cargo/config.toml b/.cargo/config.toml index c5958ed0..ec0369f8 100644 --- a/.cargo/config.toml +++ b/.cargo/config.toml @@ -33,3 +33,8 @@ rustflags = ["-C", "target-cpu=haswell", "-C", "target-feature=+avx2,+fma,+f16c" [target.aarch64-apple-darwin] rustflags = ["-C", "target-cpu=apple-m1", "-C", "target-feature=+neon,+fp16,+fhm,+dotprod"] + +# Not all Windows systems have the C runtime installed, so this avoids library +# not found errors on systems that are missing it. +[target.x86_64-pc-windows-msvc] +rustflags = ["-Ctarget-feature=+crt-static"]