aboutsummaryrefslogtreecommitdiff
path: root/src/Compilation.zig
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2020-09-23 11:15:27 -0700
committerAndrew Kelley <andrew@ziglang.org>2020-09-23 11:15:27 -0700
commitb183b612c938a8c9949fee02fa55038273595496 (patch)
tree42572a7f3df5f0c2aec19f888fa8bd10f6fe439b /src/Compilation.zig
parentf4dde4d109ecd722ac82243417cac9f0e736de94 (diff)
downloadzig-b183b612c938a8c9949fee02fa55038273595496.tar.gz
zig-b183b612c938a8c9949fee02fa55038273595496.zip
stage2: don't build libunwind on OS's that don't need it
Diffstat (limited to 'src/Compilation.zig')
-rw-r--r--src/Compilation.zig3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Compilation.zig b/src/Compilation.zig
index 1297341926..9ff2f35134 100644
--- a/src/Compilation.zig
+++ b/src/Compilation.zig
@@ -1883,7 +1883,8 @@ fn wantBuildLibUnwindFromSource(comp: *Compilation) bool {
.Exe => true,
};
return comp.bin_file.options.link_libc and is_exe_or_dyn_lib and
- comp.bin_file.options.libc_installation == null;
+ comp.bin_file.options.libc_installation == null and
+ target_util.libcNeedsLibUnwind(comp.getTarget());
}
fn updateBuiltinZigFile(comp: *Compilation, mod: *Module) !void {