aboutsummaryrefslogtreecommitdiff
path: root/depends/patches/qt
diff options
context:
space:
mode:
Diffstat (limited to 'depends/patches/qt')
-rw-r--r--depends/patches/qt/fix-cocoahelpers-macos.patch70
-rw-r--r--depends/patches/qt/fix-xcb-include-order.patch49
-rw-r--r--depends/patches/qt/fix_configure_mac.patch50
-rw-r--r--depends/patches/qt/fix_no_printer.patch19
-rw-r--r--depends/patches/qt/mac-qmake.conf1
-rw-r--r--depends/patches/qt/mingw-uuidof.patch44
-rw-r--r--depends/patches/qt/pidlist_absolute.patch37
-rw-r--r--depends/patches/qt/qfixed-coretext.patch34
8 files changed, 70 insertions, 234 deletions
diff --git a/depends/patches/qt/fix-cocoahelpers-macos.patch b/depends/patches/qt/fix-cocoahelpers-macos.patch
deleted file mode 100644
index 1b43a9eff8..0000000000
--- a/depends/patches/qt/fix-cocoahelpers-macos.patch
+++ /dev/null
@@ -1,70 +0,0 @@
-From 0707260a4f8e64dfadf1df5f935e74cabb7c7d27 Mon Sep 17 00:00:00 2001
-From: Jake Petroules <jake.petroules@qt.io>
-Date: Sun, 1 Oct 2017 21:48:17 -0700
-Subject: [PATCH] Fix build error with macOS 10.13 SDK
-MIME-Version: 1.0
-Content-Type: text/plain; charset=utf8
-Content-Transfer-Encoding: 8bit
-
-Several of these variables/macros are no longer defined. We didn't
-validate the preconditions on iOS, tvOS, or watchOS, so no
-need to bother validating them on macOS either. Nor did we check the
-OSStatus result on any platform anyways.
-
-Task-number: QTBUG-63401
-Change-Id: Ife64dff767cf6d3f4b839fc53ec486181c176bf3
-(cherry-picked from 861544583511d4e6f7745d2339b26ff1cd44132b)
-Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
-Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
----
- src/plugins/platforms/cocoa/qcocoahelpers.h | 2 +-
- src/plugins/platforms/cocoa/qcocoahelpers.mm | 13 +------------
- 2 files changed, 2 insertions(+), 13 deletions(-)
-
-diff --git old/qtbase/src/plugins/platforms/cocoa/qcocoahelpers.h new/qtbase/src/plugins/platforms/cocoa/qcocoahelpers.h
-index bbb3793..74371d5 100644
---- old/qtbase/src/plugins/platforms/cocoa/qcocoahelpers.h
-+++ new/qtbase/src/plugins/platforms/cocoa/qcocoahelpers.h
-@@ -80,7 +80,7 @@ QColor qt_mac_toQColor(CGColorRef color);
- // Creates a mutable shape, it's the caller's responsibility to release.
- HIMutableShapeRef qt_mac_QRegionToHIMutableShape(const QRegion &region);
-
--OSStatus qt_mac_drawCGImage(CGContextRef inContext, const CGRect *inBounds, CGImageRef inImage);
-+void qt_mac_drawCGImage(CGContextRef inContext, const CGRect *inBounds, CGImageRef inImage);
-
- NSDragOperation qt_mac_mapDropAction(Qt::DropAction action);
- NSDragOperation qt_mac_mapDropActions(Qt::DropActions actions);
-diff --git old/qtbase/src/plugins/platforms/cocoa/qcocoahelpers.mm new/qtbase/src/plugins/platforms/cocoa/qcocoahelpers.mm
-index cd73148..3f8429e 100644
---- old/qtbase/src/plugins/platforms/cocoa/qcocoahelpers.mm
-+++ new/qtbase/src/plugins/platforms/cocoa/qcocoahelpers.mm
-@@ -544,15 +544,8 @@ NSRect qt_mac_flipRect(const QRect &rect)
- return NSMakeRect(rect.x(), flippedY, rect.width(), rect.height());
- }
-
--OSStatus qt_mac_drawCGImage(CGContextRef inContext, const CGRect *inBounds, CGImageRef inImage)
-+void qt_mac_drawCGImage(CGContextRef inContext, const CGRect *inBounds, CGImageRef inImage)
- {
-- // Verbatim copy if HIViewDrawCGImage (as shown on Carbon-Dev)
-- OSStatus err = noErr;
--
-- require_action(inContext != NULL, InvalidContext, err = paramErr);
-- require_action(inBounds != NULL, InvalidBounds, err = paramErr);
-- require_action(inImage != NULL, InvalidImage, err = paramErr);
--
- CGContextSaveGState( inContext );
- CGContextTranslateCTM (inContext, 0, inBounds->origin.y + CGRectGetMaxY(*inBounds));
- CGContextScaleCTM(inContext, 1, -1);
-@@ -560,10 +553,6 @@ OSStatus qt_mac_drawCGImage(CGContextRef inContext, const CGRect *inBounds, CGIm
- CGContextDrawImage(inContext, *inBounds, inImage);
-
- CGContextRestoreGState(inContext);
--InvalidImage:
--InvalidBounds:
--InvalidContext:
-- return err;
- }
-
- Qt::MouseButton cocoaButton2QtButton(NSInteger buttonNum)
---
-2.7.4
diff --git a/depends/patches/qt/fix-xcb-include-order.patch b/depends/patches/qt/fix-xcb-include-order.patch
deleted file mode 100644
index ec2bc17d9b..0000000000
--- a/depends/patches/qt/fix-xcb-include-order.patch
+++ /dev/null
@@ -1,49 +0,0 @@
---- old/qtbase/src/plugins/platforms/xcb/xcb_qpa_lib.pro 2015-03-17
-+++ new/qtbase/src/plugins/platforms/xcb/xcb_qpa_lib.pro 2015-03-17
-@@ -76,8 +76,6 @@
-
- DEFINES += $$QMAKE_DEFINES_XCB
- LIBS += $$QMAKE_LIBS_XCB
--QMAKE_CXXFLAGS += $$QMAKE_CFLAGS_XCB
--QMAKE_CFLAGS += $$QMAKE_CFLAGS_XCB
-
- CONFIG += qpa/genericunixfontdatabase
-
-@@ -89,7 +87,8 @@
- contains(QT_CONFIG, xcb-qt) {
- DEFINES += XCB_USE_RENDER
- XCB_DIR = ../../../3rdparty/xcb
-- INCLUDEPATH += $$XCB_DIR/include $$XCB_DIR/sysinclude
-+ QMAKE_CFLAGS += -I$$XCB_DIR/include -I$$XCB_DIR/sysinclude $$QMAKE_CFLAGS_XCB
-+ QMAKE_CXXFLAGS += -I$$XCB_DIR/include -I$$XCB_DIR/sysinclude $$QMAKE_CFLAGS_XCB
- LIBS += -lxcb -L$$MODULE_BASE_OUTDIR/lib -lxcb-static$$qtPlatformTargetSuffix()
- } else {
- LIBS += -lxcb -lxcb-image -lxcb-icccm -lxcb-sync -lxcb-xfixes -lxcb-shm -lxcb-randr -lxcb-shape -lxcb-keysyms -lxcb-xinerama
---- old/qtbase/src/plugins/platforms/xcb/xcb-static/xcb-static.pro
-+++ new/qtbase/src/plugins/platforms/xcb/xcb-static/xcb-static.pro
-@@ -9,7 +9,8 @@
-
- XCB_DIR = ../../../../3rdparty/xcb
-
--INCLUDEPATH += $$XCB_DIR/include $$XCB_DIR/include/xcb $$XCB_DIR/sysinclude
-+QMAKE_CFLAGS += -I$$XCB_DIR/include -I$$XCB_DIR/include/xcb -I$$XCB_DIR/sysinclude
-+QMAKE_CXXFLAGS += -I$$XCB_DIR/include -I$$XCB_DIR/include/xcb -I$$XCB_DIR/sysinclude
-
- QMAKE_CXXFLAGS += $$QMAKE_CFLAGS_XCB
- QMAKE_CFLAGS += $$QMAKE_CFLAGS_XCB
---- old/qtbase/src/plugins/platforms/xcb/xcb-plugin.pro
-+++ new/qtbase/src/plugins/platforms/xcb/xcb-plugin.pro
-@@ -6,6 +6,13 @@
- qxcbmain.cpp
- OTHER_FILES += xcb.json README
-
-+contains(QT_CONFIG, xcb-qt) {
-+ DEFINES += XCB_USE_RENDER
-+ XCB_DIR = ../../../3rdparty/xcb
-+ QMAKE_CFLAGS += -I$$XCB_DIR/include -I$$XCB_DIR/sysinclude $$QMAKE_CFLAGS_XCB
-+ QMAKE_CXXFLAGS += -I$$XCB_DIR/include -I$$XCB_DIR/sysinclude $$QMAKE_CFLAGS_XCB
-+}
-+
- PLUGIN_TYPE = platforms
- PLUGIN_CLASS_NAME = QXcbIntegrationPlugin
- !equals(TARGET, $$QT_DEFAULT_QPA_PLUGIN): PLUGIN_EXTENDS = -
diff --git a/depends/patches/qt/fix_configure_mac.patch b/depends/patches/qt/fix_configure_mac.patch
new file mode 100644
index 0000000000..0d7dd647de
--- /dev/null
+++ b/depends/patches/qt/fix_configure_mac.patch
@@ -0,0 +1,50 @@
+--- old/qtbase/mkspecs/features/mac/sdk.prf 2018-02-08 10:24:48.000000000 -0800
++++ new/qtbase/mkspecs/features/mac/sdk.prf 2018-03-23 10:38:56.000000000 -0700
+@@ -8,21 +8,21 @@
+ defineReplace(xcodeSDKInfo) {
+ info = $$1
+ equals(info, "Path"): \
+- info = --show-sdk-path
++ infoarg = --show-sdk-path
+ equals(info, "PlatformPath"): \
+- info = --show-sdk-platform-path
++ infoarg = --show-sdk-platform-path
+ equals(info, "SDKVersion"): \
+- info = --show-sdk-version
++ infoarg = --show-sdk-version
+ sdk = $$2
+ isEmpty(sdk): \
+ sdk = $$QMAKE_MAC_SDK
+
+ isEmpty(QMAKE_MAC_SDK.$${sdk}.$${info}) {
+- QMAKE_MAC_SDK.$${sdk}.$${info} = $$system("/usr/bin/xcrun --sdk $$sdk $$info 2>/dev/null")
++ QMAKE_MAC_SDK.$${sdk}.$${info} = $$system("/usr/bin/xcrun --sdk $$sdk $$infoarg 2>/dev/null")
+ # --show-sdk-platform-path won't work for Command Line Tools; this is fine
+ # only used by the XCTest backend to testlib
+- isEmpty(QMAKE_MAC_SDK.$${sdk}.$${info}):if(!isEmpty(QMAKE_XCODEBUILD_PATH)|!equals(info, "--show-sdk-platform-path")): \
+- error("Could not resolve SDK $$info for \'$$sdk\'")
++ isEmpty(QMAKE_MAC_SDK.$${sdk}.$${info}):if(!isEmpty(QMAKE_XCODEBUILD_PATH)|!equals(infoarg, "--show-sdk-platform-path")): \
++ error("Could not resolve SDK $$info for \'$$sdk\' using $$infoarg")
+ cache(QMAKE_MAC_SDK.$${sdk}.$${info}, set stash, QMAKE_MAC_SDK.$${sdk}.$${info})
+ }
+
+--- old/qtbase/configure 2018-02-08 10:24:48.000000000 -0800
++++ new/qtbase/configure 2018-03-23 05:42:29.000000000 -0700
+@@ -232,8 +232,13 @@
+
+ sdk=$(getSingleQMakeVariable "QMAKE_MAC_SDK" "$1")
+ if [ -z "$sdk" ]; then echo "QMAKE_MAC_SDK must be set when building on Mac" >&2; exit 1; fi
+- sysroot=$(/usr/bin/xcrun --sdk $sdk --show-sdk-path 2>/dev/null)
+- if [ -z "$sysroot" ]; then echo "Failed to resolve SDK path for '$sdk'" >&2; exit 1; fi
++ sysroot=$(getSingleQMakeVariable "QMAKE_MAC_SDK_PATH" "$1")
++
++ echo "sysroot pre-configured as $sysroot";
++ if [ -z "$sysroot" ]; then
++ sysroot=$(/usr/bin/xcrun --sdk $sdk --show-sdk-path 2>/dev/null)
++ if [ -z "$sysroot" ]; then echo "Failed to resolve SDK path for '$sdk'" >&2; exit 1; fi
++ fi
+
+ case "$sdk" in
+ macosx*)
+
+
diff --git a/depends/patches/qt/fix_no_printer.patch b/depends/patches/qt/fix_no_printer.patch
new file mode 100644
index 0000000000..f868ca2577
--- /dev/null
+++ b/depends/patches/qt/fix_no_printer.patch
@@ -0,0 +1,19 @@
+--- x/qtbase/src/plugins/platforms/cocoa/qprintengine_mac_p.h
++++ y/qtbase/src/plugins/platforms/cocoa/qprintengine_mac_p.h
+@@ -52,6 +52,7 @@
+ //
+
+ #include <QtCore/qglobal.h>
++#include <qpa/qplatformprintdevice.h>
+
+ #ifndef QT_NO_PRINTER
+
+--- x/qtbase/src/plugins/plugins.pro
++++ y/qtbase/src/plugins/plugins.pro
+@@ -8,6 +8,3 @@ qtHaveModule(gui) {
+ qtConfig(imageformatplugin): SUBDIRS *= imageformats
+ !android:qtConfig(library): SUBDIRS *= generic
+ }
+-
+-!winrt:qtHaveModule(printsupport): \
+- SUBDIRS += printsupport
diff --git a/depends/patches/qt/mac-qmake.conf b/depends/patches/qt/mac-qmake.conf
index ca70d30b15..337d0eb9ca 100644
--- a/depends/patches/qt/mac-qmake.conf
+++ b/depends/patches/qt/mac-qmake.conf
@@ -14,6 +14,7 @@ QMAKE_MAC_SDK.macosx.Path = $${MAC_SDK_PATH}
QMAKE_MAC_SDK.macosx.platform_name = macosx
QMAKE_MAC_SDK.macosx.SDKVersion = $${MAC_SDK_VERSION}
QMAKE_MAC_SDK.macosx.PlatformPath = /phony
+QMAKE_APPLE_DEVICE_ARCHS=x86_64
!host_build: QMAKE_CFLAGS += -target $${MAC_TARGET}
!host_build: QMAKE_OBJECTIVE_CFLAGS += $$QMAKE_CFLAGS
!host_build: QMAKE_CXXFLAGS += $$QMAKE_CFLAGS
diff --git a/depends/patches/qt/mingw-uuidof.patch b/depends/patches/qt/mingw-uuidof.patch
deleted file mode 100644
index fb21923c8c..0000000000
--- a/depends/patches/qt/mingw-uuidof.patch
+++ /dev/null
@@ -1,44 +0,0 @@
---- old/qtbase/src/plugins/platforms/windows/qwindowscontext.cpp
-+++ new/qtbase/src/plugins/platforms/windows/qwindowscontext.cpp
-@@ -77,7 +77,7 @@
- #include <stdlib.h>
- #include <stdio.h>
- #include <windowsx.h>
--#ifndef Q_OS_WINCE
-+#if !defined(Q_OS_WINCE) && (!defined(USE___UUIDOF) || (defined(USE___UUIDOF) && USE___UUIDOF == 1))
- # include <comdef.h>
- #endif
-
-@@ -814,7 +814,7 @@
- HWND_MESSAGE, NULL, static_cast<HINSTANCE>(GetModuleHandle(0)), NULL);
- }
-
--#ifndef Q_OS_WINCE
-+#if !defined(Q_OS_WINCE) && (!defined(USE___UUIDOF) || (defined(USE___UUIDOF) && USE___UUIDOF == 1))
- // Re-engineered from the inline function _com_error::ErrorMessage().
- // We cannot use it directly since it uses swprintf_s(), which is not
- // present in the MSVCRT.DLL found on Windows XP (QTBUG-35617).
-@@ -833,7 +833,7 @@
- return QString::asprintf("IDispatch error #%u", uint(wCode));
- return QString::asprintf("Unknown error 0x0%x", uint(comError.Error()));
- }
--#endif // !Q_OS_WINCE
-+#endif // !defined(Q_OS_WINCE) && (!defined(USE___UUIDOF) || (defined(USE___UUIDOF) && USE___UUIDOF == 1))
-
- /*!
- \brief Common COM error strings.
-@@ -901,12 +901,12 @@
- default:
- break;
- }
--#ifndef Q_OS_WINCE
-+#if !defined(Q_OS_WINCE) && (!defined(USE___UUIDOF) || (defined(USE___UUIDOF) && USE___UUIDOF == 1))
- _com_error error(hr);
- result += QByteArrayLiteral(" (");
- result += errorMessageFromComError(error);
- result += ')';
--#endif // !Q_OS_WINCE
-+#endif // !defined(Q_OS_WINCE) && (!defined(USE___UUIDOF) || (defined(USE___UUIDOF) && USE___UUIDOF == 1))
- return result;
- }
-
diff --git a/depends/patches/qt/pidlist_absolute.patch b/depends/patches/qt/pidlist_absolute.patch
deleted file mode 100644
index c792824179..0000000000
--- a/depends/patches/qt/pidlist_absolute.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-diff -dur old/qtbase/src/plugins/platforms/windows/qwindowscontext.h new/qtbase/src/plugins/platforms/windows/qwindowscontext.h
---- old/qtbase/src/plugins/platforms/windows/qwindowscontext.h
-+++ new/qtbase/src/plugins/platforms/windows/qwindowscontext.h
-@@ -136,10 +136,18 @@
- inline void init();
-
- typedef HRESULT (WINAPI *SHCreateItemFromParsingName)(PCWSTR, IBindCtx *, const GUID&, void **);
-+#if defined(Q_CC_MINGW) && (!defined(__MINGW64_VERSION_MAJOR) || __MINGW64_VERSION_MAJOR < 3)
-+ typedef HRESULT (WINAPI *SHGetKnownFolderIDList)(const GUID &, DWORD, HANDLE, ITEMIDLIST **);
-+#else
- typedef HRESULT (WINAPI *SHGetKnownFolderIDList)(const GUID &, DWORD, HANDLE, PIDLIST_ABSOLUTE *);
-+#endif
- typedef HRESULT (WINAPI *SHGetStockIconInfo)(int , int , _SHSTOCKICONINFO *);
- typedef HRESULT (WINAPI *SHGetImageList)(int, REFIID , void **);
-+#if defined(Q_CC_MINGW) && (!defined(__MINGW64_VERSION_MAJOR) || __MINGW64_VERSION_MAJOR < 3)
-+ typedef HRESULT (WINAPI *SHCreateItemFromIDList)(const ITEMIDLIST *, REFIID, void **);
-+#else
- typedef HRESULT (WINAPI *SHCreateItemFromIDList)(PCIDLIST_ABSOLUTE, REFIID, void **);
-+#endif
-
- SHCreateItemFromParsingName sHCreateItemFromParsingName;
- SHGetKnownFolderIDList sHGetKnownFolderIDList;
-diff -dur old/qtbase/src/plugins/platforms/windows/qwindowsdialoghelpers.cpp new/qtbase/src/plugins/platforms/windows/qwindowsdialoghelpers.cpp
---- old/qtbase/src/plugins/platforms/windows/qwindowsdialoghelpers.cpp
-+++ new/qtbase/src/plugins/platforms/windows/qwindowsdialoghelpers.cpp
-@@ -1016,7 +1016,11 @@
- qWarning() << __FUNCTION__ << ": Invalid CLSID: " << url.path();
- return Q_NULLPTR;
- }
-+#if defined(Q_CC_MINGW) && (!defined(__MINGW64_VERSION_MAJOR) || __MINGW64_VERSION_MAJOR < 3)
-+ ITEMIDLIST *idList;
-+#else
- PIDLIST_ABSOLUTE idList;
-+#endif
- HRESULT hr = QWindowsContext::shell32dll.sHGetKnownFolderIDList(uuid, 0, 0, &idList);
- if (FAILED(hr)) {
- qErrnoWarning("%s: SHGetKnownFolderIDList(%s)) failed", __FUNCTION__, qPrintable(url.toString()));
diff --git a/depends/patches/qt/qfixed-coretext.patch b/depends/patches/qt/qfixed-coretext.patch
deleted file mode 100644
index aa56f1e1de..0000000000
--- a/depends/patches/qt/qfixed-coretext.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From dbdd5f0ffbce52c8b789ed09f1aa3f1da6c02e23 Mon Sep 17 00:00:00 2001
-From: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
-Date: Fri, 30 Mar 2018 11:58:16 -0700
-Subject: [PATCH] QCoreTextFontEngine: Fix build with Xcode 9.3
-
-Apple LLVM version 9.1.0 (clang-902.0.39.1)
-
-Error message:
-
-.../qfontengine_coretext.mm:827:20: error: qualified reference to
- 'QFixed' is a constructor name rather than a type in this context
- return QFixed::QFixed(int(CTFontGetUnitsPerEm(ctfont)));
-
-Change-Id: Iebe26b3b087a16b10664208fc8851cbddb47f043
-Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
----
- src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git old/qtbase/src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm new/qtbase/src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm
-index 25ff69d877d..98b753eff96 100644
---- old/qtbase/src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm
-+++ new/qtbase/src/platformsupport/fontdatabases/mac/qfontengine_coretext.mm
-@@ -824,7 +824,7 @@ void QCoreTextFontEngine::getUnscaledGlyph(glyph_t glyph, QPainterPath *path, gl
-
- QFixed QCoreTextFontEngine::emSquareSize() const
- {
-- return QFixed::QFixed(int(CTFontGetUnitsPerEm(ctfont)));
-+ return QFixed(int(CTFontGetUnitsPerEm(ctfont)));
- }
-
- QFontEngine *QCoreTextFontEngine::cloneWithSize(qreal pixelSize) const
---
-2.16.3 \ No newline at end of file