wayland: Use dev/evdev/input.h on FreeBSD

The header linux/input.h used by GDK is specific to Linux. It is
possible to get a few Linux headers on FreeBSD by installing v4l_compat,
but it is usually better to use the one shipped with FreeBSD.

We prefer dev/evdev/input.h to linux/input.h here, so it will always use
dev/evdev/input.h on FreeBSD regardless of v4l_compat.

https://svnweb.freebsd.org/changeset/ports/465644
This commit is contained in:
Ting-Wei Lan 2018-05-01 22:28:57 +08:00
parent 1dcb76bc26
commit 7fed0b74ed
3 changed files with 10 additions and 2 deletions

View File

@ -286,6 +286,10 @@
/* Define to 1 if linux/memfd.h exists */
#mesondefine HAVE_LINUX_MEMFD_H
#mesondefine HAVE_LINUX_INPUT_H
#mesondefine HAVE_DEV_EVDEV_INPUT_H
#mesondefine GTK_SYSCONFDIR
#mesondefine GTK_LOCALEDIR

View File

@ -41,11 +41,13 @@
#include <xkbcommon/xkbcommon.h>
#include <linux/input.h>
#include <sys/time.h>
#include <sys/mman.h>
#if defined(HAVE_DEV_EVDEV_INPUT_H)
#include <dev/evdev/input.h>
#elif defined(HAVE_LINUX_INPUT_H)
#include <linux/input.h>
#endif
#define BUTTON_BASE (BTN_LEFT - 1) /* Used to translate to 1-indexed buttons */

View File

@ -149,9 +149,11 @@ cdata.set('GTK_INTERFACE_AGE', gtk_interface_age)
check_headers = [
'crt/externs.h',
'dev/evdev/input.h',
'dlfcn.h',
'ftw.h',
'inttypes.h',
'linux/input.h',
'linux/memfd.h',
'locale.h',
'memory.h',