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
cmd/go: build constraints sometimes ineffective for net/cgo_resnew.go on FreeBSD #33101
Comments
The Can you reproduce this failure using a sequence of |
Ah, yeah: Cross-compiles don't enable cgo by default, for that exact reason. Do you have |
Same errors in build log https://storage.googleapis.com/go-build-log/9e20f242/freebsd-amd64-12_0_3ca8deda.log |
@cuonglm, was that a flake, or did you find a workaround? |
@bcmills it does not seem to be a flake, it occrurred when I cross-compile with cgo enable on freebsd. In my CL, I change the test to run on Linux only. |
Have the same problem here building one of our packages, confirmed on: Setting CGO_ENABLED=0 fixed it but I thought cross-compile did this by default? |
I can reproduce the observed symptom on FreeBSD 12.1 by running:
Without the explicit I note that So my question to all of you is: have you seen this issue with |
With
With
In addition removing So to confirm looks like this is fixed in |
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes. (Bumped to 1.12.7 by changing pkg repos over to latest and tried again.)
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
Downloaded sshcode and was in progress patching it for FreeBSD. Ran
ci/build.sh
.What did you expect to see?
Build success.
What did you see instead?
A few repeats of the below:
The text was updated successfully, but these errors were encountered: