From 872bc787b56f71e53c80f4681523bc8356915b71 Mon Sep 17 00:00:00 2001 From: Jakub Konka Date: Sat, 24 Oct 2020 14:35:14 +0200 Subject: [PATCH] cc: fix regression on macOS after adding libc headers Signed-off-by: Jakub Konka --- src/Compilation.zig | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Compilation.zig b/src/Compilation.zig index ad59bf352a38..a42c08af2572 100644 --- a/src/Compilation.zig +++ b/src/Compilation.zig @@ -2127,7 +2127,9 @@ fn detectLibCIncludeDirs( return detectLibCFromLibCInstallation(arena, target, lci); } - if (target_util.canBuildLibC(target)) { + if (target_util.canBuildLibC(target)) outer: { + if (is_native_os and target.isDarwin()) break :outer; // If we're on Darwin, we want to use native since we only have headers. + const generic_name = target_util.libCGenericName(target); // Some architectures are handled by the same set of headers. const arch_name = if (target.abi.isMusl()) target_util.archMuslName(target.cpu.arch) else @tagName(target.cpu.arch);