diff options
| author | Sean Cross <sean@xobs.io> | 2023-07-31 16:23:47 +0800 |
|---|---|---|
| committer | Sean Cross <sean@xobs.io> | 2023-08-22 20:25:38 +0800 |
| commit | dffc86472e2dc5139850c8fd2ae18282857016a1 (patch) | |
| tree | d4c80f787693cf3c485212e2064657def10f6397 | |
| parent | 112d101f880bafa2060a5bfa2b65563b8585624b (diff) | |
| download | rust-dffc86472e2dc5139850c8fd2ae18282857016a1.tar.gz rust-dffc86472e2dc5139850c8fd2ae18282857016a1.zip | |
bootstrap: builder: don't add origin paths on xous
Don't add the origin rpath when calling the linker. This is unnecessary on Xous since there is no dynamic linker, and Xous can use an ordinary bare-metal linker with no rpath options. As part of this patch, the logic was inverted so that the "else" clause contains everything except "windows" and "xous". Signed-off-by: Sean Cross <sean@xobs.io>
| -rw-r--r-- | src/bootstrap/builder.rs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/bootstrap/builder.rs b/src/bootstrap/builder.rs index b3666192853..9a37ed42cf2 100644 --- a/src/bootstrap/builder.rs +++ b/src/bootstrap/builder.rs @@ -1635,7 +1635,10 @@ impl<'a> Builder<'a> { // flesh out rpath support more fully in the future. rustflags.arg("-Zosx-rpath-install-name"); Some(format!("-Wl,-rpath,@loader_path/../{libdir}")) - } else if !target.contains("windows") && !target.contains("aix") { + } else if !target.contains("windows") + && !target.contains("aix") + && !target.contains("xous") + { rustflags.arg("-Clink-args=-Wl,-z,origin"); Some(format!("-Wl,-rpath,$ORIGIN/../{libdir}")) } else { |
