error: ‘SIOCGSTAMPNS’ was not declared in this scope
brooc opened this issue · comments
Ohad Benjamin commented
I'm getting the following error when building on Ubuntu 20.04:
driver/SocketCanDriver/SocketCanInterface.cpp:428:28: error: ‘SIOCGSTAMPNS’ was not declared in this scope; did you mean ‘SIOCGSTAMP_OLD’?
428 | if (ioctl(_fd, SIOCGSTAMPNS, &ts_rcv) == 0) {
| ^~~~~~~~~~~~
| SIOCGSTAMP_OLD
The fix from here is to include
#include <linux/sockios.h>
in src/driver/SocketCanDriver/SocketCanInterface.cpp
uanheng commented
add the file "#include <linux/sockios.h>" to driver/SocketCanDriver/SocketCanInterface.cpp
Ohad Benjamin commented
Isn't that what I wrote?
injae hwang commented
it works for me thanks a lot