diff options
| author | Ophestra <cat@gensokyo.uk> | 2026-07-10 14:48:54 +0900 |
|---|---|---|
| committer | Ophestra <cat@gensokyo.uk> | 2026-07-10 14:48:54 +0900 |
| commit | 8e9b3a2ed165b5432714c712838695fa5e763c5a (patch) | |
| tree | 01b56aa20b47a26d3e4d9bd012c90a35b3632fb6 /internal/rosa/package | |
| parent | fd0a81b304d9bd0b19199070a2838e604b3a4fc8 (diff) | |
internal/rosa/go: migrate to azalea
Bootstrap still remains native, however the final toolchain is migrated to azalea.
Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'internal/rosa/package')
| -rw-r--r-- | internal/rosa/package/go.az | 59 |
1 files changed, 59 insertions, 0 deletions
diff --git a/internal/rosa/package/go.az b/internal/rosa/package/go.az new file mode 100644 index 00000000..63ff6832 --- /dev/null +++ b/internal/rosa/package/go.az @@ -0,0 +1,59 @@ +package go { + description = "the Go programming language toolchain"; + website = "https://go.dev"; + anitya = 1227; + + version# = "1.26.4"; + source = remoteTar { + url = "https://go.dev/dl/go"+version+".src.tar.gz"; + checksum = "fpqJlxa41wKRtbnviYNLk9VxgcL-5oIEDxsriF8svU6kNwQW70oRRA9gTz_ImVoB"; + compress = gzip; + }; + + env = [ + "CC=cc", + "GOCACHE=/tmp/gocache", + "GOROOT_BOOTSTRAP=/system/go", + "TMPDIR=/dev/shm/go", + ]; + + enterSource = true; + + exec = generic { + inPlace = true; + build = ` +mkdir /work/system/ "${TMPDIR}" +cp -r . /work/system/go +cd /work/system/go/src/ +chmod -R +w .. + +sed -i \ + 's,/lib/ld-musl-`+linuxArch+`.so.1,/system/bin/linker,' \ + cmd/link/internal/`+arch+`/obj.go +sed -i \ + 's/cpu.X86.HasAVX512VBMI/& \&\& cpu.X86.HasPOPCNT/' \ + internal/runtime/gc/scan/scan_amd64.go + +rm \ + os/root_unix_test.go \ + cmd/cgo/internal/testsanitizers/tsan_test.go \ + cmd/cgo/internal/testsanitizers/cshared_test.go + +set +u +. ./make.bash "$@" --no-banner +set -u +`; + check = "bash run.bash --no-rebuild\n"; + install = ` +../bin/go tool dist banner # print build info + +mkdir /work/system/bin +ln -s \ + ../go/bin/go \ + ../go/bin/gofmt \ + /work/system/bin +`; + }; + + inputs = [ bash, go-bootstrap ]; +} |
