Skip to content

Commit f00a952

Browse files
committed
[RISCV] Use lld as the default linker.
1 parent 0e98621 commit f00a952

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

Diff for: src/librustc_target/spec/riscv32imac_unknown_none_elf.rs

+4-3
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@
88
// option. This file may not be copied, modified, or distributed
99
// except according to those terms.
1010

11-
use spec::{LinkerFlavor, PanicStrategy, Target, TargetOptions, TargetResult};
11+
use spec::{LinkerFlavor, LldFlavor, PanicStrategy,
12+
Target, TargetOptions, TargetResult};
1213
use spec::abi::{Abi};
1314

1415
pub fn target() -> TargetResult {
@@ -22,10 +23,10 @@ pub fn target() -> TargetResult {
2223
target_env: String::new(),
2324
target_vendor: "unknown".to_string(),
2425
arch: "riscv32".to_string(),
25-
linker_flavor: LinkerFlavor::Ld,
26+
linker_flavor: LinkerFlavor::Lld(LldFlavor::Ld),
2627

2728
options: TargetOptions {
28-
linker: Some("riscv32-unknown-elf-ld".to_string()),
29+
linker: Some("rust-lld".to_string()),
2930
cpu: "generic-rv32".to_string(),
3031
max_atomic_width: Some(32),
3132
atomic_cas: false, // incomplete +a extension

0 commit comments

Comments
 (0)