aboutsummaryrefslogtreecommitdiff
path: root/src/make.bash
diff options
context:
space:
mode:
authorRuss Cox <rsc@golang.org>2015-01-14 11:50:21 -0500
committerRuss Cox <rsc@golang.org>2015-01-14 18:49:21 +0000
commitdb47a2706fb1078f6c5ddbaabc5bc09615c0457b (patch)
treea253231ced31d09678241c162df9f2e0b3f1b70e /src/make.bash
parentb46b9429f05362b2b2227861811e50b47b9ec928 (diff)
downloadgo-db47a2706fb1078f6c5ddbaabc5bc09615c0457b.tar.gz
go-db47a2706fb1078f6c5ddbaabc5bc09615c0457b.zip
[dev.cc] build: fix cross-compilation
Fixes #9574. Change-Id: Ifd7ecccb25e934f9aba284b2d72b6b22f18cb0b6 Reviewed-on: https://go-review.googlesource.com/2812 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Diffstat (limited to 'src/make.bash')
-rwxr-xr-xsrc/make.bash2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/make.bash b/src/make.bash
index 54c4d61249..2b07ee7780 100755
--- a/src/make.bash
+++ b/src/make.bash
@@ -121,7 +121,7 @@ if [ ! -x "$GOROOT_BOOTSTRAP/bin/go" ]; then
echo "Set \$GOROOT_BOOTSTRAP to a working Go tree >= Go 1.4." >&2
fi
rm -f cmd/dist/dist
-GOROOT="$GOROOT_BOOTSTRAP" "$GOROOT_BOOTSTRAP/bin/go" build -o cmd/dist/dist ./cmd/dist
+GOROOT="$GOROOT_BOOTSTRAP" GOOS="$GOHOSTOS" GOARCH="$GOHOSTARCH" "$GOROOT_BOOTSTRAP/bin/go" build -o cmd/dist/dist ./cmd/dist
# -e doesn't propagate out of eval, so check success by hand.
eval $(./cmd/dist/dist env -p || echo FAIL=true)