openaps / oref0

oref0: The open reference implementation of the OpenAPS reference design.
http://www.OpenAPS.org
MIT License
432 stars 394 forks source link

Compile error in oref0-setup.sh when choosing to compile go code from source #1063

Closed juehv closed 5 years ago

juehv commented 6 years ago

Started interactive setup with g4-go, not explorer, not edison, not head and decide to compile from source. Setup fails with following error:

Fetching https://golang.org/x/sys/unix?go-get=1
Parsing meta tags from https://golang.org/x/sys/unix?go-get=1 (status code 200)
get "golang.org/x/sys/unix": found meta tag get.metaImport{Prefix:"golang.org/x/                                                              sys", VCS:"git", RepoRoot:"https://go.googlesource.com/sys"} at https://golang.o                                                              rg/x/sys/unix?go-get=1
get "golang.org/x/sys/unix": verifying non-authoritative meta tag
Fetching https://golang.org/x/sys?go-get=1
Parsing meta tags from https://golang.org/x/sys?go-get=1 (status code 200)
golang.org/x/sys (download)
github.com/ecc1/radio (download)
github.com/ecc1/spi (download)
github.com/ecc1/nightscout (download)
github.com/ecc1/papertrail (download)
runtime
# runtime
/usr/local/go/src/runtime/mwbbuf.go:162:19: getg().m.p.ptr().wbBuf undefined (ty                                                              pe *p has no field or method wbBuf)
/usr/local/go/src/runtime/mwbbuf.go:172:20: getg().m.p.ptr().wbBuf undefined (ty                                                              pe *p has no field or method wbBuf)
/usr/local/go/src/runtime/mwbbuf.go:196:38: _p_.wbBuf undefined (type *p has no                                                               field or method wbBuf)
/usr/local/go/src/runtime/mwbbuf.go:197:11: _p_.wbBuf undefined (type *p has no                                                               field or method wbBuf)
/usr/local/go/src/runtime/mwbbuf.go:197:47: invalid expression unsafe.Sizeof(_p_                                                              .wbBuf.buf[0])
/usr/local/go/src/runtime/mwbbuf.go:198:13: _p_.wbBuf undefined (type *p has no                                                               field or method wbBuf)
/usr/local/go/src/runtime/mwbbuf.go:201:5: _p_.wbBuf undefined (type *p has no f                                                              ield or method wbBuf)
/usr/local/go/src/runtime/mwbbuf.go:254:5: gcw.putBatch undefined (type *gcWork                                                               has no field or method putBatch)
Couldn't go get medtronic
juehv commented 6 years ago

As a side note: I used the dev branch...

szymjaw commented 6 years ago

I also had this problem. After uninstalling golang v1.10.3 and installing v1.9.7 everything works.

juehv commented 6 years ago

Interesting... But when I compile by hand, it works just fine !

szymjaw commented 6 years ago

Can you check your GOROOT in $HOME/.bash_profile ? Maybe you should change to empty

juehv commented 6 years ago

I can try, but I think that's a task for the setup script to make sure the environment is right set up...

princejha95 commented 6 years ago

I am having v1.9.7 of go but I still have same problem.

`$HOME/golang/go/src/github.com/grpc-ecosystem/grpc-gateway/runtime/mwbbuf.go:162:19: getg().m.p.ptr().wbBuf undefined (type *p has no field or method wbBuf)

$HOME/golang/go/src/github.com/grpc-ecosystem/grpc-gateway/runtime/mwbbuf.go:172:20: getg().m.p.ptr().wbBuf undefined (type *p has no field or method wbBuf)

$HOME/golang/go/src/github.com/grpc-ecosystem/grpc-gateway/runtime/mwbbuf.go:196:38: p.wbBuf undefined (type *p has no field or method wbBuf)

$HOME/golang/go/src/github.com/grpc-ecosystem/grpc-gateway/runtime/mwbbuf.go:197:11: p.wbBuf undefined (type *p has no field or method wbBuf)

$HOME/golang/go/src/github.com/grpc-ecosystem/grpc-gateway/runtime/mwbbuf.go:197:47: invalid expression unsafe.Sizeof(p.wbBuf.buf[0])

$HOME/golang/go/src/github.com/grpc-ecosystem/grpc-gateway/runtime/mwbbuf.go:198:13: p.wbBuf undefined (type *p has no field or method wbBuf)

$HOME/golang/go/src/github.com/grpc-ecosystem/grpc-gateway/runtime/mwbbuf.go:201:5: p.wbBuf undefined (type *p has no field or method wbBuf)

$HOME/golang/go/src/github.com/grpc-ecosystem/grpc-gateway/runtime/mwbbuf.go:254:5: gcw.putBatch undefined (type *gcWork has no field or method putBatch)`

Please somebody tell me how to fix it.

danamlewis commented 5 years ago

I'm guessing this has been resolved since then in 0.7.0-dev, but please open a new issue for any related errors with the current dev branch.