[PATCH 1/7] Check for python2 if available
David Herrmann
dh.herrmann at gmail.com
Sat Aug 17 04:58:13 PDT 2013
On some systems (specifically Arch Linux) /usr/bin/python is v3 while
/usr/bin/python2 is v2. Check for python2 and use it, iff available.
Otherwise fall back to python as usual.
Signed-off-by: David Herrmann <dh.herrmann at gmail.com>
---
configure.ac | 1 +
libevdev/Makefile.am | 2 +-
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/configure.ac b/configure.ac
index 68df538..889ff81 100644
--- a/configure.ac
+++ b/configure.ac
@@ -27,6 +27,7 @@ AM_SILENT_RULES([yes])
# Check for programs
AC_PROG_CC
+AC_CHECK_PROGS([PYTHON2], [python2 python])
# Initialize libtool
LT_PREREQ([2.2])
diff --git a/libevdev/Makefile.am b/libevdev/Makefile.am
index 9879c0e..e71b980 100644
--- a/libevdev/Makefile.am
+++ b/libevdev/Makefile.am
@@ -14,7 +14,7 @@ libevdevincludedir = $(includedir)/libevdev-1.0/libevdev
libevdevinclude_HEADERS = libevdev.h
event-names.h: Makefile make-event-names.py
- $(srcdir)/make-event-names.py --output=c > $@
+ $(PYTHON2) $(srcdir)/make-event-names.py --output=c > $@
EXTRA_DIST = make-event-names.py
CLEANFILES = event-names.h
--
1.8.3.4
More information about the Input-tools
mailing list