aboutsummaryrefslogtreecommitdiff
path: root/src/Compilation.zig
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2020-10-04 23:16:46 -0700
committerAndrew Kelley <andrew@ziglang.org>2020-10-04 23:16:46 -0700
commit55ac973953da88c3a108398849ee29f797c4ae52 (patch)
treeb01c6bf6a399774ec39a057b1af93f03f82453f0 /src/Compilation.zig
parentd5d48c6f4ea8a16c2fa9dc9b083c1917a3accee0 (diff)
downloadzig-55ac973953da88c3a108398849ee29f797c4ae52.tar.gz
zig-55ac973953da88c3a108398849ee29f797c4ae52.zip
fix each-lib-rpath functionality
It was regressed in 2 ways from the merge of #6250: * it was not being enabled by default when the target OS is native. * we were testing the libfoo.so file path existence with bogus format string ('{}' instead of '{s}') and so it ended up being something like "libstd.HashMap(K,V,...).Entry.so" instead of "libfoo.so". Using {} rather than {s} is a footgun, be careful! Previous functionality is now restored. closes #6523
Diffstat (limited to 'src/Compilation.zig')
-rw-r--r--src/Compilation.zig2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Compilation.zig b/src/Compilation.zig
index 2ebc1b830d..f33ada9362 100644
--- a/src/Compilation.zig
+++ b/src/Compilation.zig
@@ -800,7 +800,7 @@ pub fn create(gpa: *Allocator, options: InitOptions) !*Compilation {
.llvm_cpu_features = llvm_cpu_features,
.is_compiler_rt_or_libc = options.is_compiler_rt_or_libc,
.parent_compilation_link_libc = options.parent_compilation_link_libc,
- .each_lib_rpath = options.each_lib_rpath orelse false,
+ .each_lib_rpath = options.each_lib_rpath orelse options.is_native_os,
.disable_lld_caching = options.disable_lld_caching,
.subsystem = options.subsystem,
.is_test = options.is_test,