[vlc-devel] [PATCH 3.0 07/41] Contribs, Qt: work-around compiler crash on Mingw/32

Steve Lhomme robux4 at ycbcr.xyz
Tue Jul 7 15:11:06 CEST 2020


From: Jean-Baptiste Kempf <jb at videolan.org>

(cherry picked from commit bf633b67431cc85156d3e2a8912c08b262dedd72)
Signed-off-by: Steve Lhomme <robux4 at ycbcr.xyz>
---
 contrib/src/qt/0001-disable-qt_random_cpu.patch | 11 +++++++++++
 contrib/src/qt/rules.mak                        |  5 +++++
 2 files changed, 16 insertions(+)
 create mode 100644 contrib/src/qt/0001-disable-qt_random_cpu.patch

diff --git a/contrib/src/qt/0001-disable-qt_random_cpu.patch b/contrib/src/qt/0001-disable-qt_random_cpu.patch
new file mode 100644
index 0000000000..a271da4e9d
--- /dev/null
+++ b/contrib/src/qt/0001-disable-qt_random_cpu.patch
@@ -0,0 +1,11 @@
+--- qt-5.11.0/src/corelib/global/qrandom.cpp.orig	2018-06-19 11:22:03.011543136 +0200
++++ qt-5.11.0/src/corelib/global/qrandom.cpp	2018-06-19 11:23:45.231337043 +0200
+@@ -90,7 +90,7 @@
+ 
+ QT_BEGIN_NAMESPACE
+ 
+-#if defined(Q_PROCESSOR_X86) && QT_COMPILER_SUPPORTS_HERE(RDRND)
++#if 0
+ static qsizetype qt_random_cpu(void *buffer, qsizetype count) Q_DECL_NOTHROW;
+ 
+ #  ifdef Q_PROCESSOR_X86_64
diff --git a/contrib/src/qt/rules.mak b/contrib/src/qt/rules.mak
index 3e1df1ec4f..bc19bfb2ba 100644
--- a/contrib/src/qt/rules.mak
+++ b/contrib/src/qt/rules.mak
@@ -22,8 +22,13 @@ $(TARBALLS)/qt-$(QT_VERSION).tar.xz:
 qt: qt-$(QT_VERSION).tar.xz .sum-qt
 	$(UNPACK)
 	mv qtbase-everywhere-src-$(QT_VERSION) qt-$(QT_VERSION)
+ifdef HAVE_WIN32
 	$(APPLY) $(SRC)/qt/0001-Windows-QPA-prefer-lower-value-when-rounding-fractio.patch
 	$(APPLY) $(SRC)/qt/0002-Windows-QPA-Disable-systray-notification-sounds.patch
+ifndef HAVE_WIN64
+	$(APPLY) $(SRC)/qt/0001-disable-qt_random_cpu.patch
+endif
+endif
 	$(MOVE)
 
 ifdef HAVE_MACOSX
-- 
2.26.2



More information about the vlc-devel mailing list