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
GOOS/GOARCH pair validity is checked before flags are parsed #43597
Comments
On a related note, it would be very helpful to be able to bypass GOOS/GOARCH validity check at the Let me know if this better be a separate feature request, and I'll file a new issue. |
Duplicate of #24398 |
Thanks Bryan for triaging the issue and apologies for not finding the original one. Could you also comment on whether an option to disable this check would be a reasonable change? If so, I'll try to prepare a CL for it. |
The check should already only occur when using the |
Actually, I'm not sure that this is even still an issue. Have you tested with |
Right, it does seem to work as expected with |
What version of Go are you using (
go version
)?Does this issue reproduce with the latest release?
Yes.
What operating system and processor architecture are you using (
go env
)?go env
OutputWhat did you do?
What did you expect to see?
Successful invocation of gccgo toolchain (possibly failing inside a gccgo).
What did you see instead?
Additional context
I am investigating integrating GopherJS compiler with standard go tooling as a third-party compiler similar to gccgo, in order to support GOOS=js GOARCH=js build target. This check is meant to be skipped for compilers other than
gc
, but CheckGOOSARCHPair() is called before compiler flag is parsed and set, causing a spurious error.I suspect that there may be other checks that don't work as intended because they run against default flag values instead of real ones, I was able to find one example nearby, but probably there are more.
The text was updated successfully, but these errors were encountered: