Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update bashbrew-arch-to-goenv.sh with more edge cases #110

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

tianon
Copy link
Member

@tianon tianon commented Dec 4, 2024

Also, Go updates (GOAMD64, GOARM64, etc)

$ for bashbrewArch in $(grep -oE '^[[:space:]]+"[^[:space:]]+":' architecture/oci-platform.go | cut -d'"' -f2); do echo "# $bashbrewArch"; ./scripts/bashbrew-arch-to-goenv.sh "$bashbrewArch"; echo; done
# amd64
export GOARCH=amd64 GOAMD64=v1 GOOS=linux
unset GO386 GOARM GOMIPS64 GOARM64 GORISCV64 GOPPC64

# arm32v5
export GOARCH=arm GOARM=5 GOOS=linux
unset GO386 GOMIPS64 GOARM64 GORISCV64 GOAMD64 GOPPC64

# arm32v6
export GOARCH=arm GOARM=6 GOOS=linux
unset GO386 GOMIPS64 GOARM64 GORISCV64 GOAMD64 GOPPC64

# arm32v7
export GOARCH=arm GOARM=7 GOOS=linux
unset GO386 GOMIPS64 GOARM64 GORISCV64 GOAMD64 GOPPC64

# arm64v8
export GOARCH=arm64 GOARM64=v8.0 GOOS=linux
unset GO386 GOARM GOMIPS64 GORISCV64 GOAMD64 GOPPC64

# i386
export GOARCH=386 GOOS=linux
unset GO386 GOARM GOMIPS64 GOARM64 GORISCV64 GOAMD64 GOPPC64

# mips64le
export GOARCH=mips64le GOOS=linux
unset GO386 GOARM GOMIPS64 GOARM64 GORISCV64 GOAMD64 GOPPC64

# ppc64le
export GOARCH=ppc64le GOOS=linux
unset GO386 GOARM GOMIPS64 GOARM64 GORISCV64 GOAMD64 GOPPC64

# riscv64
export GOARCH=riscv64 GOOS=linux
unset GO386 GOARM GOMIPS64 GOARM64 GORISCV64 GOAMD64 GOPPC64

# s390x
export GOARCH=s390x GOOS=linux
unset GO386 GOARM GOMIPS64 GOARM64 GORISCV64 GOAMD64 GOPPC64

# windows-amd64
export GOARCH=amd64 GOAMD64=v1 GOOS=windows
unset GO386 GOARM GOMIPS64 GOARM64 GORISCV64 GOPPC64

Also, Go updates (`GOAMD64`, `GOARM64`, etc)

```console
$ for bashbrewArch in $(grep -oE '^[[:space:]]+"[^[:space:]]+":' architecture/oci-platform.go | cut -d'"' -f2); do echo "# $bashbrewArch"; ./scripts/bashbrew-arch-to-goenv.sh "$bashbrewArch"; echo; done
# amd64
export GOARCH=amd64 GOAMD64=v1 GOOS=linux
unset GO386 GOARM GOMIPS64 GOARM64 GORISCV64 GOPPC64

# arm32v5
export GOARCH=arm GOARM=5 GOOS=linux
unset GO386 GOMIPS64 GOARM64 GORISCV64 GOAMD64 GOPPC64

# arm32v6
export GOARCH=arm GOARM=6 GOOS=linux
unset GO386 GOMIPS64 GOARM64 GORISCV64 GOAMD64 GOPPC64

# arm32v7
export GOARCH=arm GOARM=7 GOOS=linux
unset GO386 GOMIPS64 GOARM64 GORISCV64 GOAMD64 GOPPC64

# arm64v8
export GOARCH=arm64 GOARM64=v8.0 GOOS=linux
unset GO386 GOARM GOMIPS64 GORISCV64 GOAMD64 GOPPC64

# i386
export GOARCH=386 GOOS=linux
unset GO386 GOARM GOMIPS64 GOARM64 GORISCV64 GOAMD64 GOPPC64

# mips64le
export GOARCH=mips64le GOOS=linux
unset GO386 GOARM GOMIPS64 GOARM64 GORISCV64 GOAMD64 GOPPC64

# ppc64le
export GOARCH=ppc64le GOOS=linux
unset GO386 GOARM GOMIPS64 GOARM64 GORISCV64 GOAMD64 GOPPC64

# riscv64
export GOARCH=riscv64 GOOS=linux
unset GO386 GOARM GOMIPS64 GOARM64 GORISCV64 GOAMD64 GOPPC64

# s390x
export GOARCH=s390x GOOS=linux
unset GO386 GOARM GOMIPS64 GOARM64 GORISCV64 GOAMD64 GOPPC64

# windows-amd64
export GOARCH=amd64 GOAMD64=v1 GOOS=windows
unset GO386 GOARM GOMIPS64 GOARM64 GORISCV64 GOPPC64
```
@tianon tianon requested a review from yosifkit as a code owner December 4, 2024 19:20
@tianon
Copy link
Member Author

tianon commented Dec 4, 2024

Semi-related bits of code:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant