golang revel app在升级OSX命令行工具后无法编译

时间:2014-03-10 15:49:36

标签: macos go osx-mountain-lion revel

我正在玩狂欢样本预订应用程序(http://robfig.github.io/revel/samples/booking.html),一切正常。

从Apple开发者网站升级我的OSX命令行工具后,应用程序拒绝启动:

INFO  2014/03/10 23:33:46 harness.go:165: Listening on :9000
TRACE 2014/03/10 23:34:00 harness.go:126: Rebuild
TRACE 2014/03/10 23:34:00 build.go:127: Exec: [/usr/local/bin/git describe --always --dirty]
TRACE 2014/03/10 23:34:00 build.go:77: Exec: [/usr/local/bin/go build -ldflags -X github.com/robfig/revel/samples/booking/app.APP_VERSION "git-930a54f" -tags gorp -o /Users/nrser/dev/gopath/bin/booking github.com/robfig/revel/samples/booking/app/tmp]
ERROR 2014/03/10 23:34:02 build.go:84: # github.com/robfig/revel/samples/booking/app/tmp
xcrun: Error: failed to exec real xcrun. (No such file or directory)
go install github.com/robfig/revel/samples/booking/app/tmp: build output "/Users/nrser/dev/gopath/bin/booking" already exists and is not an object file

ERROR 2014/03/10 23:34:02 build.go:247: Failed to parse build errors:
 # github.com/robfig/revel/samples/booking/app/tmp
xcrun: Error: failed to exec real xcrun. (No such file or directory)
go install github.com/robfig/revel/samples/booking/app/tmp: build output "/Users/nrser/dev/gopath/bin/booking" already exists and is not an object file

我尝试了rm /Users/nrser/dev/gopath/bin/booking,但在尝试revel run github.com/robfig/revel/samples/booking

INFO  2014/03/10 23:38:13 harness.go:165: Listening on :9000
TRACE 2014/03/10 23:38:16 harness.go:126: Rebuild
TRACE 2014/03/10 23:38:16 build.go:127: Exec: [/usr/local/bin/git describe --always --dirty]
TRACE 2014/03/10 23:38:16 build.go:77: Exec: [/usr/local/bin/go build -ldflags -X github.com/robfig/revel/samples/booking/app.APP_VERSION "git-930a54f" -tags gorp -o /Users/nrser/dev/gopath/bin/booking github.com/robfig/revel/samples/booking/app/tmp]
TRACE 2014/03/10 23:38:18 app.go:56: Exec app: /Users/nrser/dev/gopath/bin/booking [/Users/nrser/dev/gopath/bin/booking -port=56507 -importPath=github.com/robfig/revel/samples/booking -runMode=dev]
ERROR 2014/03/10 23:38:18 app.go:58: Error running: fork/exec /Users/nrser/dev/gopath/bin/booking: exec format error

我认为这与使用旧命令行工具构建的一些东西和新版本的一些东西有关,但我不知道如何清理二进制文件或强制重建所有的包或任何需要的东西。任何帮助非常感谢。

一些可能相关的转储:

uname -a

Darwin mba2 12.5.0 Darwin Kernel Version 12.5.0: Sun Sep 29 13:33:47 PDT 2013; root:xnu-2050.48.12~1/RELEASE_X86_64 x86_64

go env

GOARCH="amd64"
GOBIN=""
GOCHAR="6"
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GOOS="darwin"
GOPATH="/Users/nrser/dev/gopath"
GORACE=""
GOROOT="/usr/local/Cellar/go/1.2/libexec"
GOTOOLDIR="/usr/local/Cellar/go/1.2/libexec/pkg/tool/darwin_amd64"
TERM="dumb"
CC="/usr/local/bin/gcc-4.2"
GOGCCFLAGS="-g -O2 -fPIC -m64 -pthread -fno-common"
CXX="clang++"
CGO_ENABLED="1"

go刚刚通过自制软件安装,

go version

go version go1.2 darwin/amd64

0 个答案:

没有答案
相关问题