authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2019-07-07 19:24:44-04:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2019-07-07 19:24:44-04:00
logf04782785f66879db1f31dd6620cd31161c4da08
treee8abb9884235c1b9b3b84078809086c3c11ed798
parent56d818565015b8213f6c070236658c8796c86d0a
signaturelock-open Commit is signed but in an unrecognized format.

fix not setting a target glibc version on non-linux


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

src/target.cpp+4-4
......@@ -507,16 +507,16 @@ void get_native_target(ZigTarget *target) {
507507 target->abi = target_default_abi(target->arch, target->os);
508508 }
509509 target->glibc_version = nullptr;
510#ifdef ZIG_OS_LINUX
511510 if (target_is_glibc(target)) {
512511 target->glibc_version = allocate<ZigGLibCVersion>(1);
512 *target->glibc_version = {2, 17, 0};
513#ifdef ZIG_OS_LINUX
513514 Error err;
514515 if ((err = glibc_detect_native_version(target->glibc_version))) {
515 // Use a default version.
516 *target->glibc_version = {2, 17, 0};
516 // Fall back to the default version.
517517 }
518 }
519518#endif
519 }
520520}
521521
522522Error target_parse_archsub(ZigLLVM_ArchType *out_arch, ZigLLVM_SubArchType *out_sub,