From 0f4854982c53e60f49e721b24c032e162482179d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20=C3=85dahl?= Date: Wed, 23 Apr 2014 09:54:49 +0200 Subject: [PATCH] evdev: Define KEY_LIGHTS_TOGGLE macro if missing MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When building on a system with an older kernel, some KEY_ macros might be missing. To be able to build on such system, define them if they are missing. It is probably better to keep our own copy of input.h somewhere in our tree, and include that one instead of the system one, but that can be added later. Signed-off-by: Jonas Ã…dahl --- src/evdev.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/evdev.c b/src/evdev.c index 918af8d6..57dcca76 100644 --- a/src/evdev.c +++ b/src/evdev.c @@ -39,6 +39,10 @@ #define DEFAULT_AXIS_STEP_DISTANCE li_fixed_from_int(10) +#ifndef KEY_LIGHTS_TOGGLE +#define KEY_LIGHTS_TOGGLE 0x160 +#endif + void evdev_device_led_update(struct evdev_device *device, enum libinput_led leds) {