Skip to content

Commit c7cd5dd

Browse files
authored
Merge pull request #429 from laanwj/2019_08_rv_correct_abi
risc-v: Set ABI correctly for 32-bit targets
2 parents f6f6c81 + b154938 commit c7cd5dd

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/lib.rs

+5-1
Original file line numberDiff line numberDiff line change
@@ -1436,7 +1436,11 @@ impl Build {
14361436
cmd.args.push(("-march=rv".to_owned() + arch).into());
14371437
// ABI is always soft-float right now, update this when this is no longer the
14381438
// case:
1439-
cmd.args.push("-mabi=lp64".into());
1439+
if arch.starts_with("64") {
1440+
cmd.args.push("-mabi=lp64".into());
1441+
} else {
1442+
cmd.args.push("-mabi=ilp32".into());
1443+
}
14401444
}
14411445
}
14421446
}

0 commit comments

Comments
 (0)