authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2020-12-22 22:11:46-07:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2020-12-24 01:18:48-07:00
loged26b3204a3028fbc7d05a03b7e995d2f0de7a75
treec3af6b11a5d070a1239b229ba1c8d7d8caa2a48c
parent4d8c5dd4be7a84c5f01f8910c44c5a1e23740b77

stage2: tsan forces linking libc


1 files changed, 3 insertions(+), 3 deletions(-)

src/Compilation.zig+3-3
......@@ -593,7 +593,9 @@ pub fn create(gpa: *Allocator, options: InitOptions) !*Compilation {
593593 break :outer opts;
594594 } else .{};
595595
596 const link_libc = options.link_libc or target_util.osRequiresLibC(options.target);
596 const tsan = options.want_tsan orelse false;
597
598 const link_libc = options.link_libc or target_util.osRequiresLibC(options.target) or tsan;
597599
598600 const must_dynamic_link = dl: {
599601 if (target_util.cannotDynamicLink(options.target))
......@@ -654,8 +656,6 @@ pub fn create(gpa: *Allocator, options: InitOptions) !*Compilation {
654656 options.libc_installation,
655657 );
656658
657 const tsan = options.want_tsan orelse false;
658
659659 const must_pie = target_util.requiresPIE(options.target);
660660 const pie: bool = if (options.want_pie) |explicit| pie: {
661661 if (!explicit and must_pie) {