Skip to content

Commit

Permalink
Fix rust.use-lld when linker is not set
Browse files Browse the repository at this point in the history
  • Loading branch information
mati865 committed Sep 4, 2020
1 parent 4ffb5c5 commit a2fbf39
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/bootstrap/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -863,7 +863,12 @@ impl Build {
&& !target.contains("msvc")
{
Some(self.cc(target))
} else if can_use_lld && self.config.use_lld && self.build == target {
} else if target.contains("msvc")
&& can_use_lld
&& self.config.use_lld
&& self.build == target
{
// Currently we support using LLD directly via `rust.use_lld` option only with MSVC
Some(&self.initial_lld)
} else {
None
Expand Down

0 comments on commit a2fbf39

Please sign in to comment.