(15:41:48) ERROR: C:/tmp/_bazel_jannis.schnitzer/47bkkx3e/external/io_bazel_rules_go/BUILD.bazel:8:1: Couldn't build file external/io_bazel_rules_go/linux_amd64_stripped/stdlib%/pkg: GoStdlib external/io_bazel_rules_go/linux_amd64_stripped/stdlib%/pkg failed (Exit 1): stdlib.exe failed: error executing command
cd C:/tmp/_bazel_jannis.schnitzer/47bkkx3e/execroot/com_github_Xjs_proto_test
SET CC=c:/tools/msys64/mingw64/bin/gcc
SET CGO_CFLAGS=
SET CGO_CPPFLAGS=
SET CGO_ENABLED=1
SET CGO_LDFLAGS=-lstdc++
SET GOARCH=amd64
SET GOOS=linux
SET GOROOT=external/go_sdk
SET GOROOT_FINAL=GOROOT
SET PATH=c:/tools/msys64/mingw64/bin
bazel-out/host/bin/external/io_bazel_rules_go/go/tools/builders/windows_amd64_stripped/stdlib.exe -sdk external/go_sdk -installsuffix linux_amd64 -out bazel-out/x64_windows-fastbuild/bin/external/io_bazel_rules_go/linux_amd64_stripped/stdlib% -filter_buildid bazel-out/host/bin/external/io_bazel_rules_go/go/tools/builders/windows_amd64_stripped/filter_buildid.exe
# runtime/cgo
gcc_linux_amd64.c: In function '_cgo_sys_thread_start':
gcc_linux_amd64.c:62:2: error: unknown type name 'sigset_t'; did you mean '_sigset_t'?
sigset_t ign, oset;
^~~~~~~~
_sigset_t
gcc_linux_amd64.c:67:2: error: implicit declaration of function 'sigfillset' [-Werror=implicit-function-declaration]
sigfillset(&ign);
^~~~~~~~~~
gcc_linux_amd64.c:62:16: error: unused variable 'oset' [-Werror=unused-variable]
sigset_t ign, oset;
^~~~
cc1.exe: all warnings being treated as errors
GoStdlib: error running subcommand: exit status 2
Originally reported by @Xjs in #1676.
Somewhat related (?): building the same repository with --compiler=mingw-gcc like @jayconrod documented in https://github.com/bazelbuild/rules_go/issues/1613 fails with some C compiler errors: