From cc29f0686379187733fe8824a2bea3ec63d93448 Mon Sep 17 00:00:00 2001 From: widberg Date: Thu, 4 Jan 2024 21:24:15 -0500 Subject: [PATCH] Don't build with LTO on Windows --- build.zig | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/build.zig b/build.zig index 8856eb766..bed0bf0e0 100644 --- a/build.zig +++ b/build.zig @@ -251,6 +251,10 @@ pub fn build(b: *std.Build) !void { ); } + // Building with LTO on Windows is broken. + // https://github.com/ziglang/zig/issues/15958 + if (target.isWindows()) exe.want_lto = false; + // If we're installing, we get the install step so we can add // additional dependencies to it. const install_step = if (app_runtime != .none) step: {