PKGBUILDs/qt5-multimedia/mingw-w64/0001-Recorder-includes-to-prevent-conflict-with-vsnprintf.patch
Martchus c9819b9c7c Update mingw-w64-qt5-* to 5.8.0
* Adapt hacks to new config system
* Use distinct mkspec mingw-w64-g++ rather than
  patching the existing win32-g++
* Testing QML and ANGLE is on TODO list
  because it hasn't been tested since quite a time
2017-02-09 16:10:06 +01:00

42 lines
1.4 KiB
Diff

From ecfcbb10eaae22d0887e074e3734d6d9e69d2e34 Mon Sep 17 00:00:00 2001
From: Martchus <martchus@gmx.net>
Date: Sun, 25 Sep 2016 21:36:56 +0200
Subject: [PATCH 1/2] Recorder includes to prevent conflict with vsnprintf
Some files #include <dshow.h>
This is a C header which also #include's stdio.h which adds a #define vsnprintf
This #define vsnprint conflicts with QtCore/qstring.h so reorder the includes
a bit to prevent this situation
---
src/multimedia/video/qvideosurfaceformat.h | 1 +
src/plugins/directshow/helpers/directshowglobal.h | 1 +
2 files changed, 2 insertions(+)
diff --git a/src/multimedia/video/qvideosurfaceformat.h b/src/multimedia/video/qvideosurfaceformat.h
index 83785ac0..25607d08 100644
--- a/src/multimedia/video/qvideosurfaceformat.h
+++ b/src/multimedia/video/qvideosurfaceformat.h
@@ -44,6 +44,7 @@
#include <QtCore/qpair.h>
#include <QtCore/qshareddata.h>
#include <QtCore/qsize.h>
+#include <QtCore/qstring.h>
#include <QtGui/qimage.h>
#include <QtMultimedia/qvideoframe.h>
diff --git a/src/plugins/directshow/helpers/directshowglobal.h b/src/plugins/directshow/helpers/directshowglobal.h
index f7890c52..4f7c8213 100644
--- a/src/plugins/directshow/helpers/directshowglobal.h
+++ b/src/plugins/directshow/helpers/directshowglobal.h
@@ -43,6 +43,7 @@
#include <dshow.h>
#include <QtCore/qglobal.h>
+#include <QtCore/qstring.h>
template <typename T> T *com_cast(IUnknown *unknown, const IID &iid)
{
--
2.11.0