1
0
mirror of https://github.com/golang/go synced 2024-11-24 23:57:57 -07:00

go/build: remove 'go/build' from error messages

This leads to really confusing messages in goinstall.

R=golang-dev, r
CC=golang-dev
https://golang.org/cl/5495074
This commit is contained in:
Andrew Gerrand 2011-12-17 13:14:18 +11:00
parent 86dcc431e9
commit 96a5780db8

View File

@ -85,8 +85,8 @@ func (t *Tree) HasPkg(pkg string) bool {
}
var (
ErrNotFound = errors.New("go/build: package could not be found locally")
ErrTreeNotFound = errors.New("go/build: no valid GOROOT or GOPATH could be found")
ErrNotFound = errors.New("package could not be found locally")
ErrTreeNotFound = errors.New("no valid GOROOT or GOPATH could be found")
)
// FindTree takes an import or filesystem path and returns the
@ -151,7 +151,7 @@ func init() {
root := runtime.GOROOT()
t, err := newTree(root)
if err != nil {
log.Printf("go/build: invalid GOROOT %q: %v", root, err)
log.Printf("invalid GOROOT %q: %v", root, err)
} else {
t.Goroot = true
Path = []*Tree{t}
@ -163,7 +163,7 @@ func init() {
}
t, err := newTree(p)
if err != nil {
log.Printf("go/build: invalid GOPATH %q: %v", p, err)
log.Printf("invalid GOPATH %q: %v", p, err)
continue
}
Path = append(Path, t)