1
0
mirror of https://github.com/golang/go synced 2024-11-17 11:14:46 -07:00

cmd/dist: add support for freebsd/riscv64

Updates #53466

Change-Id: I6643b4254dc707351d397018cee485bb508dde94
Reviewed-on: https://go-review.googlesource.com/c/go/+/431659
Reviewed-by: Ian Lance Taylor <iant@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Run-TryBot: Joel Sing <joel@sing.id.au>
Reviewed-by: Joel Sing <joel@sing.id.au>
Reviewed-by: Dmitri Goutnik <dgoutnik@gmail.com>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
This commit is contained in:
Mikael Urankar 2022-09-18 17:33:42 +02:00 committed by Meng Zhuo
parent 2b1c414fa8
commit 738a2caf08
2 changed files with 5 additions and 0 deletions

View File

@ -1561,6 +1561,7 @@ var cgoEnabled = map[string]bool{
"freebsd/amd64": true,
"freebsd/arm": true,
"freebsd/arm64": true,
"freebsd/riscv64": true,
"illumos/amd64": true,
"linux/386": true,
"linux/amd64": true,

View File

@ -143,6 +143,10 @@ func main() {
if strings.Contains(run("", CheckExit, "uname", "-v"), "RELEASE_ARM64_") {
gohostarch = "arm64"
}
case gohostos == "freebsd":
if strings.Contains(run("", CheckExit, "uname", "-p"), "riscv64") {
gohostarch = "riscv64"
}
case gohostos == "openbsd":
if strings.Contains(run("", CheckExit, "uname", "-p"), "mips64") {
gohostarch = "mips64"