This libgo patch by Svante Signell adds some Hurd portability patches to libgo. These are from GCC PR 93020. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline.
Ian
Index: gcc/go/gofrontend/MERGE =================================================================== --- gcc/go/gofrontend/MERGE (revision 279398) +++ gcc/go/gofrontend/MERGE (working copy) @@ -1,4 +1,4 @@ -85641a0f26061f7c98db42a2adb3250c07ce504e +393957c8b68e370504209eb901aa0c3874e256d4 The first line of this file holds the git revision number of the last merge done from the gofrontend repository. Index: libgo/go/internal/poll/errno_unix.go =================================================================== --- libgo/go/internal/poll/errno_unix.go (revision 279398) +++ libgo/go/internal/poll/errno_unix.go (working copy) @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris +// +build aix darwin dragonfly freebsd hurd linux netbsd openbsd solaris package poll Index: libgo/go/os/export_unix_test.go =================================================================== --- libgo/go/os/export_unix_test.go (revision 279398) +++ libgo/go/os/export_unix_test.go (working copy) @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build aix darwin dragonfly freebsd js,wasm linux nacl netbsd openbsd solaris +// +build aix darwin dragonfly freebsd hurd js,wasm linux nacl netbsd openbsd solaris package os Index: libgo/go/runtime/os_hurd.go =================================================================== --- libgo/go/runtime/os_hurd.go (revision 279398) +++ libgo/go/runtime/os_hurd.go (working copy) @@ -112,7 +112,7 @@ func semawakeup(mp *m) { } func getncpu() int32 { - n := int32(sysconf(_SC_NPROCESSORS_ONLN)) + n := int32(sysconf(__SC_NPROCESSORS_ONLN)) if n < 1 { return 1 } Index: libgo/go/syscall/export_unix_test.go =================================================================== --- libgo/go/syscall/export_unix_test.go (revision 279398) +++ libgo/go/syscall/export_unix_test.go (working copy) @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. -// +build aix darwin dragonfly freebsd linux netbsd openbsd solaris +// +build aix darwin dragonfly freebsd hurd linux netbsd openbsd solaris package syscall