Skip to content

Commit

Permalink
Add riscv64gc-unknown-linux-gnu support
Browse files Browse the repository at this point in the history
  • Loading branch information
tblah committed Apr 28, 2020
1 parent bedf3b8 commit 342642d
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
7 changes: 6 additions & 1 deletion rustup-init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,9 @@ get_architecture() {
s390x)
_cputype=s390x
;;

riscv64)
_cputype=riscv64gc
;;
*)
err "unknown CPU type: $_cputype"

Expand All @@ -317,6 +319,9 @@ get_architecture() {
_ostype="${_ostype}eabihf"
fi
;;
riscv64gc)
err "riscv64 with 32-bit userland unsupported"
;;
esac
fi

Expand Down
1 change: 1 addition & 0 deletions src/dist/dist.rs
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ static LIST_ARCHS: &[&str] = &[
"powerpc",
"powerpc64",
"powerpc64le",
"riscv64gc",
"s390x",
];
static LIST_OSES: &[&str] = &[
Expand Down
2 changes: 2 additions & 0 deletions tests/mock/clitools.rs
Original file line number Diff line number Diff line change
Expand Up @@ -941,6 +941,8 @@ pub fn this_host_triple() -> String {
"i686"
} else if cfg!(target_arch = "x86_64") {
"x86_64"
} else if cfg!(target_arch = "riscv64") {
"riscv64gc"
} else {
unimplemented!()
};
Expand Down

0 comments on commit 342642d

Please sign in to comment.