Skip to content

Commit

Permalink
Patch: video_capture: Use correct V4L2 header on OpenBSD
Browse files Browse the repository at this point in the history
video(4) provides everything needed, the Linux header does not exist.
Tested on OpenBSD/amd64 7.0 -CURRENT.
  • Loading branch information
klemensn authored and john-preston committed May 3, 2022
1 parent c7b75bb commit 77761ca
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/modules/video_capture/linux/device_info_linux.cc
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,11 @@
#include <sys/ioctl.h>
#include <unistd.h>
// v4l includes
#if defined(__OpenBSD__)
#include <sys/videoio.h>
#else
#include <linux/videodev2.h>
#endif

#include <vector>

Expand Down
4 changes: 4 additions & 0 deletions src/modules/video_capture/linux/video_capture_linux.cc
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,11 @@

#include <errno.h>
#include <fcntl.h>
#if defined(__OpenBSD__)
#include <sys/videoio.h>
#else
#include <linux/videodev2.h>
#endif
#include <stdio.h>
#include <string.h>
#include <sys/ioctl.h>
Expand Down

0 comments on commit 77761ca

Please sign in to comment.