goreplay icon indicating copy to clipboard operation
goreplay copied to clipboard

gor on arm64: undefined: unix.SYS_POLL

Open emetriqChris opened this issue 4 years ago • 2 comments

Moin,

I'm trying to compile gor (latest checkout from github) on a Ubuntu ARM64 machine (I tried Ubuntu 20.04 and 22.04). For 22.04 I'm using libpcap 1.10.1 and go 1.17.3 (both installed from Ubuntu Repo).

The build fails with

capture/sock_linux.go:144:27: undefined: unix.SYS_POLL

The corresponding code is

_, _, e := unix.Syscall(unix.SYS_POLL, uintptr(unsafe.Pointer(poll)), 1, sock.pollTimeout)

I found https://github.com/golang/go/issues/16052 which doesn't help me. Do you have any idea how to compile gor on aarch64?

Thanks a lot!

Christian Kelinski

P.S. I forgot how I managed this, but we've a goreplay v1.0.0 up and running on aarch64

emetriqChris avatar Dec 21 '21 07:12 emetriqChris

Hi,

I changed the Syscall from unix.SYS_POLL to unix.SYS_PPOLL and at least I'm able to compile gor on a Ubuntu 20.04 aarch64 machine.

Doing the test from your tutorial was also possible, so basically it's working. But I'm not sure if there are any downsides.

Greetings, Christian

emetriqChris avatar Dec 27 '21 13:12 emetriqChris

Ran into this same issue while trying to build an arm64 container for goreplay.

jauderho avatar Jan 19 '22 19:01 jauderho