Skip to content

error: ‘SIOCGSTAMPNS’ was not declared in this scope #21

@brooc

Description

@brooc

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions