Add .cargo/config.toml for Windows target

Add configuration for Windows target build with specific rustflags.
This commit is contained in:
Tiziano Marra
2026-07-12 16:35:37 +02:00
committed by GitHub
parent 08f946bd73
commit 4a1bf03025
+19
View File
@@ -0,0 +1,19 @@
[build]
target = "x86_64-pc-windows-msvc"
[target.x86_64-pc-windows-msvc]
rustflags = [
"-C", "link-arg=/OSVERSION:6.2",
"-C", "link-arg=/MACHINE:X64",
"-C", "control-flow-guard=yes",
"-C", "link-arg=/CETCOMPAT",
"-C", "link-arg=/force:guardehcont",
"-C", "link-arg=/guard:ehcont",
# "-Z", "ehcont-guard", # requires nightly; uncomment if using rustc nightly
"-C", "link-arg=/DYNAMICBASE",
"-C", "link-arg=/NXCOMPAT",
"-C", "link-arg=/HIGHENTROPYVA",
]