mirror of
https://github.com/ziglang/zig.git
synced 2026-02-12 20:37:54 +00:00
parent
6305ce828b
commit
dca19b6757
@ -992,6 +992,14 @@ static int main0(int argc, char **argv) {
|
||||
}
|
||||
} else {
|
||||
target_init_default_glibc_version(&target);
|
||||
#if defined(ZIG_OS_LINUX)
|
||||
if (target.is_native) {
|
||||
// TODO self-host glibc version detection, and then this logic can go away
|
||||
if ((err = glibc_detect_native_version(target.glibc_version))) {
|
||||
// Fall back to the default version.
|
||||
}
|
||||
}
|
||||
#endif
|
||||
}
|
||||
} else if (target_glibc != nullptr) {
|
||||
fprintf(stderr, "'%s' is not a glibc-compatible target", target_string);
|
||||
|
||||
@ -467,12 +467,6 @@ void get_native_target(ZigTarget *target) {
|
||||
if (target_is_glibc(target)) {
|
||||
target->glibc_version = heap::c_allocator.create<ZigGLibCVersion>();
|
||||
target_init_default_glibc_version(target);
|
||||
#ifdef ZIG_OS_LINUX
|
||||
Error err;
|
||||
if ((err = glibc_detect_native_version(target->glibc_version))) {
|
||||
// Fall back to the default version.
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user