about summary refs log tree commit diff
path: root/src/librustc_codegen_llvm
diff options
context:
space:
mode:
authorJorge Aparicio <jorge@japaric.io>2018-08-18 16:31:36 +0200
committerJorge Aparicio <jorge@japaric.io>2018-08-18 16:31:36 +0200
commit750e72b9e0881529dad5010862ffc8dec7c28fe8 (patch)
tree0f1f4768c61ba73c85bbc3f639f51bc89f4b187f /src/librustc_codegen_llvm
parenta0911cf95d3cf6bc0fe50ad95c2578771b122e64 (diff)
downloadrust-750e72b9e0881529dad5010862ffc8dec7c28fe8.tar.gz
rust-750e72b9e0881529dad5010862ffc8dec7c28fe8.zip
add lld_flavor info to target spec
this field defaults to the LD / GNU flavor
Diffstat (limited to 'src/librustc_codegen_llvm')
-rw-r--r--src/librustc_codegen_llvm/back/link.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/librustc_codegen_llvm/back/link.rs b/src/librustc_codegen_llvm/back/link.rs
index c31928afb22..86cef587d5b 100644
--- a/src/librustc_codegen_llvm/back/link.rs
+++ b/src/librustc_codegen_llvm/back/link.rs
@@ -624,6 +624,8 @@ pub fn linker_and_flavor(sess: &Session) -> (PathBuf, LinkerFlavor) {
                     LinkerFlavor::Ld
                 } else if stem == "link" || stem == "lld-link" {
                     LinkerFlavor::Msvc
+                } else if stem == "lld" || stem == "rust-lld" {
+                    LinkerFlavor::Lld(sess.target.target.options.lld_flavor)
                 } else {
                     // fall back to the value in the target spec
                     sess.target.target.linker_flavor