From 55a0016221e459c49b9f04a4b57ba84be27bba72 Mon Sep 17 00:00:00 2001 From: Andrew Kelley Date: Tue, 5 Mar 2019 15:54:08 -0500 Subject: dynamic linker path is independent from libc installation --- src/link.cpp | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) (limited to 'src/link.cpp') diff --git a/src/link.cpp b/src/link.cpp index f7df0112db..320d1204d2 100644 --- a/src/link.cpp +++ b/src/link.cpp @@ -517,14 +517,9 @@ static void construct_linker_job_elf(LinkJob *lj) { } if (!g->is_static) { - if (g->libc != nullptr) { - assert(buf_len(&g->libc->dynamic_linker_path) != 0); - lj->args.append("-dynamic-linker"); - lj->args.append(buf_ptr(&g->libc->dynamic_linker_path)); - } else { - lj->args.append("-dynamic-linker"); - lj->args.append(target_dynamic_linker(g->zig_target)); - } + assert(g->dynamic_linker_path != nullptr); + lj->args.append("-dynamic-linker"); + lj->args.append(buf_ptr(g->dynamic_linker_path)); } } @@ -545,7 +540,6 @@ static void construct_linker_job_elf(LinkJob *lj) { lj->args.append(buf_ptr(builtin_a_path)); } - // sometimes libgcc is missing stuff, so we still build compiler_rt and rely on weak linkage Buf *compiler_rt_o_path = build_compiler_rt(g); lj->args.append(buf_ptr(compiler_rt_o_path)); } -- cgit v1.2.3