Cannot start debug in Gogland 1.0 EAP on macOS Sierra

208 views Asked by At

I've switched to Go not so long ago. I've chosen JetBrains Gogland as IDE. I like both: Go and IDE, except a one issue. I don't know whether it is an issue with IDE or with Go lang configuration on macOS Sierra. But when I'm trying start debuging for a test from Gogland, the build fails with message:

GOROOT=/usr/local/go
GOPATH=/Users/username/project/go
/usr/local/go/bin/go test -c -i -o /private/var/folders/3b/hlrss45s1p93cgtq9xgsw4gh0000gn/T/All_in__bitbucket_org_ username_package_matrix_go -gcflags "-N -l" -a bitbucket.org/usaername/package/matrix
go install runtime/internal/sys: open /usr/local/go/pkg/darwin_amd64/runtime/internal/sys.a: permission denied

I use Go 1.9

$ go version
go version go1.9 darwin/amd64
$ go env
GOARCH="amd64"
GOBIN=""
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GOOS="darwin"
GOPATH="/Users/azagretdinov/project/go"
GORACE=""
GOROOT="/usr/local/Cellar/go/1.9/libexec"
GOTOOLDIR="/usr/local/Cellar/go/1.9/libexec/pkg/tool/darwin_amd64"
GCCGO="gccgo"
CC="clang"
GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/3b/hlrss45s1p93cgtq9xgsw4gh0000gn/T/go-build006508560=/tmp/go-build -gno-record-gcc-switches -fno-common"
CXX="clang++"
CGO_ENABLED="1"
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"

Information about Gogland

Gogland (1.0 Preview) 1.0 EAP
Build #GO-172.3757.46, built on August 11, 2017
Gogland EAP User
Expiration date: November 9, 2017
JRE: 1.8.0_152-release-915-b10 x86_64
JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
Mac OS X 10.12.6
1

There are 1 answers

1
dlsniper On BEST ANSWER

You are using an old version of the IDE, please upgrade to the latest one and it will work as expected.

For reference, this issue was addressed in EAP 13 / 14 (which is the latest), see the original issue here: https://youtrack.jetbrains.com/issue/GO-4430