aboutsummaryrefslogtreecommitdiffstats
path: root/common.h
blob: 786212174a5f40f78c46458f980781bb532349ec (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/* See LICENSE file for copyright and license details. */
#include "libgamepad.h"

#include <sys/stat.h>
#include <ctype.h>
#include <dirent.h>
#include <errno.h>
#include <fcntl.h>
#include <limits.h>
#include <math.h>
#include <stddef.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <strings.h>
#include <time.h>
#include <unistd.h>

#include <libevdev/libevdev.h>
#include <libudev.h>


#define ELEMSOF(A) (sizeof(A) / sizeof(*(A)))


struct libgamepad_attachment_monitor {
	struct udev *udev;
	struct udev_monitor *monitor;
};


extern const char *libgamepad_button_names__[
#include "button.count"
];

extern const char *libgamepad_absolute_axis_names__[
#include "absolute-axis.count"
];

extern const char *libgamepad_relative_axis_names__[
#include "relative-axis.count"
];