This reverts commit
c2d85eb999fcd428a1cd71ed93805cbde0c16eaa.
Reason for revert: change was incorrect. ignores setting of CGO_ENABLED in some cases
Change-Id: I8e6e68dd600be5306a247a3314f4b57175f1aa56
Reviewed-on: https://go-review.googlesource.com/c/go/+/705495
Auto-Submit: Michael Matloob <matloob@google.com>
Reviewed-by: Michael Matloob <matloob@google.com>
Reviewed-by: Michael Matloob <matloob@golang.org>
Reviewed-by: Ian Alexander <jitsu@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
if buildcfg.DefaultCGO_ENABLED == "1" {
defaultCgoEnabled = true
} else if buildcfg.DefaultCGO_ENABLED == "0" {
- }
- if runtime.GOARCH == ctxt.GOARCH && runtime.GOOS == ctxt.GOOS {
+ } else if runtime.GOARCH == ctxt.GOARCH && runtime.GOOS == ctxt.GOOS {
defaultCgoEnabled = platform.CgoSupported(ctxt.GOOS, ctxt.GOARCH)
// Use built-in default cgo setting for GOOS/GOARCH.
// Note that ctxt.GOOS/GOARCH are derived from the preference list