raintank / go-pinger

Go library for perform ICMP ping checks to 1 or more destination addresses.
Apache License 2.0
20 stars 15 forks source link

can't build on windows #4

Open freexdk opened 5 years ago

freexdk commented 5 years ago

Can't build on windows Tried both cross compile and directly on windows 10 Linux works fine.

github.com/raintank/go-pinger

../../github.com/raintank/go-pinger/packet_reader.go:75:33: not enough arguments in call to syscall.Syscall ../../github.com/raintank/go-pinger/packet_reader.go:75:34: undefined: syscall.SYS_IOCTL ../../github.com/raintank/go-pinger/packet_reader.go:75:74: undefined: syscall.SIOCGSTAMP ../../github.com/raintank/go-pinger/packet_reader.go:149:33: not enough arguments in call to syscall.Syscall ../../github.com/raintank/go-pinger/packet_reader.go:149:34: undefined: syscall.SYS_IOCTL ../../github.com/raintank/go-pinger/packet_reader.go:149:74: undefined: syscall.SIOCGSTAMP

woodsaj commented 5 years ago

yes, i use the SIOCGSTAMP ioctl operation to get the packet receive time. This is a linux only feature.

I will happily accept a PR to provide support for Windows and OSX, but it is not on my todo list.