summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xdoc/progs/run2
-rw-r--r--misc/cgo/gmp/Makefile4
-rw-r--r--misc/cgo/stdio/Makefile4
-rw-r--r--src/Make.cmd13
-rw-r--r--src/Make.conf6
-rw-r--r--src/Make.pkg18
-rwxr-xr-xsrc/clean.bash4
-rw-r--r--src/cmd/5a/Makefile4
-rw-r--r--src/cmd/5c/Makefile4
-rw-r--r--src/cmd/5g/Makefile4
-rw-r--r--src/cmd/5l/Makefile4
-rw-r--r--src/cmd/6a/Makefile4
-rw-r--r--src/cmd/6c/Makefile4
-rw-r--r--src/cmd/6g/Makefile4
-rw-r--r--src/cmd/6l/Makefile4
-rw-r--r--src/cmd/8a/Makefile4
-rw-r--r--src/cmd/8c/Makefile4
-rw-r--r--src/cmd/8g/Makefile4
-rw-r--r--src/cmd/8l/Makefile4
-rw-r--r--src/cmd/cgo/Makefile4
-rw-r--r--src/cmd/cov/Makefile4
-rw-r--r--src/cmd/ebnflint/Makefile6
-rwxr-xr-xsrc/cmd/gc/mkbuiltin2
-rw-r--r--src/cmd/godefs/Makefile4
-rw-r--r--src/cmd/godoc/Makefile4
-rw-r--r--src/cmd/gofmt/Makefile6
-rwxr-xr-xsrc/cmd/gofmt/test.sh28
-rw-r--r--src/cmd/gopack/Makefile4
-rw-r--r--src/cmd/gotest/Makefile4
-rwxr-xr-xsrc/cmd/gotest/gotest2
-rw-r--r--src/cmd/goyacc/Makefile4
-rw-r--r--src/cmd/hgpatch/Makefile4
-rwxr-xr-xsrc/cmd/make.bash2
-rw-r--r--src/cmd/nm/Makefile4
-rw-r--r--src/cmd/prof/Makefile4
-rw-r--r--src/lib9/Makefile8
-rw-r--r--src/libbio/Makefile6
-rw-r--r--src/libcgo/Makefile11
-rw-r--r--src/libmach/Makefile6
-rwxr-xr-xsrc/make-arm.bash2
-rwxr-xr-xsrc/make.bash16
-rw-r--r--src/pkg/Makefile2
-rw-r--r--src/pkg/archive/tar/Makefile4
-rw-r--r--src/pkg/asn1/Makefile4
-rw-r--r--src/pkg/big/Makefile4
-rw-r--r--src/pkg/bignum/Makefile4
-rw-r--r--src/pkg/bufio/Makefile4
-rw-r--r--src/pkg/bytes/Makefile4
-rw-r--r--src/pkg/compress/flate/Makefile4
-rw-r--r--src/pkg/compress/gzip/Makefile4
-rw-r--r--src/pkg/compress/zlib/Makefile4
-rw-r--r--src/pkg/container/heap/Makefile4
-rw-r--r--src/pkg/container/list/Makefile4
-rw-r--r--src/pkg/container/ring/Makefile4
-rw-r--r--src/pkg/container/vector/Makefile4
-rw-r--r--src/pkg/crypto/aes/Makefile4
-rw-r--r--src/pkg/crypto/block/Makefile4
-rw-r--r--src/pkg/crypto/hmac/Makefile4
-rw-r--r--src/pkg/crypto/md5/Makefile4
-rw-r--r--src/pkg/crypto/rc4/Makefile4
-rw-r--r--src/pkg/crypto/rsa/Makefile4
-rw-r--r--src/pkg/crypto/sha1/Makefile4
-rw-r--r--src/pkg/crypto/subtle/Makefile4
-rw-r--r--src/pkg/crypto/tls/Makefile4
-rw-r--r--src/pkg/crypto/x509/Makefile4
-rw-r--r--src/pkg/debug/dwarf/Makefile4
-rw-r--r--src/pkg/debug/elf/Makefile4
-rw-r--r--src/pkg/debug/gosym/Makefile4
-rw-r--r--src/pkg/debug/macho/Makefile4
-rw-r--r--src/pkg/debug/proc/Makefile4
-rw-r--r--src/pkg/ebnf/Makefile4
-rw-r--r--src/pkg/encoding/ascii85/Makefile4
-rw-r--r--src/pkg/encoding/base64/Makefile4
-rw-r--r--src/pkg/encoding/binary/Makefile4
-rw-r--r--src/pkg/encoding/git85/Makefile4
-rw-r--r--src/pkg/encoding/hex/Makefile4
-rw-r--r--src/pkg/encoding/pem/Makefile4
-rw-r--r--src/pkg/exec/Makefile4
-rw-r--r--src/pkg/exp/datafmt/Makefile4
-rw-r--r--src/pkg/exp/draw/Makefile4
-rw-r--r--src/pkg/exp/eval/Makefile4
-rwxr-xr-xsrc/pkg/exp/eval/test.bash4
-rw-r--r--src/pkg/exp/exception/Makefile4
-rw-r--r--src/pkg/exp/iterable/Makefile4
-rw-r--r--src/pkg/exp/nacl/av/Makefile4
-rw-r--r--src/pkg/exp/nacl/srpc/Makefile4
-rw-r--r--src/pkg/exp/ogle/Makefile4
-rw-r--r--src/pkg/expvar/Makefile4
-rw-r--r--src/pkg/flag/Makefile4
-rw-r--r--src/pkg/fmt/Makefile4
-rw-r--r--src/pkg/go/ast/Makefile4
-rw-r--r--src/pkg/go/doc/Makefile4
-rw-r--r--src/pkg/go/parser/Makefile4
-rw-r--r--src/pkg/go/printer/Makefile4
-rw-r--r--src/pkg/go/scanner/Makefile4
-rw-r--r--src/pkg/go/token/Makefile4
-rw-r--r--src/pkg/gob/Makefile4
-rw-r--r--src/pkg/hash/Makefile4
-rw-r--r--src/pkg/hash/adler32/Makefile4
-rw-r--r--src/pkg/hash/crc32/Makefile4
-rw-r--r--src/pkg/http/Makefile4
-rw-r--r--src/pkg/image/Makefile4
-rw-r--r--src/pkg/image/png/Makefile4
-rw-r--r--src/pkg/io/Makefile4
-rw-r--r--src/pkg/json/Makefile4
-rw-r--r--src/pkg/log/Makefile4
-rw-r--r--src/pkg/malloc/Makefile4
-rw-r--r--src/pkg/math/Makefile4
-rw-r--r--src/pkg/net/Makefile4
-rw-r--r--src/pkg/once/Makefile4
-rw-r--r--src/pkg/os/Makefile4
-rw-r--r--src/pkg/patch/Makefile4
-rw-r--r--src/pkg/path/Makefile4
-rw-r--r--src/pkg/rand/Makefile4
-rw-r--r--src/pkg/reflect/Makefile4
-rw-r--r--src/pkg/regexp/Makefile4
-rw-r--r--src/pkg/rpc/Makefile4
-rw-r--r--src/pkg/runtime/Makefile4
-rw-r--r--src/pkg/sort/Makefile4
-rw-r--r--src/pkg/strconv/Makefile4
-rw-r--r--src/pkg/strings/Makefile4
-rw-r--r--src/pkg/sync/Makefile4
-rw-r--r--src/pkg/syscall/Makefile4
-rw-r--r--src/pkg/tabwriter/Makefile4
-rw-r--r--src/pkg/template/Makefile4
-rw-r--r--src/pkg/testing/Makefile4
-rw-r--r--src/pkg/testing/iotest/Makefile4
-rw-r--r--src/pkg/testing/quick/Makefile4
-rw-r--r--src/pkg/testing/script/Makefile4
-rw-r--r--src/pkg/time/Makefile4
-rw-r--r--src/pkg/unicode/Makefile4
-rw-r--r--src/pkg/utf8/Makefile4
-rw-r--r--src/pkg/xml/Makefile4
-rwxr-xr-xsrc/sudo.bash2
-rwxr-xr-xtest/bench/timing.sh2
135 files changed, 310 insertions, 294 deletions
diff --git a/doc/progs/run b/doc/progs/run
index 46de91250..71999ece9 100755
--- a/doc/progs/run
+++ b/doc/progs/run
@@ -3,7 +3,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-. $GOROOT/src/Make.$GOARCH
+. "$GOROOT"/src/Make.$GOARCH
if [ -z "$O" ]; then
echo 'missing $O - maybe no Make.$GOARCH?' 1>&2
diff --git a/misc/cgo/gmp/Makefile b/misc/cgo/gmp/Makefile
index c92458c90..ad5db33c2 100644
--- a/misc/cgo/gmp/Makefile
+++ b/misc/cgo/gmp/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../src/Make.$(GOARCH)
TARG=gmp
@@ -22,7 +22,7 @@ CGO_LDFLAGS=-lgmp
CLEANFILES+=pi fib
-include $(GOROOT)/src/Make.pkg
+include ../../../src/Make.pkg
# Simple test programs
diff --git a/misc/cgo/stdio/Makefile b/misc/cgo/stdio/Makefile
index 83b1ed9e5..7ff8c3007 100644
--- a/misc/cgo/stdio/Makefile
+++ b/misc/cgo/stdio/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../src/Make.$(GOARCH)
TARG=stdio
CGOFILES=\
@@ -10,7 +10,7 @@ CGOFILES=\
CLEANFILES+=hello fib chain run.out
-include $(GOROOT)/src/Make.pkg
+include ../../../src/Make.pkg
%: install %.go
$(GC) $*.go
diff --git a/src/Make.cmd b/src/Make.cmd
index 656ea5531..7cf0a5b53 100644
--- a/src/Make.cmd
+++ b/src/Make.cmd
@@ -7,6 +7,11 @@ ifndef GOBIN
GOBIN=$(HOME)/bin
endif
+# ugly hack to deal with whitespaces in $GOBIN
+nullstring :=
+space := $(nullstring) # a space at the end
+QUOTED_GOBIN=$(subst $(space),\ ,$(GOBIN))
+
all: $(TARG)
$(TARG): _go_.$O $(OFILES)
@@ -15,13 +20,13 @@ $(TARG): _go_.$O $(OFILES)
_go_.$O: $(GOFILES)
$(GC) -o $@ $(GOFILES)
-install: $(GOBIN)/$(TARG)
+install: $(QUOTED_GOBIN)/$(TARG)
-$(GOBIN)/$(TARG): $(TARG)
- cp $(TARG) $@
+$(QUOTED_GOBIN)/$(TARG): $(TARG)
+ cp -f $(TARG) $(QUOTED_GOBIN)
clean:
rm -f *.[$(OS)] $(TARG) $(CLEANFILES)
nuke:
- rm -f *.[$(OS)] $(TARG) $(CLEANFILES) $(GOBIN)/$(TARG)
+ rm -f *.[$(OS)] $(TARG) $(CLEANFILES) $(QUOTED_GOBIN)/$(TARG)
diff --git a/src/Make.conf b/src/Make.conf
index 02268ce2d..21eee4678 100644
--- a/src/Make.conf
+++ b/src/Make.conf
@@ -4,14 +4,14 @@
CC=quietgcc
LD=quietgcc
-CFLAGS=-ggdb -I$(GOROOT)/include -O2 -fno-inline
+CFLAGS=-ggdb -I"$(GOROOT)"/include -O2 -fno-inline
O=o
YFLAGS=-d
# GNU Make syntax:
ifndef GOBIN
-GOBIN=$(HOME)/bin
+GOBIN="$(HOME)/bin"
endif
PWD=$(shell pwd)
%.$O: %.c
- $(CC) $(CFLAGS) -c $(PWD)/$*.c
+ $(CC) $(CFLAGS) -c "$(PWD)"/$*.c
diff --git a/src/Make.pkg b/src/Make.pkg
index 29d028d54..26d6e20ee 100644
--- a/src/Make.pkg
+++ b/src/Make.pkg
@@ -12,7 +12,13 @@ TARG_words=$(subst /, ,$(TARG))
elem=$(word $(words $(TARG_words)),$(TARG_words))
dir=$(patsubst %/$(elem),%,./$(TARG))
-pkgdir=$(GOROOT)/pkg/$(GOOS)_$(GOARCH)
+
+# ugly hack to deal with whitespaces in $GOROOT
+nullstring :=
+space := $(nullstring) # a space at the end
+QUOTED_GOROOT=$(subst $(space),\ ,$(GOROOT))
+
+pkgdir=$(QUOTED_GOROOT)/pkg/$(GOOS)_$(GOARCH)
INSTALLFILES=$(pkgdir)/$(TARG).a
@@ -43,8 +49,8 @@ testpackage-clean:
install: $(INSTALLFILES)
$(pkgdir)/$(TARG).a: package
- @test -d $(GOROOT)/pkg && mkdir -p $(pkgdir)/$(dir)
- cp _obj/$(TARG).a $@
+ @test -d $(QUOTED_GOROOT)/pkg && mkdir -p $(pkgdir)/$(dir)
+ cp _obj/$(TARG).a "$@"
_go_.$O: $(GOFILES) $(PREREQ)
$(GC) -o $@ $(GOFILES)
@@ -96,7 +102,7 @@ dir:
# Compile x.cgo3.c with 6c; needs access to the runtime headers.
RUNTIME_CFLAGS_amd64=-D_64BIT
-RUNTIME_CFLAGS=-I$(GOROOT)/src/pkg/runtime $(RUNTIME_CFLAGS_$(GOARCH))
+RUNTIME_CFLAGS=-I"$(GOROOT)/src/pkg/runtime" $(RUNTIME_CFLAGS_$(GOARCH))
%.cgo3.$O: %.cgo3.c
$(CC) $(CFLAGS) $(RUNTIME_CFLAGS) $*.cgo3.c
@@ -116,8 +122,8 @@ $(elem)_%.so: %.cgo4.o
gcc $(_CGO_CFLAGS_$(GOARCH)) -o $@ $*.cgo4.o $(CGO_LDFLAGS) $(_CGO_LDFLAGS_$(GOOS))
$(pkgdir)/$(dir)/$(elem)_%.so: $(elem)_%.so
- @test -d $(GOROOT)/pkg && mkdir -p $(pkgdir)/$(dir)
- cp $(elem)_$*.so $@
+ @test -d $(QUOTED_GOROOT/pkg && mkdir -p $(pkgdir)/$(dir)
+ cp $(elem)_$*.so "$@"
# Generic build rules.
# These come last so that the rules above can override them
diff --git a/src/clean.bash b/src/clean.bash
index 411321b55..f6fc6d1f5 100755
--- a/src/clean.bash
+++ b/src/clean.bash
@@ -3,8 +3,8 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-rm -rf $GOROOT/pkg/${GOOS}_$GOARCH
-rm -f $GOROOT/lib/*.a
+rm -rf "$GOROOT"/pkg/${GOOS}_$GOARCH
+rm -f "$GOROOT"/lib/*.a
for i in lib9 libbio libcgo libmach cmd pkg \
../misc/cgo/gmp ../misc/cgo/stdio \
../test/bench
diff --git a/src/cmd/5a/Makefile b/src/cmd/5a/Makefile
index 87c9d68cd..f01b017da 100644
--- a/src/cmd/5a/Makefile
+++ b/src/cmd/5a/Makefile
@@ -21,7 +21,7 @@ YFILES=\
a.y\
$(TARG): $(OFILES)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) -lbio -l9
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) -lbio -l9
$(OFILES): $(HFILES)
@@ -37,4 +37,4 @@ clean:
rm -f *.$O $(TARG) *.5 enam.c 5.out a.out y.tab.h y.tab.c
install: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
diff --git a/src/cmd/5c/Makefile b/src/cmd/5c/Makefile
index be9f4c52a..b534206f3 100644
--- a/src/cmd/5c/Makefile
+++ b/src/cmd/5c/Makefile
@@ -29,7 +29,7 @@ LIB=\
../cc/cc.a$O
$(TARG): $(OFILES) $(LIB)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) $(LIB) -lbio -l9
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) $(LIB) -lbio -l9
$(OFILES): $(HFILES)
@@ -37,7 +37,7 @@ clean:
rm -f *.$O $(TARG) *.5 enam.c 5.out a.out
install: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
%.$O: ../cc/%.c
$(CC) $(CFLAGS) -c -I. -o $@ ../cc/$*.c
diff --git a/src/cmd/5g/Makefile b/src/cmd/5g/Makefile
index 05915a75e..123af19cd 100644
--- a/src/cmd/5g/Makefile
+++ b/src/cmd/5g/Makefile
@@ -27,7 +27,7 @@ LIB=\
../gc/gc.a$O
$(TARG): $(OFILES) $(LIB)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) $(LIB) -lbio -l9 -lm
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) $(LIB) -lbio -l9 -lm
$(OFILES): $(HFILES)
@@ -35,4 +35,4 @@ clean:
rm -f *.o $(TARG) *.5 enam.c 5.out a.out
install: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
diff --git a/src/cmd/5l/Makefile b/src/cmd/5l/Makefile
index b04211504..be866b87a 100644
--- a/src/cmd/5l/Makefile
+++ b/src/cmd/5l/Makefile
@@ -25,7 +25,7 @@ HFILES=\
../5l/5.out.h\
$(TARG): $(OFILES)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) -lbio -l9
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) -lbio -l9
$(OFILES): $(HFILES)
@@ -36,7 +36,7 @@ clean:
rm -f *.o $(TARG) *.5 enam.c 5.out a.out
install: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
%.$O: ../ld/%.c
$(CC) $(CFLAGS) -c -I. ../ld/$*.c
diff --git a/src/cmd/6a/Makefile b/src/cmd/6a/Makefile
index 0050921b5..21d824708 100644
--- a/src/cmd/6a/Makefile
+++ b/src/cmd/6a/Makefile
@@ -21,7 +21,7 @@ YFILES=\
a.y\
$(TARG): $(OFILES)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) -lbio -l9
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) -lbio -l9
$(OFILES): $(HFILES)
@@ -37,4 +37,4 @@ clean:
rm -f *.$O $(TARG) *.6 enam.c 6.out a.out y.tab.h y.tab.c
install: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
diff --git a/src/cmd/6c/Makefile b/src/cmd/6c/Makefile
index 1cae39e1b..1bf1da9d3 100644
--- a/src/cmd/6c/Makefile
+++ b/src/cmd/6c/Makefile
@@ -30,7 +30,7 @@ LIB=\
../cc/cc.a$O
$(TARG): $(OFILES) $(LIB)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) $(LIB) -lbio -l9
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) $(LIB) -lbio -l9
$(OFILES): $(HFILES)
@@ -38,7 +38,7 @@ clean:
rm -f *.$O $(TARG) *.6 enam.c 6.out a.out
install: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
%.$O: ../cc/%.c
$(CC) $(CFLAGS) -c -I. -o $@ ../cc/$*.c
diff --git a/src/cmd/6g/Makefile b/src/cmd/6g/Makefile
index 6538c5528..a6d3eb762 100644
--- a/src/cmd/6g/Makefile
+++ b/src/cmd/6g/Makefile
@@ -28,7 +28,7 @@ LIB=\
../gc/gc.a$O
$(TARG): $(OFILES) $(LIB)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) $(LIB) -lbio -l9 -lm
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) $(LIB) -lbio -l9 -lm
$(OFILES): $(HFILES)
@@ -36,4 +36,4 @@ clean:
rm -f $(TARG) enam.c 6.out a.out *.$O *.6
install: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
diff --git a/src/cmd/6l/Makefile b/src/cmd/6l/Makefile
index 3260c15a7..72bde4465 100644
--- a/src/cmd/6l/Makefile
+++ b/src/cmd/6l/Makefile
@@ -28,7 +28,7 @@ HFILES=\
../ld/macho.h\
$(TARG): $(OFILES)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) -lbio -l9
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) -lbio -l9
$(OFILES): $(HFILES)
@@ -39,7 +39,7 @@ clean:
rm -f *.$O $(TARG) *.6 enam.c 6.out a.out
install: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
%.$O: ../ld/%.c
$(CC) $(CFLAGS) -c -I. ../ld/$*.c
diff --git a/src/cmd/8a/Makefile b/src/cmd/8a/Makefile
index cb5897e08..beb575544 100644
--- a/src/cmd/8a/Makefile
+++ b/src/cmd/8a/Makefile
@@ -21,7 +21,7 @@ YFILES=\
a.y\
$(TARG): $(OFILES)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) -lbio -l9
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) -lbio -l9
$(OFILES): $(HFILES)
@@ -37,4 +37,4 @@ clean:
rm -f *.$O $(TARG) *.6 enam.c 6.out a.out y.tab.h y.tab.c
install: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
diff --git a/src/cmd/8c/Makefile b/src/cmd/8c/Makefile
index 0f3973910..85ea3013b 100644
--- a/src/cmd/8c/Makefile
+++ b/src/cmd/8c/Makefile
@@ -32,7 +32,7 @@ LIB=\
../cc/cc.a$O
$(TARG): $(OFILES) $(LIB)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) $(LIB) -lm -lbio -l9
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) $(LIB) -lm -lbio -l9
$(OFILES): $(HFILES)
@@ -40,7 +40,7 @@ clean:
rm -f *.$O $(TARG) *.8 8.out a.out
install: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
%.$O: ../cc/%.c
$(CC) $(CFLAGS) -c -I. -o $@ ../cc/$*.c
diff --git a/src/cmd/8g/Makefile b/src/cmd/8g/Makefile
index b2b9d91d6..ea1f178d2 100644
--- a/src/cmd/8g/Makefile
+++ b/src/cmd/8g/Makefile
@@ -29,7 +29,7 @@ LIB=\
../gc/gc.a$O
$(TARG): $(OFILES) $(LIB)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) $(LIB) -lbio -l9 -lm
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) $(LIB) -lbio -l9 -lm
$(OFILES): $(HFILES)
@@ -37,4 +37,4 @@ clean:
rm -f *.$O $(TARG) *.8 enam.c 8.out a.out
install: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
diff --git a/src/cmd/8l/Makefile b/src/cmd/8l/Makefile
index 088174877..52bd021c3 100644
--- a/src/cmd/8l/Makefile
+++ b/src/cmd/8l/Makefile
@@ -28,7 +28,7 @@ HFILES=\
$(TARG): $(OFILES)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) -lbio -l9
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) -lbio -l9
$(OFILES): $(HFILES)
@@ -39,7 +39,7 @@ clean:
rm -f *.$O $(TARG) *.8 enam.c 8.out a.out
install: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
%.$O: ../ld/%.c
$(CC) $(CFLAGS) -c -I. ../ld/$*.c
diff --git a/src/cmd/cgo/Makefile b/src/cmd/cgo/Makefile
index 2c62cbdf5..34ca3dd46 100644
--- a/src/cmd/cgo/Makefile
+++ b/src/cmd/cgo/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=cgo
GOFILES=\
@@ -12,4 +12,4 @@ GOFILES=\
out.go\
util.go\
-include $(GOROOT)/src/Make.cmd
+include ../../Make.cmd
diff --git a/src/cmd/cov/Makefile b/src/cmd/cov/Makefile
index 293ff399a..58cb2302c 100644
--- a/src/cmd/cov/Makefile
+++ b/src/cmd/cov/Makefile
@@ -17,7 +17,7 @@ HFILES=\
tree.h\
$(TARG): $(OFILES)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) -lmach -lbio -l9
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) -lmach -lbio -l9
clean:
rm -f *.$O $(TARG)
@@ -31,6 +31,6 @@ install-darwin: $(TARG)
@true
install-default: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
$(OFILES): $(HFILES)
diff --git a/src/cmd/ebnflint/Makefile b/src/cmd/ebnflint/Makefile
index 6e42ba8d2..9c482446a 100644
--- a/src/cmd/ebnflint/Makefile
+++ b/src/cmd/ebnflint/Makefile
@@ -2,14 +2,14 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=ebnflint
GOFILES=\
ebnflint.go\
-include $(GOROOT)/src/Make.cmd
+include ../../Make.cmd
test: $(TARG)
- $(TARG) -start="SourceFile" $(GOROOT)/doc/go_spec.html
+ $(TARG) -start="SourceFile" "$(GOROOT)"/doc/go_spec.html
diff --git a/src/cmd/gc/mkbuiltin b/src/cmd/gc/mkbuiltin
index 7fa717053..7fe11caf7 100755
--- a/src/cmd/gc/mkbuiltin
+++ b/src/cmd/gc/mkbuiltin
@@ -5,7 +5,7 @@
set -e
-. $GOROOT/src/Make.$GOARCH
+. "$GOROOT"/src/Make.$GOARCH
if [ -z "$GC" ]; then
echo 'missing $GC - maybe no Make.$GOARCH?' 1>&2
exit 1
diff --git a/src/cmd/godefs/Makefile b/src/cmd/godefs/Makefile
index d3215c87d..49244f152 100644
--- a/src/cmd/godefs/Makefile
+++ b/src/cmd/godefs/Makefile
@@ -13,12 +13,12 @@ OFILES=\
HFILES=a.h
$(TARG): $(OFILES)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) -lbio -l9
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) -lbio -l9
clean:
rm -f *.$O $(TARG)
install: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
$(OFILES): $(HFILES)
diff --git a/src/cmd/godoc/Makefile b/src/cmd/godoc/Makefile
index f24b50966..dcd4e5b4e 100644
--- a/src/cmd/godoc/Makefile
+++ b/src/cmd/godoc/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=godoc
GOFILES=\
@@ -12,4 +12,4 @@ GOFILES=\
snippet.go\
spec.go\
-include $(GOROOT)/src/Make.cmd
+include ../../Make.cmd
diff --git a/src/cmd/gofmt/Makefile b/src/cmd/gofmt/Makefile
index dbc134f88..2294fd1db 100644
--- a/src/cmd/gofmt/Makefile
+++ b/src/cmd/gofmt/Makefile
@@ -2,18 +2,18 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=gofmt
GOFILES=\
gofmt.go\
rewrite.go\
-include $(GOROOT)/src/Make.cmd
+include ../../Make.cmd
test: $(TARG)
./test.sh
smoketest: $(TARG)
- ./test.sh $(GOROOT)/src/pkg/go/parser/parser.go
+ ./test.sh "$(GOROOT)"/src/pkg/go/parser/parser.go
diff --git a/src/cmd/gofmt/test.sh b/src/cmd/gofmt/test.sh
index 8af8900e6..8912923f7 100755
--- a/src/cmd/gofmt/test.sh
+++ b/src/cmd/gofmt/test.sh
@@ -3,7 +3,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-. $GOROOT/src/Make.$GOARCH
+. "$GOROOT"/src/Make.$GOARCH
if [ -z "$O" ]; then
echo 'missing $O - maybe no Make.$GOARCH?' 1>&2
exit 1
@@ -28,14 +28,14 @@ count() {
# apply to one file
apply1() {
#echo $1 $2
- case `basename $F` in
+ case `basename "$F"` in
# the following files are skipped because they are test cases
# for syntax errors and thus won't parse in the first place:
func3.go | const2.go | \
bug014.go | bug050.go | bug068.go | bug083.go | bug088.go | \
bug106.go | bug121.go | bug125.go | bug133.go | bug160.go | \
bug163.go | bug166.go | bug169.go | bug217.go ) ;;
- * ) $1 $2; count $F;;
+ * ) "$1" "$2"; count "$F";;
esac
}
@@ -43,15 +43,15 @@ apply1() {
# apply to local files
applydot() {
for F in `find . -name "*.go" | grep -v "._"`; do
- apply1 $1 $F
+ apply1 "$1" $F
done
}
# apply to all .go files we can find
apply() {
- for F in `find $GOROOT -name "*.go" | grep -v "._"`; do
- apply1 $1 $F
+ for F in `find "$GOROOT" -name "*.go" | grep -v "._"`; do
+ apply1 "$1" $F
done
}
@@ -63,7 +63,7 @@ cleanup() {
silent() {
cleanup
- $CMD $1 > /dev/null 2> $TMP1
+ $CMD "$1" > /dev/null 2> $TMP1
if [ $? != 0 ]; then
cat $TMP1
echo "Error (silent mode test): test.sh $1"
@@ -74,7 +74,7 @@ silent() {
idempotent() {
cleanup
- $CMD $1 > $TMP1
+ $CMD "$1" > $TMP1
if [ $? != 0 ]; then
echo "Error (step 1 of idempotency test): test.sh $1"
exit 1
@@ -103,7 +103,7 @@ idempotent() {
valid() {
cleanup
- $CMD $1 > $TMP1
+ $CMD "$1" > $TMP1
if [ $? != 0 ]; then
echo "Error (step 1 of validity test): test.sh $1"
exit 1
@@ -120,11 +120,11 @@ valid() {
runtest() {
#echo "Testing silent mode"
cleanup
- $1 silent $2
+ "$1" silent "$2"
#echo "Testing idempotency"
cleanup
- $1 idempotent $2
+ "$1" idempotent "$2"
}
@@ -137,15 +137,15 @@ runtests() {
cleanup
applydot valid
else
- for F in $*; do
- runtest apply1 $F
+ for F in "$*"; do
+ runtest apply1 "$F"
done
fi
}
# run over all .go files
-runtests $*
+runtests "$*"
cleanup
# done
diff --git a/src/cmd/gopack/Makefile b/src/cmd/gopack/Makefile
index d95c9dd9d..c3c136f42 100644
--- a/src/cmd/gopack/Makefile
+++ b/src/cmd/gopack/Makefile
@@ -9,10 +9,10 @@ OFILES=\
ar.$O\
$(TARG): $(OFILES)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) -lmach -lbio -l9
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) -lmach -lbio -l9
clean:
rm -f *.$O $(TARG)
install: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
diff --git a/src/cmd/gotest/Makefile b/src/cmd/gotest/Makefile
index 8a1f02386..b20b1daff 100644
--- a/src/cmd/gotest/Makefile
+++ b/src/cmd/gotest/Makefile
@@ -10,5 +10,5 @@ clean:
@true
install: $(TARG)
- ! test -f $(GOBIN)/$(TARG) || chmod u+w $(GOBIN)/$(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ ! test -f "$(GOBIN)"/$(TARG) || chmod u+w "$(GOBIN)"/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
diff --git a/src/cmd/gotest/gotest b/src/cmd/gotest/gotest
index 5f87b4791..75fd19217 100755
--- a/src/cmd/gotest/gotest
+++ b/src/cmd/gotest/gotest
@@ -21,7 +21,7 @@ if [ ! -f [Mm]akefile ]; then
exit 2
fi
-. $GOROOT/src/Make.$GOARCH
+. "$GOROOT"/src/Make.$GOARCH
if [ -z "$O" ]; then
echo 'missing $O - maybe no Make.$GOARCH?' 1>&2
exit 2
diff --git a/src/cmd/goyacc/Makefile b/src/cmd/goyacc/Makefile
index 80365b86e..77ac918bc 100644
--- a/src/cmd/goyacc/Makefile
+++ b/src/cmd/goyacc/Makefile
@@ -2,13 +2,13 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=goyacc
GOFILES=\
goyacc.go\
-include $(GOROOT)/src/Make.cmd
+include ../../Make.cmd
units: goyacc units.y
./goyacc units.y
diff --git a/src/cmd/hgpatch/Makefile b/src/cmd/hgpatch/Makefile
index 85f0722c8..f7d64bc12 100644
--- a/src/cmd/hgpatch/Makefile
+++ b/src/cmd/hgpatch/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=hgpatch
GOFILES=\
main.go\
-include $(GOROOT)/src/Make.cmd
+include ../../Make.cmd
diff --git a/src/cmd/make.bash b/src/cmd/make.bash
index db31b7b5a..8e1546b53 100755
--- a/src/cmd/make.bash
+++ b/src/cmd/make.bash
@@ -7,7 +7,7 @@ set -e
bash clean.bash
-. $GOROOT/src/Make.$GOARCH
+. "$GOROOT"/src/Make.$GOARCH
if [ -z "$O" ]; then
echo 'missing $O - maybe no Make.$GOARCH?' 1>&2
exit 1
diff --git a/src/cmd/nm/Makefile b/src/cmd/nm/Makefile
index b2134e6b5..bb1545122 100644
--- a/src/cmd/nm/Makefile
+++ b/src/cmd/nm/Makefile
@@ -13,12 +13,12 @@ OFILES=\
nm.$O\
$(TARG): $(OFILES)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) -lmach -lbio -l9
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) -lmach -lbio -l9
clean:
rm -f *.$O $(TARG)
install: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
$(OFILES): $(HFILES)
diff --git a/src/cmd/prof/Makefile b/src/cmd/prof/Makefile
index f9012577e..b29ba4595 100644
--- a/src/cmd/prof/Makefile
+++ b/src/cmd/prof/Makefile
@@ -17,7 +17,7 @@ OFILES=\
# fns.h\
$(TARG): $(OFILES)
- $(LD) -o $(TARG) -L$(GOROOT)/lib $(OFILES) -lmach -lbio -l9
+ $(LD) -o $(TARG) -L"$(GOROOT)"/lib $(OFILES) -lmach -lbio -l9
clean:
rm -f *.$O $(TARG)
@@ -31,6 +31,6 @@ install-darwin: $(TARG)
@true
install-default: $(TARG)
- cp $(TARG) $(GOBIN)/$(TARG)
+ cp $(TARG) "$(GOBIN)"/$(TARG)
$(OFILES): $(HFILES)
diff --git a/src/lib9/Makefile b/src/lib9/Makefile
index 12b72f01e..6f0739d2c 100644
--- a/src/lib9/Makefile
+++ b/src/lib9/Makefile
@@ -92,11 +92,11 @@ OFILES=\
$(UTFOFILES)\
HFILES=\
- $(GOROOT)/include/u.h\
- $(GOROOT)/include/libc.h\
+ "$(GOROOT)"/include/u.h\
+ "$(GOROOT)"/include/libc.h\
install: $(LIB)
- cp $(LIB) $(GOROOT)/lib
+ cp $(LIB) "$(GOROOT)/lib"
$(LIB): $(OFILES)
ar rsc $(LIB) $(OFILES)
@@ -111,7 +111,7 @@ clean:
rm -f *.$O *.6 6.out $(LIB)
nuke: clean
- rm -f $(GOROOT)/lib/$(LIB)
+ rm -f "$(GOROOT)"/lib/$(LIB)
#XLIB=$PLAN9/lib/$LIB
diff --git a/src/libbio/Makefile b/src/libbio/Makefile
index bcd78347f..32fdedd91 100644
--- a/src/libbio/Makefile
+++ b/src/libbio/Makefile
@@ -45,10 +45,10 @@ OFILES=\
bwrite.$O\
HFILES=\
- $(GOROOT)/include/bio.h\
+ ../../include/bio.h
install: $(LIB)
- cp $(LIB) $(GOROOT)/lib
+ cp $(LIB) ../../lib
$(LIB): $(OFILES)
ar rsc $(LIB) $(OFILES)
@@ -62,4 +62,4 @@ clean:
rm -f $(OFILES) *.6 6.out $(LIB)
nuke: clean
- rm -f $(GOROOT)/lib/$(LIB)
+ rm -f ../../lib/$(LIB)
diff --git a/src/libcgo/Makefile b/src/libcgo/Makefile
index 254e4622d..b5ac6e33f 100644
--- a/src/libcgo/Makefile
+++ b/src/libcgo/Makefile
@@ -2,9 +2,14 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
+# ugly hack to deal with whitespaces in $GOROOT
+nullstring :=
+space := $(nullstring) # a space at the end
+QUOTED_GOROOT=$(subst $(space),\ ,$(GOROOT))
+
all: libcgo.so
-install: $(GOROOT)/pkg/$(GOOS)_$(GOARCH)/libcgo.so
+install: $(QUOTED_GOROOT)/pkg/$(GOOS)_$(GOARCH)/libcgo.so
OFILES=\
$(GOOS)_$(GOARCH).o\
@@ -27,8 +32,8 @@ LDFLAGS_freebsd=-pthread -shared -lm
libcgo.so: $(OFILES)
gcc $(CFLAGS_$(GOARCH)) -o libcgo.so $(OFILES) $(LDFLAGS_$(GOOS))
-$(GOROOT)/pkg/$(GOOS)_$(GOARCH)/libcgo.so: libcgo.so
- cp libcgo.so $@
+$(QUOTED_GOROOT)/pkg/$(GOOS)_$(GOARCH)/libcgo.so: libcgo.so
+ cp libcgo.so $(QUOTED_GOROOT)/pkg/$(GOOS)_$(GOARCH)
clean:
rm -f *.o *.so
diff --git a/src/libmach/Makefile b/src/libmach/Makefile
index cde2cdf66..f1be126d2 100644
--- a/src/libmach/Makefile
+++ b/src/libmach/Makefile
@@ -49,10 +49,10 @@ OFILES=\
8obj.$O\
$(shell uname | tr A-Z a-z).$O\
-HFILES=$(GOROOT)/include/mach.h elf.h macho.h obj.h
+HFILES=../../include/mach.h elf.h macho.h obj.h
install: $(LIB)
- cp $(LIB) $(GOROOT)/lib
+ cp $(LIB) ../../lib
$(LIB): $(OFILES)
ar rsc $(LIB) $(OFILES)
@@ -63,5 +63,5 @@ clean:
rm -f *.$O $(LIB)
nuke: clean
- rm -f $(GOROOT)/lib/$(LIB)
+ rm -f "$(GOROOT)"/lib/$(LIB)
diff --git a/src/make-arm.bash b/src/make-arm.bash
index 759454156..b007418db 100755
--- a/src/make-arm.bash
+++ b/src/make-arm.bash
@@ -7,7 +7,7 @@ set -e
GOBIN="${GOBIN:-$HOME/bin}"
export MAKEFLAGS=-j4
-if ! test -f $GOROOT/include/u.h
+if ! test -f "$GOROOT"/include/u.h
then
echo '$GOROOT is not set correctly or not exported' 1>&2
exit 1
diff --git a/src/make.bash b/src/make.bash
index 249a9cee2..c9a812b76 100755
--- a/src/make.bash
+++ b/src/make.bash
@@ -7,13 +7,13 @@ set -e
GOBIN="${GOBIN:-$HOME/bin}"
export MAKEFLAGS=-j4
-if ! test -f $GOROOT/include/u.h
+if ! test -f "$GOROOT"/include/u.h
then
echo '$GOROOT is not set correctly or not exported' 1>&2
exit 1
fi
-if ! test -d $GOBIN
+if ! test -d "$GOBIN"
then
echo '$GOBIN is not a directory or does not exist' 1>&2
echo 'create it or set $GOBIN differently' 1>&2
@@ -36,18 +36,18 @@ darwin | linux | nacl | freebsd)
exit 1
esac
-rm -f $GOBIN/quietgcc
+rm -f "$GOBIN"/quietgcc
CC=${CC:-gcc}
-sed -e "s|@CC@|$CC|" < quietgcc.bash > $GOBIN/quietgcc
-chmod +x $GOBIN/quietgcc
+sed -e "s|@CC@|$CC|" < quietgcc.bash > "$GOBIN"/quietgcc
+chmod +x "$GOBIN"/quietgcc
-rm -f $GOBIN/gomake
+rm -f "$GOBIN"/gomake
MAKE=make
if ! make --version 2>/dev/null | grep 'GNU Make' >/dev/null; then
MAKE=gmake
fi
-(echo '#!/bin/sh'; echo 'exec '$MAKE' "$@"') >$GOBIN/gomake
-chmod +x $GOBIN/gomake
+(echo '#!/bin/sh'; echo 'exec '$MAKE' "$@"') >"$GOBIN"/gomake
+chmod +x "$GOBIN"/gomake
if ! (cd lib9 && which quietgcc) >/dev/null 2>&1; then
echo "installed quietgcc as $GOBIN/quietgcc but 'which quietgcc' fails" 1>&2
diff --git a/src/pkg/Makefile b/src/pkg/Makefile
index 32a261b3f..c9e070e62 100644
--- a/src/pkg/Makefile
+++ b/src/pkg/Makefile
@@ -139,7 +139,7 @@ install: install.dirs
test: test.dirs
nuke: nuke.dirs
- rm -rf $(GOROOT)/pkg/*
+ rm -rf "$(GOROOT)"/pkg/*
deps:
./deps.bash
diff --git a/src/pkg/archive/tar/Makefile b/src/pkg/archive/tar/Makefile
index debe06284..6a29de8f7 100644
--- a/src/pkg/archive/tar/Makefile
+++ b/src/pkg/archive/tar/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=archive/tar
GOFILES=\
@@ -10,4 +10,4 @@ GOFILES=\
reader.go\
writer.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/asn1/Makefile b/src/pkg/asn1/Makefile
index 32848743a..40b76b849 100644
--- a/src/pkg/asn1/Makefile
+++ b/src/pkg/asn1/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=asn1
GOFILES=\
@@ -10,4 +10,4 @@ GOFILES=\
common.go\
marshal.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/big/Makefile b/src/pkg/big/Makefile
index 595a60797..520c2b852 100644
--- a/src/pkg/big/Makefile
+++ b/src/pkg/big/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=big
GOFILES=\
@@ -13,4 +13,4 @@ GOFILES=\
OFILES=\
arith_$(GOARCH).$O\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/bignum/Makefile b/src/pkg/bignum/Makefile
index bcb8752aa..c3dd59531 100644
--- a/src/pkg/bignum/Makefile
+++ b/src/pkg/bignum/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=bignum
GOFILES=\
@@ -11,4 +11,4 @@ GOFILES=\
integer.go\
rational.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/bufio/Makefile b/src/pkg/bufio/Makefile
index af41e888b..1f5fc349b 100644
--- a/src/pkg/bufio/Makefile
+++ b/src/pkg/bufio/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=bufio
GOFILES=\
bufio.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/bytes/Makefile b/src/pkg/bytes/Makefile
index 6d7d113e6..f9e18ac6b 100644
--- a/src/pkg/bytes/Makefile
+++ b/src/pkg/bytes/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=bytes
GOFILES=\
buffer.go\
bytes.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/compress/flate/Makefile b/src/pkg/compress/flate/Makefile
index c71610cf9..6f9ee74d4 100644
--- a/src/pkg/compress/flate/Makefile
+++ b/src/pkg/compress/flate/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=compress/flate
GOFILES=\
@@ -14,4 +14,4 @@ GOFILES=\
token.go\
util.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/compress/gzip/Makefile b/src/pkg/compress/gzip/Makefile
index 717a2d608..ca26333f3 100644
--- a/src/pkg/compress/gzip/Makefile
+++ b/src/pkg/compress/gzip/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=compress/gzip
GOFILES=\
gunzip.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/compress/zlib/Makefile b/src/pkg/compress/zlib/Makefile
index 94175a147..4cfda4f1b 100644
--- a/src/pkg/compress/zlib/Makefile
+++ b/src/pkg/compress/zlib/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=compress/zlib
GOFILES=\
reader.go\
writer.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/container/heap/Makefile b/src/pkg/container/heap/Makefile
index 2625d19ca..244ebae06 100644
--- a/src/pkg/container/heap/Makefile
+++ b/src/pkg/container/heap/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=container/heap
GOFILES=\
heap.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/container/list/Makefile b/src/pkg/container/list/Makefile
index 3ed4d1f6c..2d5b35715 100644
--- a/src/pkg/container/list/Makefile
+++ b/src/pkg/container/list/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=container/list
GOFILES=\
list.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/container/ring/Makefile b/src/pkg/container/ring/Makefile
index 70046cb54..4755bab07 100644
--- a/src/pkg/container/ring/Makefile
+++ b/src/pkg/container/ring/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=container/ring
GOFILES=\
ring.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/container/vector/Makefile b/src/pkg/container/vector/Makefile
index 1237f2c3b..8ccc34789 100644
--- a/src/pkg/container/vector/Makefile
+++ b/src/pkg/container/vector/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=container/vector
GOFILES=\
@@ -10,4 +10,4 @@ GOFILES=\
stringvector.go\
vector.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/crypto/aes/Makefile b/src/pkg/crypto/aes/Makefile
index f7352cb91..07d759b4b 100644
--- a/src/pkg/crypto/aes/Makefile
+++ b/src/pkg/crypto/aes/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=crypto/aes
GOFILES=\
@@ -10,4 +10,4 @@ GOFILES=\
cipher.go\
const.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/crypto/block/Makefile b/src/pkg/crypto/block/Makefile
index a277d0dd9..25c3483ae 100644
--- a/src/pkg/crypto/block/Makefile
+++ b/src/pkg/crypto/block/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=crypto/block
GOFILES=\
@@ -16,4 +16,4 @@ GOFILES=\
ofb.go\
xor.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/crypto/hmac/Makefile b/src/pkg/crypto/hmac/Makefile
index 9da53a474..d1a6bfc2b 100644
--- a/src/pkg/crypto/hmac/Makefile
+++ b/src/pkg/crypto/hmac/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=crypto/hmac
GOFILES=\
hmac.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/crypto/md5/Makefile b/src/pkg/crypto/md5/Makefile
index 53fcf874a..7f37f6a33 100644
--- a/src/pkg/crypto/md5/Makefile
+++ b/src/pkg/crypto/md5/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=crypto/md5
GOFILES=\
md5.go\
md5block.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/crypto/rc4/Makefile b/src/pkg/crypto/rc4/Makefile
index 5c7e67fa0..7827b0817 100644
--- a/src/pkg/crypto/rc4/Makefile
+++ b/src/pkg/crypto/rc4/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=crypto/rc4
GOFILES=\
rc4.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/crypto/rsa/Makefile b/src/pkg/crypto/rsa/Makefile
index ef0bd7c49..e4d81bc52 100644
--- a/src/pkg/crypto/rsa/Makefile
+++ b/src/pkg/crypto/rsa/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=crypto/rsa
GOFILES=\
rsa.go\
pkcs1v15.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/crypto/sha1/Makefile b/src/pkg/crypto/sha1/Makefile
index 940e2ff15..f3422dd84 100644
--- a/src/pkg/crypto/sha1/Makefile
+++ b/src/pkg/crypto/sha1/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=crypto/sha1
GOFILES=\
sha1.go\
sha1block.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/crypto/subtle/Makefile b/src/pkg/crypto/subtle/Makefile
index 4d245c683..fa5f7ef42 100644
--- a/src/pkg/crypto/subtle/Makefile
+++ b/src/pkg/crypto/subtle/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=crypto/subtle
GOFILES=\
constant_time.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/crypto/tls/Makefile b/src/pkg/crypto/tls/Makefile
index 0c2d33998..55c9d87cf 100644
--- a/src/pkg/crypto/tls/Makefile
+++ b/src/pkg/crypto/tls/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=crypto/tls
GOFILES=\
@@ -18,4 +18,4 @@ GOFILES=\
ca_set.go\
tls.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/crypto/x509/Makefile b/src/pkg/crypto/x509/Makefile
index 98bf44acc..b2ecfdc01 100644
--- a/src/pkg/crypto/x509/Makefile
+++ b/src/pkg/crypto/x509/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=crypto/x509
GOFILES=\
x509.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/debug/dwarf/Makefile b/src/pkg/debug/dwarf/Makefile
index 8825c597e..a626513c7 100644
--- a/src/pkg/debug/dwarf/Makefile
+++ b/src/pkg/debug/dwarf/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=debug/dwarf
GOFILES=\
@@ -13,4 +13,4 @@ GOFILES=\
type.go\
unit.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/debug/elf/Makefile b/src/pkg/debug/elf/Makefile
index ee3ca46d6..931f9d24d 100644
--- a/src/pkg/debug/elf/Makefile
+++ b/src/pkg/debug/elf/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=debug/elf
GOFILES=\
elf.go\
file.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/debug/gosym/Makefile b/src/pkg/debug/gosym/Makefile
index 715288250..ac16b4cee 100644
--- a/src/pkg/debug/gosym/Makefile
+++ b/src/pkg/debug/gosym/Makefile
@@ -2,12 +2,12 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=debug/gosym
GOFILES=\
pclntab.go\
symtab.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/debug/macho/Makefile b/src/pkg/debug/macho/Makefile
index 1a88c7377..d34aacf54 100644
--- a/src/pkg/debug/macho/Makefile
+++ b/src/pkg/debug/macho/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=debug/macho
GOFILES=\
macho.go\
file.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/debug/proc/Makefile b/src/pkg/debug/proc/Makefile
index 1c6dc9089..5444ec0db 100644
--- a/src/pkg/debug/proc/Makefile
+++ b/src/pkg/debug/proc/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=debug/proc
GOFILES=\
@@ -10,4 +10,4 @@ GOFILES=\
proc_$(GOOS).go\
regs_$(GOOS)_$(GOARCH).go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/ebnf/Makefile b/src/pkg/ebnf/Makefile
index 8b3b0774c..4a75c7432 100644
--- a/src/pkg/ebnf/Makefile
+++ b/src/pkg/ebnf/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=ebnf
GOFILES=\
ebnf.go\
parser.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/encoding/ascii85/Makefile b/src/pkg/encoding/ascii85/Makefile
index 5a7bc176c..7ec14bd1a 100644
--- a/src/pkg/encoding/ascii85/Makefile
+++ b/src/pkg/encoding/ascii85/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=encoding/ascii85
GOFILES=\
ascii85.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/encoding/base64/Makefile b/src/pkg/encoding/base64/Makefile
index 1afb0ebb8..8503b1663 100644
--- a/src/pkg/encoding/base64/Makefile
+++ b/src/pkg/encoding/base64/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=encoding/base64
GOFILES=\
base64.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/encoding/binary/Makefile b/src/pkg/encoding/binary/Makefile
index 69fd57c67..23d4d6d43 100644
--- a/src/pkg/encoding/binary/Makefile
+++ b/src/pkg/encoding/binary/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=encoding/binary
GOFILES=\
binary.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/encoding/git85/Makefile b/src/pkg/encoding/git85/Makefile
index 10587743a..09dd96f32 100644
--- a/src/pkg/encoding/git85/Makefile
+++ b/src/pkg/encoding/git85/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=encoding/git85
GOFILES=\
git.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/encoding/hex/Makefile b/src/pkg/encoding/hex/Makefile
index bcfed2d45..d6849d9a5 100644
--- a/src/pkg/encoding/hex/Makefile
+++ b/src/pkg/encoding/hex/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=encoding/hex
GOFILES=\
hex.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/encoding/pem/Makefile b/src/pkg/encoding/pem/Makefile
index 8bdfc747b..79490a57d 100644
--- a/src/pkg/encoding/pem/Makefile
+++ b/src/pkg/encoding/pem/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=encoding/pem
GOFILES=\
pem.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/exec/Makefile b/src/pkg/exec/Makefile
index 9927eb3e7..9d88b8d8a 100644
--- a/src/pkg/exec/Makefile
+++ b/src/pkg/exec/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=exec
GOFILES=\
exec.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/exp/datafmt/Makefile b/src/pkg/exp/datafmt/Makefile
index 57836a1b3..40543b195 100644
--- a/src/pkg/exp/datafmt/Makefile
+++ b/src/pkg/exp/datafmt/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=exp/datafmt
GOFILES=\
datafmt.go\
parser.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/exp/draw/Makefile b/src/pkg/exp/draw/Makefile
index 44238c5cf..7ab574482 100644
--- a/src/pkg/exp/draw/Makefile
+++ b/src/pkg/exp/draw/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=exp/draw
GOFILES=\
@@ -11,4 +11,4 @@ GOFILES=\
draw.go\
event.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/exp/eval/Makefile b/src/pkg/exp/eval/Makefile
index 65bedf7ba..46445876b 100644
--- a/src/pkg/exp/eval/Makefile
+++ b/src/pkg/exp/eval/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=exp/eval
GOFILES=\
@@ -20,4 +20,4 @@ GOFILES=\
value.go\
world.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/exp/eval/test.bash b/src/pkg/exp/eval/test.bash
index dabaa280b..1755689ea 100755
--- a/src/pkg/exp/eval/test.bash
+++ b/src/pkg/exp/eval/test.bash
@@ -12,13 +12,13 @@ set -e
make
6g main.go && 6l main.6
(
-for i in $(egrep -l '// \$G (\$D/)?\$F\.go \&\& \$L \$F\.\$A && \./\$A\.out' $GOROOT/test/*.go $GOROOT/test/*/*.go)
+for i in $(egrep -l '// \$G (\$D/)?\$F\.go \&\& \$L \$F\.\$A && \./\$A\.out' "$GOROOT"/test/*.go "$GOROOT"/test/*/*.go)
do
if grep '^import' $i >/dev/null 2>&1
then
true
else
- if $GOROOT/usr/austin/eval/6.out -f $i >/tmp/out 2>&1 && ! test -s /tmp/out
+ if "$GOROOT"/usr/austin/eval/6.out -f $i >/tmp/out 2>&1 && ! test -s /tmp/out
then
echo PASS $i
else
diff --git a/src/pkg/exp/exception/Makefile b/src/pkg/exp/exception/Makefile
index 5c8d1e9df..19c86630f 100644
--- a/src/pkg/exp/exception/Makefile
+++ b/src/pkg/exp/exception/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=exp/exception
GOFILES=\
exception.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/exp/iterable/Makefile b/src/pkg/exp/iterable/Makefile
index f448089ce..9adf714da 100644
--- a/src/pkg/exp/iterable/Makefile
+++ b/src/pkg/exp/iterable/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=exp/iterable
GOFILES=\
array.go\
iterable.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/exp/nacl/av/Makefile b/src/pkg/exp/nacl/av/Makefile
index 743658b25..d966078ec 100644
--- a/src/pkg/exp/nacl/av/Makefile
+++ b/src/pkg/exp/nacl/av/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../../Make.$(GOARCH)
TARG=exp/nacl/av
GOFILES=\
@@ -10,4 +10,4 @@ GOFILES=\
event.go\
image.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../../Make.pkg
diff --git a/src/pkg/exp/nacl/srpc/Makefile b/src/pkg/exp/nacl/srpc/Makefile
index d30ae7d13..7dda292f5 100644
--- a/src/pkg/exp/nacl/srpc/Makefile
+++ b/src/pkg/exp/nacl/srpc/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../../Make.$(GOARCH)
TARG=exp/nacl/srpc
GOFILES=\
@@ -10,4 +10,4 @@ GOFILES=\
msg.go\
server.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../../Make.pkg
diff --git a/src/pkg/exp/ogle/Makefile b/src/pkg/exp/ogle/Makefile
index 31bb9df5c..141f9759d 100644
--- a/src/pkg/exp/ogle/Makefile
+++ b/src/pkg/exp/ogle/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=exp/ogle
GOFILES=\
@@ -20,7 +20,7 @@ GOFILES=\
CLEANFILES+=ogle
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
main.$O: main.go package
$(GC) -I_obj $<
diff --git a/src/pkg/expvar/Makefile b/src/pkg/expvar/Makefile
index 49e8de6d1..544891739 100644
--- a/src/pkg/expvar/Makefile
+++ b/src/pkg/expvar/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=expvar
GOFILES=\
expvar.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/flag/Makefile b/src/pkg/flag/Makefile
index faa95185c..3ffbea83c 100644
--- a/src/pkg/flag/Makefile
+++ b/src/pkg/flag/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=flag
GOFILES=\
flag.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/fmt/Makefile b/src/pkg/fmt/Makefile
index 9273093e8..757af41bb 100644
--- a/src/pkg/fmt/Makefile
+++ b/src/pkg/fmt/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=fmt
GOFILES=\
format.go\
print.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/go/ast/Makefile b/src/pkg/go/ast/Makefile
index 1cafa633b..752e45350 100644
--- a/src/pkg/go/ast/Makefile
+++ b/src/pkg/go/ast/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=go/ast
GOFILES=\
@@ -11,4 +11,4 @@ GOFILES=\
filter.go\
walk.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/go/doc/Makefile b/src/pkg/go/doc/Makefile
index 60ce26483..1558ac30a 100644
--- a/src/pkg/go/doc/Makefile
+++ b/src/pkg/go/doc/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=go/doc
GOFILES=\
comment.go\
doc.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/go/parser/Makefile b/src/pkg/go/parser/Makefile
index a8f14ff63..d9b52a7d9 100644
--- a/src/pkg/go/parser/Makefile
+++ b/src/pkg/go/parser/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=go/parser
GOFILES=\
interface.go\
parser.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/go/printer/Makefile b/src/pkg/go/printer/Makefile
index 5737a0115..a0fe22e42 100644
--- a/src/pkg/go/printer/Makefile
+++ b/src/pkg/go/printer/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=go/printer
GOFILES=\
printer.go\
nodes.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/go/scanner/Makefile b/src/pkg/go/scanner/Makefile
index 5e3f38d00..70d21a972 100644
--- a/src/pkg/go/scanner/Makefile
+++ b/src/pkg/go/scanner/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=go/scanner
GOFILES=\
errors.go\
scanner.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/go/token/Makefile b/src/pkg/go/token/Makefile
index 259fb29f6..629196c5d 100644
--- a/src/pkg/go/token/Makefile
+++ b/src/pkg/go/token/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=go/token
GOFILES=\
token.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/gob/Makefile b/src/pkg/gob/Makefile
index 1a77252f7..5b175b347 100644
--- a/src/pkg/gob/Makefile
+++ b/src/pkg/gob/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=gob
GOFILES=\
@@ -12,4 +12,4 @@ GOFILES=\
encoder.go\
type.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/hash/Makefile b/src/pkg/hash/Makefile
index 5bf470fd1..aaa641f7c 100644
--- a/src/pkg/hash/Makefile
+++ b/src/pkg/hash/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=hash
GOFILES=\
hash.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/hash/adler32/Makefile b/src/pkg/hash/adler32/Makefile
index 8e5a3389b..6f6d66fd0 100644
--- a/src/pkg/hash/adler32/Makefile
+++ b/src/pkg/hash/adler32/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=hash/adler32
GOFILES=\
adler32.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/hash/crc32/Makefile b/src/pkg/hash/crc32/Makefile
index dbfcda10c..071d89823 100644
--- a/src/pkg/hash/crc32/Makefile
+++ b/src/pkg/hash/crc32/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=hash/crc32
GOFILES=\
crc32.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/http/Makefile b/src/pkg/http/Makefile
index 974067882..93852fe71 100644
--- a/src/pkg/http/Makefile
+++ b/src/pkg/http/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=http
GOFILES=\
@@ -13,4 +13,4 @@ GOFILES=\
status.go\
url.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/image/Makefile b/src/pkg/image/Makefile
index 318070826..f1ba374db 100644
--- a/src/pkg/image/Makefile
+++ b/src/pkg/image/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=image
GOFILES=\
color.go\
image.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/image/png/Makefile b/src/pkg/image/png/Makefile
index 5c534af24..3ba0f44d3 100644
--- a/src/pkg/image/png/Makefile
+++ b/src/pkg/image/png/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=image/png
GOFILES=\
reader.go\
writer.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/io/Makefile b/src/pkg/io/Makefile
index bf124f454..cbe691644 100644
--- a/src/pkg/io/Makefile
+++ b/src/pkg/io/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=io
GOFILES=\
@@ -10,4 +10,4 @@ GOFILES=\
pipe.go\
utils.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/json/Makefile b/src/pkg/json/Makefile
index 061ab88cf..1adeff721 100644
--- a/src/pkg/json/Makefile
+++ b/src/pkg/json/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=json
GOFILES=\
@@ -10,4 +10,4 @@ GOFILES=\
parse.go\
struct.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/log/Makefile b/src/pkg/log/Makefile
index b569c9e9f..402be03bc 100644
--- a/src/pkg/log/Makefile
+++ b/src/pkg/log/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=log
GOFILES=\
log.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/malloc/Makefile b/src/pkg/malloc/Makefile
index 8a108c802..d7c39c0cf 100644
--- a/src/pkg/malloc/Makefile
+++ b/src/pkg/malloc/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=malloc
GOFILES=\
malloc.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/math/Makefile b/src/pkg/math/Makefile
index 74072503c..f30f38faf 100644
--- a/src/pkg/math/Makefile
+++ b/src/pkg/math/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=math
@@ -40,4 +40,4 @@ GOFILES=\
$(filter-out $(NOGOFILES),$(ALLGOFILES))\
$(subst .go,_decl.go,$(NOGOFILES))\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/net/Makefile b/src/pkg/net/Makefile
index a11b0009a..bb2cb3978 100644
--- a/src/pkg/net/Makefile
+++ b/src/pkg/net/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=net
GOFILES=\
@@ -21,4 +21,4 @@ GOFILES=\
udpsock.go\
unixsock.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/once/Makefile b/src/pkg/once/Makefile
index f83250b54..e87fbf810 100644
--- a/src/pkg/once/Makefile
+++ b/src/pkg/once/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=once
GOFILES=\
once.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/os/Makefile b/src/pkg/os/Makefile
index 2b30483e9..fa92c76e3 100644
--- a/src/pkg/os/Makefile
+++ b/src/pkg/os/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=os
GOFILES=\
@@ -19,4 +19,4 @@ GOFILES=\
time.go\
types.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/patch/Makefile b/src/pkg/patch/Makefile
index c32a56ed8..1666345c6 100644
--- a/src/pkg/patch/Makefile
+++ b/src/pkg/patch/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=patch
GOFILES=\
@@ -11,4 +11,4 @@ GOFILES=\
patch.go\
textdiff.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/path/Makefile b/src/pkg/path/Makefile
index d3a40bfcf..199b68008 100644
--- a/src/pkg/path/Makefile
+++ b/src/pkg/path/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=path
GOFILES=\
path.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/rand/Makefile b/src/pkg/rand/Makefile
index fc07d3d59..068b6fdee 100644
--- a/src/pkg/rand/Makefile
+++ b/src/pkg/rand/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=rand
GOFILES=\
@@ -11,4 +11,4 @@ GOFILES=\
rand.go\
rng.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/reflect/Makefile b/src/pkg/reflect/Makefile
index 9e9ea3ad6..b72d3873f 100644
--- a/src/pkg/reflect/Makefile
+++ b/src/pkg/reflect/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=reflect
GOFILES=\
@@ -10,4 +10,4 @@ GOFILES=\
type.go\
value.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/regexp/Makefile b/src/pkg/regexp/Makefile
index 84d1a5d51..9f91c8e7a 100644
--- a/src/pkg/regexp/Makefile
+++ b/src/pkg/regexp/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=regexp
GOFILES=\
regexp.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/rpc/Makefile b/src/pkg/rpc/Makefile
index 9ea178238..4757b3aae 100644
--- a/src/pkg/rpc/Makefile
+++ b/src/pkg/rpc/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=rpc
GOFILES=\
@@ -10,4 +10,4 @@ GOFILES=\
debug.go\
server.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/runtime/Makefile b/src/pkg/runtime/Makefile
index ea6192ae2..80bfa5103 100644
--- a/src/pkg/runtime/Makefile
+++ b/src/pkg/runtime/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=runtime
@@ -80,7 +80,7 @@ HFILES=\
$(GOOS)/os.h\
$(GOOS)/$(GOARCH)/defs.h\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
clean: clean-local
diff --git a/src/pkg/sort/Makefile b/src/pkg/sort/Makefile
index a10e407d6..57c9f8f47 100644
--- a/src/pkg/sort/Makefile
+++ b/src/pkg/sort/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=sort
GOFILES=\
sort.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/strconv/Makefile b/src/pkg/strconv/Makefile
index af5c5e110..8b20273b8 100644
--- a/src/pkg/strconv/Makefile
+++ b/src/pkg/strconv/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=strconv
GOFILES=\
@@ -13,4 +13,4 @@ GOFILES=\
itoa.go\
quote.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/strings/Makefile b/src/pkg/strings/Makefile
index 3f0e429f6..9bae470e9 100644
--- a/src/pkg/strings/Makefile
+++ b/src/pkg/strings/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=strings
GOFILES=\
reader.go\
strings.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/sync/Makefile b/src/pkg/sync/Makefile
index 0c18f8bcb..2517d01e6 100644
--- a/src/pkg/sync/Makefile
+++ b/src/pkg/sync/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=sync
GOFILES=\
@@ -11,4 +11,4 @@ GOFILES=\
OFILES=\
asm_$(GOARCH).$O\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/syscall/Makefile b/src/pkg/syscall/Makefile
index 969cd0def..5673da9d2 100644
--- a/src/pkg/syscall/Makefile
+++ b/src/pkg/syscall/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=syscall
GOFILES=\
@@ -19,4 +19,4 @@ GOFILES=\
OFILES=\
asm_$(GOOS)_$(GOARCH).$O\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/tabwriter/Makefile b/src/pkg/tabwriter/Makefile
index 28cb50580..5beb88f0f 100644
--- a/src/pkg/tabwriter/Makefile
+++ b/src/pkg/tabwriter/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=tabwriter
GOFILES=\
tabwriter.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/template/Makefile b/src/pkg/template/Makefile
index 832f5046c..c9c79f799 100644
--- a/src/pkg/template/Makefile
+++ b/src/pkg/template/Makefile
@@ -2,11 +2,11 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=template
GOFILES=\
format.go\
template.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/testing/Makefile b/src/pkg/testing/Makefile
index ffbd11111..64485489e 100644
--- a/src/pkg/testing/Makefile
+++ b/src/pkg/testing/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=testing
GOFILES=\
@@ -10,4 +10,4 @@ GOFILES=\
regexp.go\
testing.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/testing/iotest/Makefile b/src/pkg/testing/iotest/Makefile
index a37a9d622..2b9abd4b3 100644
--- a/src/pkg/testing/iotest/Makefile
+++ b/src/pkg/testing/iotest/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=testing/iotest
GOFILES=\
@@ -10,4 +10,4 @@ GOFILES=\
reader.go\
writer.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/testing/quick/Makefile b/src/pkg/testing/quick/Makefile
index 7e3a354da..0e97f2af2 100644
--- a/src/pkg/testing/quick/Makefile
+++ b/src/pkg/testing/quick/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=testing/quick
GOFILES=\
quick.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/testing/script/Makefile b/src/pkg/testing/script/Makefile
index 1b4882d56..2e13aeb2f 100644
--- a/src/pkg/testing/script/Makefile
+++ b/src/pkg/testing/script/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../../Make.$(GOARCH)
TARG=testing/script
GOFILES=\
script.go\
-include $(GOROOT)/src/Make.pkg
+include ../../../Make.pkg
diff --git a/src/pkg/time/Makefile b/src/pkg/time/Makefile
index fef9753c8..ac4415069 100644
--- a/src/pkg/time/Makefile
+++ b/src/pkg/time/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=time
GOFILES=\
@@ -11,4 +11,4 @@ GOFILES=\
time.go\
zoneinfo.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/unicode/Makefile b/src/pkg/unicode/Makefile
index e309902ea..489467f0e 100644
--- a/src/pkg/unicode/Makefile
+++ b/src/pkg/unicode/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=unicode
GOFILES=\
@@ -10,7 +10,7 @@ GOFILES=\
letter.go\
tables.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
maketables: maketables.go
$(GC) maketables.go
diff --git a/src/pkg/utf8/Makefile b/src/pkg/utf8/Makefile
index b33adaa8a..a013913c3 100644
--- a/src/pkg/utf8/Makefile
+++ b/src/pkg/utf8/Makefile
@@ -2,10 +2,10 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=utf8
GOFILES=\
utf8.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/pkg/xml/Makefile b/src/pkg/xml/Makefile
index 3c005c605..38e32e7a4 100644
--- a/src/pkg/xml/Makefile
+++ b/src/pkg/xml/Makefile
@@ -2,7 +2,7 @@
# Use of this source code is governed by a BSD-style
# license that can be found in the LICENSE file.
-include $(GOROOT)/src/Make.$(GOARCH)
+include ../../Make.$(GOARCH)
TARG=xml
@@ -10,4 +10,4 @@ GOFILES=\
read.go\
xml.go\
-include $(GOROOT)/src/Make.pkg
+include ../../Make.pkg
diff --git a/src/sudo.bash b/src/sudo.bash
index 68f990591..d87fb231d 100755
--- a/src/sudo.bash
+++ b/src/sudo.bash
@@ -12,7 +12,7 @@ esac
for i in prof cov
do
- sudo cp $GOROOT/src/cmd/$i/6$i /usr/local/bin/6$i
+ sudo cp "$GOROOT"/src/cmd/$i/6$i /usr/local/bin/6$i
sudo chgrp procmod /usr/local/bin/6$i
sudo chmod g+s /usr/local/bin/6$i
done
diff --git a/test/bench/timing.sh b/test/bench/timing.sh
index 7c3eeab8e..1bb14d3ba 100755
--- a/test/bench/timing.sh
+++ b/test/bench/timing.sh
@@ -4,7 +4,7 @@
# license that can be found in the LICENSE file.
set -e
-. $GOROOT/src/Make.$GOARCH
+. "$GOROOT"/src/Make.$GOARCH
PATH=.:$PATH
mode=run