[PATCH libinput 1/3] Make a link to the html docs available as a #define
Peter Hutterer
peter.hutterer at who-t.net
Wed Apr 27 10:36:48 UTC 2016
Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>
---
configure.ac | 4 ++++
src/libinput-private.h | 8 ++++++++
2 files changed, 12 insertions(+)
diff --git a/configure.ac b/configure.ac
index 507b8e0..8c5b257 100644
--- a/configure.ac
+++ b/configure.ac
@@ -17,6 +17,10 @@ AC_SUBST([LIBINPUT_VERSION_MINOR], [libinput_minor_version])
AC_SUBST([LIBINPUT_VERSION_MICRO], [libinput_micro_version])
AC_SUBST([LIBINPUT_VERSION], [libinput_version])
+AC_DEFINE([LIBINPUT_VERSION_MAJOR], [libinput_major_version], "libinput major version number")
+AC_DEFINE([LIBINPUT_VERSION_MINOR], [libinput_minor_version], "libinput minor version number")
+AC_DEFINE([LIBINPUT_VERSION_MICRO], [libinput_micro_version], "libinput micro version number")
+
AC_CONFIG_HEADERS([config.h])
AC_CONFIG_MACRO_DIR([m4])
diff --git a/src/libinput-private.h b/src/libinput-private.h
index 539e69a..b65ae93 100644
--- a/src/libinput-private.h
+++ b/src/libinput-private.h
@@ -25,6 +25,8 @@
#ifndef LIBINPUT_PRIVATE_H
#define LIBINPUT_PRIVATE_H
+#include "config.h"
+
#include <errno.h>
#include <math.h>
@@ -33,6 +35,12 @@
#include "libinput.h"
#include "libinput-util.h"
+#if LIBINPUT_VERSION_MICRO >= 90
+#define HTTP_DOC_LINK "https://wayland.freedesktop.org/libinput/doc/latest/"
+#else
+#define HTTP_DOC_LINK "https://wayland.freedesktop.org/libinput/doc/" VERSION "/"
+#endif
+
struct libinput_source;
/* A coordinate pair in device coordinates */
--
2.7.4
More information about the wayland-devel
mailing list