Skip to content

Commit 9d6ab82

Browse files
committed
[dev.boringcrypto] make.bash: disable GOEXPERIMENT when using bootstrap toolchain
When using Go 1.4 this doesn't matter, but when using Go 1.17, the bootstrap toolchain will complain about unknown GOEXPERIMENT settings. Clearly GOEXPERIMENT is for the toolchain being built, not the bootstrap. For #51940. Change-Id: Iff77204391a5a66f7eecab1c7036ebe77e1a4e82 Reviewed-on: https://go-review.googlesource.com/c/go/+/395879 Trust: Russ Cox <[email protected]> Run-TryBot: Russ Cox <[email protected]> Reviewed-by: Ian Lance Taylor <[email protected]> TryBot-Result: Gopher Robot <[email protected]>
1 parent d1405d7 commit 9d6ab82

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/make.bash

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ fi
185185
# Get the exact bootstrap toolchain version to help with debugging.
186186
# We clear GOOS and GOARCH to avoid an ominous but harmless warning if
187187
# the bootstrap doesn't support them.
188-
GOROOT_BOOTSTRAP_VERSION=$(GOOS= GOARCH= $GOROOT_BOOTSTRAP/bin/go version | sed 's/go version //')
188+
GOROOT_BOOTSTRAP_VERSION=$(GOOS= GOARCH= GOEXPERIMENT= $GOROOT_BOOTSTRAP/bin/go version | sed 's/go version //')
189189
echo "Building Go cmd/dist using $GOROOT_BOOTSTRAP. ($GOROOT_BOOTSTRAP_VERSION)"
190190
if $verbose; then
191191
echo cmd/dist
@@ -196,7 +196,7 @@ if [ "$GOROOT_BOOTSTRAP" = "$GOROOT" ]; then
196196
exit 1
197197
fi
198198
rm -f cmd/dist/dist
199-
GOROOT="$GOROOT_BOOTSTRAP" GOOS="" GOARCH="" GO111MODULE=off "$GOROOT_BOOTSTRAP/bin/go" build -o cmd/dist/dist ./cmd/dist
199+
GOROOT="$GOROOT_BOOTSTRAP" GOOS="" GOARCH="" GO111MODULE=off GOEXPERIMENT= "$GOROOT_BOOTSTRAP/bin/go" build -o cmd/dist/dist ./cmd/dist
200200

201201
# -e doesn't propagate out of eval, so check success by hand.
202202
eval $(./cmd/dist/dist env -p || echo FAIL=true)

0 commit comments

Comments
 (0)