include libudev only on udev builds
This commit is contained in:
parent
b350ece864
commit
3065187300
1 changed files with 4 additions and 1 deletions
|
@ -33,11 +33,14 @@
|
||||||
#include "joystick_linux.h"
|
#include "joystick_linux.h"
|
||||||
|
|
||||||
#include <linux/input.h>
|
#include <linux/input.h>
|
||||||
#include <libudev.h>
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
|
|
||||||
|
#ifdef UDEV_ENABLED
|
||||||
|
#include <libudev.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
#define LONG_BITS (sizeof(long) * 8)
|
#define LONG_BITS (sizeof(long) * 8)
|
||||||
#define test_bit(nr, addr) (((1UL << ((nr) % LONG_BITS)) & ((addr)[(nr) / LONG_BITS])) != 0)
|
#define test_bit(nr, addr) (((1UL << ((nr) % LONG_BITS)) & ((addr)[(nr) / LONG_BITS])) != 0)
|
||||||
#define NBITS(x) ((((x)-1)/LONG_BITS)+1)
|
#define NBITS(x) ((((x)-1)/LONG_BITS)+1)
|
||||||
|
|
Loading…
Reference in a new issue