1
我的測試程序test.go
:圍棋:在你好錯誤進口世界
package main
import "fmt"
func main() {
fmt.Printf("Hello\n")
}
運行此go run test.go
完成與錯誤:
# io
pack: cannot open $WORK/io/_obj/_go_.6
# strconv
pack: cannot open $WORK/strconv/_obj/_go_.6
環境:
go version devel +715674f61ae8 Tue Jan 29 13:34:18 2013 -0800 linux/amd64
GOARCH="amd64"
GOBIN=""
GOCHAR="6"
GOEXE=""
GOGCCFLAGS="-g -O2 -fPIC -m64 -pthread"
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="/usr/local/google/home/igord/incub/web"
GOROOT="/opt/go"
GOTOOLDIR="/opt/go/pkg/tool/linux_amd64"
CGO_ENABLED="1"
但我下載了這個版本(精選)RELEASE 1.0.3在旅途中!
什麼的輸出'去env'? – Staven 2013-02-12 19:12:13
你安裝了轉到一個不尋常的位置?你的$ GOROOT和$ GOPATH是什麼?請參閱http://golang.org/doc/install#install – 2013-02-12 19:13:50
'go env'的輸出是什麼? 'go run -work test.go'的輸出是什麼? – peterSO 2013-02-12 19:16:07