aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKhem Raj <raj.khem@gmail.com>2019-11-30 10:17:23 -0800
committerMartin Jansa <Martin.Jansa@gmail.com>2019-12-02 15:14:31 +0100
commit25039161c1646ce1b6cc30303d4588e43b9b714a (patch)
tree47c328951a680334430e423801e45d6d1bca5f56
parent4f3ed3ed490f092f53a4ff4a78e331c0e4886350 (diff)
qtwebengine: Fix build with 64bit time_t on 32bit architectures
Signed-off-by: Khem Raj <raj.khem@gmail.com>
-rw-r--r--recipes-qt/qt5/qtwebengine/chromium/0021-chromium-Fix-build-on-32bit-arches-with-64bit-time_t.patch70
-rw-r--r--recipes-qt/qt5/qtwebengine_git.bb1
2 files changed, 71 insertions, 0 deletions
diff --git a/recipes-qt/qt5/qtwebengine/chromium/0021-chromium-Fix-build-on-32bit-arches-with-64bit-time_t.patch b/recipes-qt/qt5/qtwebengine/chromium/0021-chromium-Fix-build-on-32bit-arches-with-64bit-time_t.patch
new file mode 100644
index 00000000..ac16068c
--- /dev/null
+++ b/recipes-qt/qt5/qtwebengine/chromium/0021-chromium-Fix-build-on-32bit-arches-with-64bit-time_t.patch
@@ -0,0 +1,70 @@
+From 6ae9112ffea9a5b7d41a06c3d33e55e4f32d8b5a Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sat, 30 Nov 2019 10:07:43 -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
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ chromium/ui/events/ozone/evdev/event_converter_evdev.cc | 4 ++--
+ chromium/ui/events/ozone/evdev/touch_evdev_debug_buffer.cc | 6 +++---
+ chromium/ui/events/ozone/evdev/touch_evdev_debug_buffer.h | 5 +++++
+ 3 files changed, 10 insertions(+), 5 deletions(-)
+
+diff --git a/chromium/ui/events/ozone/evdev/event_converter_evdev.cc b/chromium/ui/events/ozone/evdev/event_converter_evdev.cc
+index 684514ff011..e2f2ae0b633 100644
+--- a/chromium/ui/events/ozone/evdev/event_converter_evdev.cc
++++ b/chromium/ui/events/ozone/evdev/event_converter_evdev.cc
+@@ -168,8 +168,8 @@ void EventConverterEvdev::SetPalmSuppressionCallback(
+ base::TimeTicks EventConverterEvdev::TimeTicksFromInputEvent(
+ const input_event& event) {
+ base::TimeTicks timestamp =
+- ui::EventTimeStampFromSeconds(event.time.tv_sec) +
+- base::TimeDelta::FromMicroseconds(event.time.tv_usec);
++ ui::EventTimeStampFromSeconds(event.input_event_sec) +
++ base::TimeDelta::FromMicroseconds(event.input_event_usec);
+ ValidateEventTimeClock(&timestamp);
+ return timestamp;
+ }
+diff --git a/chromium/ui/events/ozone/evdev/touch_evdev_debug_buffer.cc b/chromium/ui/events/ozone/evdev/touch_evdev_debug_buffer.cc
+index 363c3183e05..4fccfd62f84 100644
+--- a/chromium/ui/events/ozone/evdev/touch_evdev_debug_buffer.cc
++++ b/chromium/ui/events/ozone/evdev/touch_evdev_debug_buffer.cc
+@@ -59,11 +59,11 @@ void TouchEventLogEvdev::DumpLog(const char* filename) {
+ for (int i = 0; i < kDebugBufferSize; ++i) {
+ struct TouchEvent* te =
+ &logged_events_[(debug_buffer_tail_ + i) % kDebugBufferSize];
+- if (te->ev.time.tv_sec == 0 && te->ev.time.tv_usec == 0)
++ if (te->ev.input_event_sec == 0 && te->ev.input_event_usec == 0)
+ continue;
+ std::string event_string = base::StringPrintf(
+- "E: %ld.%06ld %04x %04x %d %d\n", te->ev.time.tv_sec,
+- te->ev.time.tv_usec, te->ev.type, te->ev.code, te->ev.value, te->slot);
++ "E: %ld.%06ld %04x %04x %d %d\n", te->ev.input_event_sec,
++ te->ev.input_event_usec, te->ev.type, te->ev.code, te->ev.value, te->slot);
+ report_content += event_string;
+ }
+ file.Write(0, report_content.c_str(), report_content.length());
+diff --git a/chromium/ui/events/ozone/evdev/touch_evdev_debug_buffer.h b/chromium/ui/events/ozone/evdev/touch_evdev_debug_buffer.h
+index ccd3a499a38..5a2da89d09a 100644
+--- a/chromium/ui/events/ozone/evdev/touch_evdev_debug_buffer.h
++++ b/chromium/ui/events/ozone/evdev/touch_evdev_debug_buffer.h
+@@ -14,6 +14,11 @@
+
+ #include "ui/events/ozone/evdev/events_ozone_evdev_export.h"
+
++#ifndef input_event_sec
++#define input_event_sec time.tv_sec
++#define input_event_usec time.tv_usec
++#endif
++
+ namespace ui {
+
+ class EventDeviceInfo;
+--
+2.24.0
+
diff --git a/recipes-qt/qt5/qtwebengine_git.bb b/recipes-qt/qt5/qtwebengine_git.bb
index 00106a73..c6474db9 100644
--- a/recipes-qt/qt5/qtwebengine_git.bb
+++ b/recipes-qt/qt5/qtwebengine_git.bb
@@ -159,6 +159,7 @@ SRC_URI += " \
file://chromium/0005-chromium-Do-not-try-to-set-the-guessed-values-for-ma.patch;patchdir=src/3rdparty \
file://chromium/0006-chromium-aarch64-skia-build-fix.patch;patchdir=src/3rdparty \
file://chromium/0007-chromium-fix-build-after-y2038-changes-in-glibc.patch;patchdir=src/3rdparty \
+ file://chromium/0021-chromium-Fix-build-on-32bit-arches-with-64bit-time_t.patch;patchdir=src/3rdparty \
"
SRC_URI_append_libc-musl = "\