From: Joel Sing Subject: [lang/go] remove mips64 support To: ports@openbsd.org Date: Sun, 23 Jun 2024 01:56:44 +1000 The openbsd/mips64 port is effectively unmaintainable. I've been trying to upstream the direct syscall to libc conversion for two years now: https://github.com/golang/go/issues/61546 Currently, I'm carrying a bunch of extra diffs in ports, I have limited working hardware to build/test on and when it was broken in ports for multiple months, no one seemed to notice. I think it's time to simply give up. The below removes mips64 from GO_ARCHS, along with armv7 which seems like it should not be there. Remove mips64 from the lang/go Makefile and sort the MACHINE_ARCH handling list. Do the same in go.port.mk, however add riscv64 (neither mips64 or riscv64 were there - not sure what the impact was). ok? P.S. I'll deal with the removal of mips64 specific patches in the upcoming Go 1.23 bump. Index: infrastructure/mk/arch-defines.mk =================================================================== RCS file: /cvs/ports/infrastructure/mk/arch-defines.mk,v diff -u -p -r1.106 arch-defines.mk --- infrastructure/mk/arch-defines.mk 16 May 2024 11:04:44 -0000 1.106 +++ infrastructure/mk/arch-defines.mk 22 Jun 2024 15:38:10 -0000 @@ -24,7 +24,7 @@ GCC4_ARCHS = alpha hppa sh sparc64 GCC3_ARCHS = m88k # arches where certain ports are available MONO_ARCHS = aarch64 amd64 i386 -GO_ARCHS = aarch64 amd64 arm armv7 i386 mips64 riscv64 +GO_ARCHS = aarch64 amd64 arm i386 riscv64 LUAJIT_ARCHS = aarch64 arm amd64 i386 powerpc RUST_ARCHS = aarch64 amd64 i386 powerpc64 riscv64 sparc64 # arch-specific features that ocaml ports need to know about Index: lang/go/Makefile =================================================================== RCS file: /cvs/ports/lang/go/Makefile,v diff -u -p -r1.151 Makefile --- lang/go/Makefile 22 Jun 2024 12:43:03 -0000 1.151 +++ lang/go/Makefile 22 Jun 2024 15:38:10 -0000 @@ -1,6 +1,6 @@ ONLY_FOR_ARCHS = ${GO_ARCHS} -BIN_BOOTSTRAP_GOARCHS = 386 amd64 arm arm64 mips64 riscv64 +BIN_BOOTSTRAP_GOARCHS = 386 amd64 arm arm64 riscv64 BIN_BOOTSTRAP_VERSION = 1.20.4 COMMENT = Go programming language @@ -46,16 +46,14 @@ GOROOT = ${PREFIX}/go GOROOT_BOOTSTRAP = # sync with go.port.mk -.if ${MACHINE_ARCH} == "amd64" +.if ${MACHINE_ARCH} == "aarch64" +GOARCH = arm64 +.elif ${MACHINE_ARCH} == "amd64" GOARCH = amd64 .elif ${MACHINE_ARCH} == "arm" GOARCH = arm -.elif ${MACHINE_ARCH} == "aarch64" -GOARCH = arm64 .elif ${MACHINE_ARCH} == "i386" GOARCH = 386 -.elif ${MACHINE_ARCH} == "mips64" -GOARCH = mips64 .elif ${MACHINE_ARCH} == "riscv64" GOARCH = riscv64 .endif Index: lang/go/go.port.mk =================================================================== RCS file: /cvs/ports/lang/go/go.port.mk,v diff -u -p -r1.73 go.port.mk --- lang/go/go.port.mk 22 Jun 2024 14:01:40 -0000 1.73 +++ lang/go/go.port.mk 22 Jun 2024 15:38:10 -0000 @@ -23,14 +23,16 @@ _subst := ${_subst}:S/${l:U}/!$l/g BUILD_DEPENDS += ${MODGO_BUILD_DEPENDS} .endif -.if ${MACHINE_ARCH} == "amd64" +.if ${MACHINE_ARCH} == "aarch64" +_GOARCH = arm64 +.elif ${MACHINE_ARCH} == "amd64" _GOARCH = amd64 .elif ${MACHINE_ARCH} == "arm" _GOARCH = arm -.elif ${MACHINE_ARCH} == "aarch64" -_GOARCH = arm64 .elif ${MACHINE_ARCH} == "i386" _GOARCH = 386 +.elif ${MACHINE_ARCH} == "riscv64" +_GOARCH = riscv64 .endif MODGO_PACKAGE_PATH = ${PREFIX}/go-pkg