vim-gocode icon indicating copy to clipboard operation
vim-gocode copied to clipboard

Compiler support not working?

Open myitcv opened this issue 10 years ago • 4 comments

Using commit 76f1ece5b6950f64f56f3c5d70a3c33e4f1e25af of vim-gocode and:

$ gvm version
Go Version Manager v1.0.19 installed at /home/myitcv/.gvm
$ vim --version
VIM - Vi IMproved 7.4 (2013 Aug 10, compiled Feb 25 2014 10:54:46)
Included patches: 1-192
$ echo $GOROOT
/home/myitcv/.gvm/gos/go1.2
$ echo $GOPATH
/home/myitcv/gostuff:/home/myitcv/.gvm/pkgsets/go1.2/global

The simple hello world example:

// /home/myitcv/gostuff/src/github.com/myitcv/hello/hello.go

package main
import "fmt"

func main() {
  fmt.Printf("Hello world!\n")
}

Checking :set makeprg:

makeprg=go build $* ~/gostuff/src/github.com/myitcv/hello

Then :make produces:

can't load package: package /home/myitcv/gostuff/src/github.com/myitcv/hello: import "/home/myitcv/gostuff/src/github.com/myitcv/hello": cannot import absolute path

Any thoughts on what I'm missing here?

Incidentally, :set makeprg=go\ build works as expected.

Thanks in advance. Great integration with gocode

myitcv avatar Feb 28 '14 16:02 myitcv