2 # Copyright 2009 The Go Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style
4 # license that can be found in the LICENSE file.
8 if [ -z "$GOROOT" ] ; then
12 if [ -z "$GOOS" ] ; then
16 if [ -z "$GOARCH" ] ; then
17 echo '$GOARCH not set'
21 GOBIN="${GOBIN:-$HOME/bin}"
23 if [ "$1" != "--nopkg" ]; then
24 rm -rf "$GOROOT"/pkg/${GOOS}_$GOARCH
26 rm -f "$GOROOT"/lib/*.a
27 for i in lib9 libbio libcgo libmach cmd pkg \
28 ../misc/cgo/gmp ../misc/cgo/stdio \
29 ../test/bench ../test/garbage
31 cd "$GOROOT"/src/$i || exit 1
32 if test -f clean.bash; then