summaryrefslogtreecommitdiff
path: root/meta-openembedded/meta-python/recipes-devtools/python/python-evdev/0001-Fix-build-on-32bit-arches-with-64bit-time_t.patch
diff options
context:
space:
mode:
authorAndrew Geissler <geissonator@yahoo.com>2020-04-13 21:39:40 +0300
committerAndrew Geissler <geissonator@yahoo.com>2020-05-05 16:30:44 +0300
commit82c905dc58a36aeae40b1b273a12f63fb1973cf4 (patch)
tree38caf00263451b5036435cdc36e035b25d32e623 /meta-openembedded/meta-python/recipes-devtools/python/python-evdev/0001-Fix-build-on-32bit-arches-with-64bit-time_t.patch
parent83ecb75644b3d677c274188f9ac0b2374d6f6925 (diff)
downloadopenbmc-82c905dc58a36aeae40b1b273a12f63fb1973cf4.tar.xz
meta-openembedded and poky: subtree updates
Squash of the following due to dependencies among them and OpenBMC changes: meta-openembedded: subtree update:d0748372d2..9201611135 meta-openembedded: subtree update:9201611135..17fd382f34 poky: subtree update:9052e5b32a..2e11d97b6c poky: subtree update:2e11d97b6c..a8544811d7 The change log was too large for the jenkins plugin to handle therefore it has been removed. Here is the first and last commit of each subtree: meta-openembedded:d0748372d2 cppzmq: bump to version 4.6.0 meta-openembedded:17fd382f34 mpv: Remove X11 dependency poky:9052e5b32a package_ipk: Remove pointless comment to trigger rebuild poky:a8544811d7 pbzip2: Fix license warning Change-Id: If0fc6c37629642ee207a4ca2f7aa501a2c673cd6 Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
Diffstat (limited to 'meta-openembedded/meta-python/recipes-devtools/python/python-evdev/0001-Fix-build-on-32bit-arches-with-64bit-time_t.patch')
-rw-r--r--meta-openembedded/meta-python/recipes-devtools/python/python-evdev/0001-Fix-build-on-32bit-arches-with-64bit-time_t.patch83
1 files changed, 0 insertions, 83 deletions
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-evdev/0001-Fix-build-on-32bit-arches-with-64bit-time_t.patch b/meta-openembedded/meta-python/recipes-devtools/python/python-evdev/0001-Fix-build-on-32bit-arches-with-64bit-time_t.patch
deleted file mode 100644
index 154172ca8..000000000
--- a/meta-openembedded/meta-python/recipes-devtools/python/python-evdev/0001-Fix-build-on-32bit-arches-with-64bit-time_t.patch
+++ /dev/null
@@ -1,83 +0,0 @@
-From 435e78aaf6745e4da0fe3d4455473011626c77d1 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Sat, 30 Nov 2019 11:21:20 -0800
-Subject: [PATCH] Fix build on 32bit arches with 64bit time_t
-
-time element is deprecated on new input_event structure in kernel's
-input.h [1]
-
-[1] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit?id=152194fe9c3f
-
-Upstream-Status: Submitted [https://github.com/gvalkov/python-evdev/pull/112]
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- evdev/input.c | 13 +++++++++----
- evdev/uinput.c | 9 ++++++++-
- 2 files changed, 17 insertions(+), 5 deletions(-)
-
-diff --git a/evdev/input.c b/evdev/input.c
-index 67b9348..432db92 100644
---- a/evdev/input.c
-+++ b/evdev/input.c
-@@ -24,6 +24,11 @@
- #include <linux/input.h>
- #endif
-
-+#ifndef input_event_sec
-+#define input_event_sec time.tv_sec
-+#define input_event_usec time.tv_usec
-+#endif
-+
- #define MAX_NAME_SIZE 256
-
- extern char* EV_NAME[EV_CNT];
-@@ -60,8 +65,8 @@ device_read(PyObject *self, PyObject *args)
- return NULL;
- }
-
-- PyObject* sec = PyLong_FromLong(event.time.tv_sec);
-- PyObject* usec = PyLong_FromLong(event.time.tv_usec);
-+ PyObject* sec = PyLong_FromLong(event.input_event_sec);
-+ PyObject* usec = PyLong_FromLong(event.input_event_usec);
- PyObject* val = PyLong_FromLong(event.value);
- PyObject* py_input_event = NULL;
-
-@@ -102,8 +107,8 @@ device_read_many(PyObject *self, PyObject *args)
-
- // Construct a list of event tuples, which we'll make sense of in Python
- for (unsigned i = 0 ; i < nread/event_size ; i++) {
-- sec = PyLong_FromLong(event[i].time.tv_sec);
-- usec = PyLong_FromLong(event[i].time.tv_usec);
-+ sec = PyLong_FromLong(event[i].input_event_sec);
-+ usec = PyLong_FromLong(event[i].input_event_usec);
- val = PyLong_FromLong(event[i].value);
-
- py_input_event = Py_BuildValue("OOhhO", sec, usec, event[i].type, event[i].code, val);
-diff --git a/evdev/uinput.c b/evdev/uinput.c
-index 192568d..56fe86c 100644
---- a/evdev/uinput.c
-+++ b/evdev/uinput.c
-@@ -16,6 +16,10 @@
- #include <linux/uinput.h>
- #endif
-
-+#ifndef input_event_sec
-+#define input_event_sec time.tv_sec
-+#define input_event_usec time.tv_usec
-+#endif
-
- // Workaround for installing on kernels newer than 4.4.
- #ifndef FF_MAX_EFFECTS
-@@ -232,8 +236,11 @@ uinput_write(PyObject *self, PyObject *args)
- if (!ret) return NULL;
-
- struct input_event event;
-+ struct timeval tval;
- memset(&event, 0, sizeof(event));
-- gettimeofday(&event.time, 0);
-+ gettimeofday(&tval, 0);
-+ event.input_event_usec = tval.tv_usec;
-+ event.input_event_sec = tval.tv_sec;
- event.type = type;
- event.code = code;
- event.value = value;