Skip to content

Commit

Permalink
Merge pull request #530 from infosiftr/GOARM64-GORISCV64
Browse files Browse the repository at this point in the history
Add GOARM64 and GORISCV64 values to our `versions.json`
  • Loading branch information
tianon authored Aug 16, 2024
2 parents cc3386b + 8d99221 commit bb910a3
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 4 deletions.
6 changes: 4 additions & 2 deletions versions.json
Original file line number Diff line number Diff line change
Expand Up @@ -455,7 +455,8 @@
"sha256": "62788056693009bcf7020eedc778cdd1781941c6145eab7688bd087bce0f8659",
"env": {
"GOOS": "linux",
"GOARCH": "arm64"
"GOARCH": "arm64",
"GOARM64": "v8.0"
},
"supported": true
},
Expand Down Expand Up @@ -735,7 +736,8 @@
"sha256": "a87726205f1a283247f877ccae8ce147ff4e77ac802382647ac52256eb5642c7",
"env": {
"GOOS": "linux",
"GOARCH": "riscv64"
"GOARCH": "riscv64",
"GORISCV64": "rva20u64"
},
"supported": true
},
Expand Down
11 changes: 9 additions & 2 deletions versions.sh
Original file line number Diff line number Diff line change
Expand Up @@ -140,11 +140,18 @@ for version in "${versions[@]}"; do
# i386 in Debian is non-SSE2, Alpine appears to be similar (but interesting, not FreeBSD?)
{ GOARCH: "386", GO386: "softfloat" }
elif $bashbrewArch == "amd64" then
# https://tip.golang.org/doc/go1.18#amd64
# https://go.dev/doc/go1.18#amd64
{ GOAMD64: "v1" }
# TODO ^^ figure out what to do with GOAMD64 / GO386 if/when the OS baselines change and these choices needs to be per-variant /o\ (probably move it to the template instead, in fact, since that is where we can most easily toggle based on variant)
elif $bashbrewArch == "riscv64" and env.version != "1.22" then
# https://go.dev/doc/go1.23#riscv
{ GORISCV64: "rva20u64" }
elif $bashbrewArch | startswith("arm64v") then
{ GOARCH: "arm64" } # TODO do something with arm64 variant
{ GOARCH: "arm64" }
+ if env.version != "1.22" then {
# https://go.dev/doc/go1.23#arm64
GOARM64: ($bashbrewArch | ltrimstr("arm64") | if index(".") then . else . + ".0" end),
} else {} end
elif $bashbrewArch | startswith("arm32v") then
{ GOARCH: "arm", GOARM: ($bashbrewArch | ltrimstr("arm32v")) }
else {} end
Expand Down

0 comments on commit bb910a3

Please sign in to comment.