]> Cypherpunks repositories - gostls13.git/commitdiff
goinstall: assume go binaries are in path
authorRuss Cox <rsc@golang.org>
Fri, 3 Sep 2010 19:37:45 +0000 (15:37 -0400)
committerRuss Cox <rsc@golang.org>
Fri, 3 Sep 2010 19:37:45 +0000 (15:37 -0400)
(Following new convention.)

Fixes #1063.

R=adg
CC=golang-dev
https://golang.org/cl/2115042

src/cmd/goinstall/main.go
src/cmd/goinstall/make.go

index f0bd9c5b1cef2c8905c54253754070ab97de2102..2d410cd4fcfb33e7cfd291388ad7d864907bda71 100644 (file)
@@ -29,7 +29,6 @@ func usage() {
 var (
        argv0         = os.Args[0]
        errors        = false
-       gobin         = os.Getenv("GOBIN")
        parents       = make(map[string]string)
        root          = runtime.GOROOT()
        visit         = make(map[string]status)
@@ -57,9 +56,6 @@ func main() {
                fmt.Fprintf(os.Stderr, "%s: no $GOROOT\n", argv0)
                os.Exit(1)
        }
-       if gobin == "" {
-               gobin = root + "/bin"
-       }
        root += "/src/pkg/"
 
        // special case - "unsafe" is already installed
index 769c8741595e1c491500f0401def2dd9d1f95388..4e001b49bd5dcd6e8fd7a006c8727282c6fe840a 100644 (file)
@@ -21,14 +21,14 @@ func domake(dir, pkg string, local bool) os.Error {
        if local {
                _, err := os.Stat(dir + "/Makefile")
                if err == nil {
-                       return run(dir, nil, gobin+"/gomake", "install")
+                       return run(dir, nil, "gomake", "install")
                }
        }
        makefile, err := makeMakefile(dir, pkg)
        if err != nil {
                return err
        }
-       return run(dir, makefile, gobin+"/gomake", "-f-", "install")
+       return run(dir, makefile, "gomake", "-f-", "install")
 }
 
 // makeMakefile computes the standard Makefile for the directory dir