]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/vet/all: disable cgo when running 'go install'
authorJosh Bleecher Snyder <josharian@gmail.com>
Tue, 28 Feb 2017 23:24:18 +0000 (15:24 -0800)
committerBrad Fitzpatrick <bradfitz@golang.org>
Tue, 28 Feb 2017 23:25:22 +0000 (23:25 +0000)
Change-Id: Iab1e84624c0288ebdd33fbe83bd60948b5d91fc4
Reviewed-on: https://go-review.googlesource.com/37612
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
src/cmd/vet/all/main.go

index 302041580a8f8f7aeb2da4ffa07ce40ecc81d747..70111116597f89e780bb705b07c9af68b8fbad72 100644 (file)
@@ -221,7 +221,7 @@ func (p platform) vet(ncpus int) {
        w := make(whitelist)
        w.load(p.os, p.arch)
 
-       env := append(os.Environ(), "GOOS="+p.os, "GOARCH="+p.arch)
+       env := append(os.Environ(), "GOOS="+p.os, "GOARCH="+p.arch, "CGO_ENABLED=0")
 
        // Do 'go install std' before running vet.
        // It is cheap when already installed.