mirror of
https://github.com/ziglang/zig.git
synced 2026-02-12 20:37:54 +00:00
stage2: don't bother building glibc when only doing build-obj
This commit is contained in:
parent
e5aef96293
commit
0379d7b431
@ -1548,7 +1548,12 @@ fn addBuildingGLibCWorkItems(comp: *Compilation) !void {
|
||||
}
|
||||
|
||||
fn wantBuildGLibCFromSource(comp: *Compilation) bool {
|
||||
return comp.bin_file.options.link_libc and
|
||||
const is_exe_or_dyn_lib = switch (comp.bin_file.options.output_mode) {
|
||||
.Obj => false,
|
||||
.Lib => comp.bin_file.options.link_mode == .Dynamic,
|
||||
.Exe => true,
|
||||
};
|
||||
return comp.bin_file.options.link_libc and is_exe_or_dyn_lib and
|
||||
comp.bin_file.options.libc_installation == null and
|
||||
comp.bin_file.options.target.isGnuLibC();
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user