mdlayher / raw

Package raw enables reading and writing data at the device driver level for a network interface. MIT Licensed.
MIT License
425 stars 71 forks source link

../../_go/src/github.com/mdlayher/raw/raw_linux.go:86:14: f.SyscallConn undefined (type *os.File has no field or method SyscallConn) #63

Closed tpo closed 4 years ago

tpo commented 4 years ago
$ go  get github.com/mdlayher/arp
# github.com/mdlayher/raw
../../_go/src/github.com/mdlayher/raw/raw_linux.go:86:14: f.SyscallConn undefined (type *os.File has no field or method SyscallConn)

I get this because I'm trying to build vip-manager, which apparently depends on github.com/mdlayher/arp which apparently depends on github.com/mdlayher/raw.

Not being experienced with building go stuff I do not have a clue on how to fix this. The only thing I can google up is https://github.com/bettercap/bettercap/issues/468 which I'm unable to translate into a fix for not being able to go get github.com/mdlayher/raw.

Any help is very appreciated.

tpo commented 4 years ago

I've worked around the problem by:

cd $GOPATH/src/github.com/mdlayher/raw
git checkout 156e9b6
cd $GOPATH/src/github.com/mdlayher/arp
git checkout 43953fc

whereas the revisions are from https://github.com/cybertec-postgresql/vip-manager/blob/master/Gopkg.lock

mdlayher commented 4 years ago

https://golang.org/pkg/os/#File.SyscallConn

This method was added in Go 1.12, so I assume your version of Go is out of date at this point. The latest stable release is 1.14. Closing.

tpo commented 4 years ago

@mdlayher you are correct. I am not developping Go stuff so I'm not following Go's own releases. I'm on Debian stable which ships go1.11.6.

Thanks a lot!

mdlayher commented 4 years ago

@tpo yeah this is the unfortunate part about distro packaged Go. If possible, I'd move to 1.14 ASAP. 1.11 is no longer supported upstream.