diff options
author | Martchus | 2017-02-09 21:00:00 +0100 |
---|---|---|
committer | Martchus | 2017-02-09 21:00:00 +0100 |
commit | 017bc5699e8507491c2acbe88d0fd51185422c11 (patch) | |
tree | 13b401ebe2f19ba3c953534dbb1afa4c8f23b2a5 | |
parent | d5440cf4c6f5db8ea6794b1bdc895ceb9bc55efc (diff) | |
download | aur-017bc5699e8507491c2acbe88d0fd51185422c11.tar.gz |
Update to 5.8.0
42 files changed, 1088 insertions, 780 deletions
@@ -1,13 +1,12 @@ # Generated by mksrcinfo v8 -# Sat Dec 24 12:03:51 UTC 2016 +# Thu Feb 9 19:59:58 UTC 2017 pkgbase = mingw-w64-qt5-base pkgdesc = A cross-platform application and UI framework (mingw-w64) - pkgver = 5.7.1 + pkgver = 5.8.0 pkgrel = 1 url = https://www.qt.io/ arch = i686 arch = x86_64 - groups = mingw-w64-qt groups = mingw-w64-qt5 license = GPL3 license = LGPL3 @@ -32,21 +31,21 @@ pkgbase = mingw-w64-qt5-base options = !buildflags options = staticlibs options = !emptydirs - source = https://download.qt.io/official_releases/qt/5.7/5.7.1/submodules/qtbase-opensource-src-5.7.1.tar.xz - source = 0001-Fix-qwindows-plugin-linking-with-system-freetype.patch - source = 0002-Fix-oci-config-test-on-windows.patch - source = 0003-Don-t-set-QT_NO_SYSTEMSEMAPHORE-for-Windows.patch - source = 0004-Fix-building-mysql-driver-under-mingw.patch - source = 0005-Support-ANGLE-switches-via-configure-shell-script.patch - source = 0006-Use-external-ANGLE-library.patch - source = 0007-Fix-too-many-sections-assemler-error-in-OpenGL-facto.patch - source = 0008-Make-sure-.pc-files-are-installed-correctly.patch - source = 0009-Don-t-add-resource-files-to-LIBS-parameter.patch - source = 0010-Prevent-debug-library-names-in-pkg-config-files.patch - source = 0011-Fix-linking-against-static-D-Bus.patch - source = 0012-Adjust-win32-g-mkspecs-profile.patch - source = 0013-Fix-linking-against-external-harfbuzz.patch - source = 0014-Fix-linking-against-static-pcre.patch + source = https://download.qt.io/official_releases/qt/5.8/5.8.0/submodules/qtbase-opensource-src-5.8.0.tar.xz + source = 0001-Add-profile-for-cross-compilation-with-mingw-w64.patch + source = 0002-Ensure-GLdouble-is-defined-when-using-dynamic-OpenGL.patch + source = 0003-Use-external-ANGLE-library.patch + source = 0004-Fix-too-many-sections-assemler-error-in-OpenGL-facto.patch + source = 0005-Make-sure-.pc-files-are-installed-correctly.patch + source = 0006-Don-t-add-resource-files-to-LIBS-parameter.patch + source = 0007-Prevent-debug-library-names-in-pkg-config-files.patch + source = 0008-Fix-linking-against-shared-static-libpng.patch + source = 0009-Fix-linking-against-static-D-Bus.patch + source = 0010-Fix-linking-against-static-freetype2.patch + source = 0011-Fix-linking-against-static-harfbuzz.patch + source = 0012-Fix-linking-against-static-pcre.patch + source = 0013-Fix-linking-against-shared-static-MariaDB.patch + source = 0014-Fix-linking-against-shared-static-PostgreSQL.patch source = 0015-Rename-qtmain-to-qt5main.patch source = 0016-Build-dynamic-host-libraries.patch source = 0017-Enable-rpath-for-build-tools.patch @@ -56,86 +55,44 @@ pkgbase = mingw-w64-qt5-base source = 0021-Merge-shared-and-static-library-trees.patch source = 0022-Allow-usage-of-static-version-with-CMake.patch source = 0023-Use-correct-pkg-config-static-flag.patch - source = 0024-Use-shared-static-version-of-MariaDB.patch - source = 0025-Use-shared-static-version-of-PostgreSQL.patch - source = 0001-Fix-qwindows-plugin-linking-with-system-freetype.patch - source = 0002-Fix-oci-config-test-on-windows.patch - source = 0003-Don-t-set-QT_NO_SYSTEMSEMAPHORE-for-Windows.patch - source = 0004-Fix-building-mysql-driver-under-mingw.patch - source = 0005-Support-ANGLE-switches-via-configure-shell-script.patch - source = 0006-Use-external-ANGLE-library.patch - source = 0007-Fix-too-many-sections-assemler-error-in-OpenGL-facto.patch - source = 0008-Make-sure-.pc-files-are-installed-correctly.patch - source = 0009-Don-t-add-resource-files-to-LIBS-parameter.patch - source = 0010-Prevent-debug-library-names-in-pkg-config-files.patch - source = 0011-Fix-linking-against-static-D-Bus.patch - source = 0012-Adjust-win32-g-mkspecs-profile.patch - source = 0013-Fix-linking-against-external-harfbuzz.patch - source = 0014-Fix-linking-against-static-pcre.patch - source = 0015-Rename-qtmain-to-qt5main.patch - source = 0016-Build-dynamic-host-libraries.patch - source = 0017-Enable-rpath-for-build-tools.patch - source = 0018-Use-system-zlib-for-build-tools.patch - source = 0019-Disable-determing-default-include-and-lib-dirs-at-qm.patch - source = 0020-Use-.dll.a-as-import-lib-extension.patch - source = 0021-Merge-shared-and-static-library-trees.patch - source = 0022-Allow-usage-of-static-version-with-CMake.patch - source = 0023-Use-correct-pkg-config-static-flag.patch - source = 0024-Use-shared-static-version-of-MariaDB.patch - source = 0025-Use-shared-static-version-of-PostgreSQL.patch - source = 0026-Fix-qt5_wrap_ui-macro.patch - md5sums = f0809befe04160fbb73bbf38a06a2073 - md5sums = 14ea9353fcc9234a9c7cb98ef14050a3 - md5sums = 34c9df86a43132f58b18bd3061305b36 - md5sums = 94f3ec6cdb456cc9b0535bd549cf2859 - md5sums = eb118e7a01ff8e39f608e715758ac3dd - md5sums = c5184ae70974aaeaf5e1996dc7af6ec0 - md5sums = 917a3439afa97afab1b0b722082d640b - md5sums = bea9eb1a5be8e5e1ee2592007b112fe5 - md5sums = 281a81a7c32cc2f4bfeb83f5bea29d59 - md5sums = ec262ef6bcf2f12832f83aad30d2f728 - md5sums = 10c24aec6ca3743d01ca7e0f2704b024 - md5sums = bfa3574a0d44f831e412befba235b2ca - md5sums = 366b8209ba35b00e2fe4ddcf448ed015 - md5sums = 0c17f618cbee73a49d7829da7c816cd7 - md5sums = 11f26a2237acd5e78d5a3db4de2d6d90 - md5sums = 632765f81a4b72b540376255a10b4c2e - md5sums = 1f57d40dc492822f2e931bdd3a0b7435 - md5sums = 758afe3653d7ce126ebae03e6a8f222f - md5sums = d616bd0fd1ac1ae0d749f93fcba0aeb1 - md5sums = 6847671b013c249aaa2dd7d7e646e4e6 - md5sums = 9e3c6cee969a55b15558f6a46f7aad20 - md5sums = 7bf4cf112551bea4c4d3dd91ed7e1461 - md5sums = 97ece0bb54a249aa0a1fc662eedc93de - md5sums = 4bdbf113772fdfe4cc6da53c866216b2 - md5sums = 399555789f729477d65861179efaf9e3 - md5sums = 295d83b50278474289727dc49a688e95 - md5sums = 14ea9353fcc9234a9c7cb98ef14050a3 - md5sums = 34c9df86a43132f58b18bd3061305b36 - md5sums = 94f3ec6cdb456cc9b0535bd549cf2859 - md5sums = eb118e7a01ff8e39f608e715758ac3dd - md5sums = c5184ae70974aaeaf5e1996dc7af6ec0 - md5sums = 917a3439afa97afab1b0b722082d640b - md5sums = bea9eb1a5be8e5e1ee2592007b112fe5 - md5sums = 281a81a7c32cc2f4bfeb83f5bea29d59 - md5sums = ec262ef6bcf2f12832f83aad30d2f728 - md5sums = 10c24aec6ca3743d01ca7e0f2704b024 - md5sums = bfa3574a0d44f831e412befba235b2ca - md5sums = 366b8209ba35b00e2fe4ddcf448ed015 - md5sums = 0c17f618cbee73a49d7829da7c816cd7 - md5sums = 11f26a2237acd5e78d5a3db4de2d6d90 - md5sums = 632765f81a4b72b540376255a10b4c2e - md5sums = 1f57d40dc492822f2e931bdd3a0b7435 - md5sums = 758afe3653d7ce126ebae03e6a8f222f - md5sums = d616bd0fd1ac1ae0d749f93fcba0aeb1 - md5sums = 6847671b013c249aaa2dd7d7e646e4e6 - md5sums = 9e3c6cee969a55b15558f6a46f7aad20 - md5sums = 7bf4cf112551bea4c4d3dd91ed7e1461 - md5sums = 97ece0bb54a249aa0a1fc662eedc93de - md5sums = 4bdbf113772fdfe4cc6da53c866216b2 - md5sums = 399555789f729477d65861179efaf9e3 - md5sums = 295d83b50278474289727dc49a688e95 - md5sums = 541413adc439b0650ad236f13c47e28e + source = 0024-Fix-qt5_wrap_ui-macro.patch + source = 0025-Ignore-errors-about-missing-feature-static.patch + source = 0026-Enable-anf-fix-use-of-iconv.patch + source = 0027-Ignore-failing-pkg-config-test.patch + source = 0028-Include-uiviewsettingsinterop.h-correctly.patch + source = 0029-Hardcode-linker-flags-for-libqwindows.dll.patch + source = 0030-Prevent-qmake-from-messing-static-lib-dependencies.patch + md5sums = 6e1f7f6fb6333eb66e563b175c4e87e9 + md5sums = 4870da8aa8e01334f0daf09be09e7f32 + md5sums = e86ad52f472a4c4a70f9061b5474b947 + md5sums = 4c7c1df53c99182e296932d8cf398c5f + md5sums = d18a5d3fc8570b03aed954a72b68739a + md5sums = 685860a2ac1410c49ab82648bc24f510 + md5sums = e1a1ca7caf93e8033a1915af457b7b98 + md5sums = bd7c1c99dca91ed604c84cf9632f7e0d + md5sums = 7fbfcbb581e07563ab87e17c33a6b48b + md5sums = df541beb0bc0cc8054aae93f462c5923 + md5sums = 4711804aaf43ec810e70898c32948237 + md5sums = 3d4294c3279e69864fcdf87b6f852122 + md5sums = 55c3593dc03079c794e97ed88136845b + md5sums = 5d04636091f7768b940d090178997384 + md5sums = d4cc6c6394c795a2e6708e797e49b616 + md5sums = 8e234c3b077a8f942ee9a7e8209bfc79 + md5sums = 6685fe994d64f3e1b2a4bfe6a645bb6a + md5sums = a0fa368726934c21d3a0e8a5a61023c9 + md5sums = 3dc9e1efaed892d0eb24dfa68769d0f2 + md5sums = 53c06c4a646a9572b40982c4e29b5ce4 + md5sums = 61f4848e9e0a8a6e183458c871070a53 + md5sums = fd2e8c22fdbb3f9415ee500bde5980fc + md5sums = 6a7539edc09f66bae5dfad7e3d210614 + md5sums = 440f7d221985abcb781a519d1bc26ee7 + md5sums = 504e6a091aa8b35a5b6b5a8c77b7d4e3 + md5sums = e85f6106f31bcd8da1213f670575941a + md5sums = 4046dcb53c3a6c735f6d7d4b866d80a0 + md5sums = c964ad83bff270380aa5ac0991e57c10 + md5sums = 3921c665e46cbe39e012432db704089d + md5sums = 8f47783a83f54c82650502a120af4f16 + md5sums = 2bc5f6f3d2c1cd0e2590a8e8e1cf0ff1 pkgname = mingw-w64-qt5-base diff --git a/0001-Add-profile-for-cross-compilation-with-mingw-w64.patch b/0001-Add-profile-for-cross-compilation-with-mingw-w64.patch new file mode 100644 index 000000000000..028bc5cfef8c --- /dev/null +++ b/0001-Add-profile-for-cross-compilation-with-mingw-w64.patch @@ -0,0 +1,307 @@ +From eb3e8004e4cb74f021294e1e57dd268af001980e Mon Sep 17 00:00:00 2001 +From: Martchus <martchus@gmx.net> +Date: Fri, 3 Feb 2017 18:30:51 +0100 +Subject: [PATCH 01/30] Add profile for cross compilation with mingw-w64 + +--- + mkspecs/mingw-w64-g++/qmake.conf | 125 +++++++++++++++++++++++++++ + mkspecs/mingw-w64-g++/qplatformdefs.h | 155 ++++++++++++++++++++++++++++++++++ + 2 files changed, 280 insertions(+) + create mode 100644 mkspecs/mingw-w64-g++/qmake.conf + create mode 100644 mkspecs/mingw-w64-g++/qplatformdefs.h + +diff --git a/mkspecs/mingw-w64-g++/qmake.conf b/mkspecs/mingw-w64-g++/qmake.conf +new file mode 100644 +index 0000000000..6f21ae75d5 +--- /dev/null ++++ b/mkspecs/mingw-w64-g++/qmake.conf +@@ -0,0 +1,125 @@ ++# ++# qmake configuration for i686-w64-mingw32-g++ and x86_64-w64-mingw32-g++ ++# ++# Written for cross compilation with mingw-w64 under GNU/Linux ++# ++# Cross compile example for i686-w64-mingw32-g++: ++# configure -xplatform mingw-w64-g++ -device-option CROSS_COMPILE=i686-w64-mingw32- ++# ++ ++load(device_config) ++include(../common/angle.conf) ++ ++MAKEFILE_GENERATOR = MINGW ++QMAKE_PLATFORM = win32 win32-g++ mingw ++CONFIG += debug_and_release debug_and_release_target precompile_header ++DEFINES += UNICODE ++QMAKE_COMPILER_DEFINES += __GNUC__ WIN32 ++ ++QMAKE_EXT_OBJ = .o ++QMAKE_EXT_RES = _res.o ++ ++QMAKE_COMPILER = gcc ++ ++QMAKE_CC = $${CROSS_COMPILE}gcc ++QMAKE_LEX = flex ++QMAKE_LEXFLAGS = ++QMAKE_YACC = bison -y ++QMAKE_YACCFLAGS = -d ++QMAKE_CFLAGS = -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4 -fno-keep-inline-dllexport $${CROSS_COMPILE_CFLAGS} ++QMAKE_CFLAGS_DEPS = -M ++QMAKE_CFLAGS_WARN_ON = -Wall -Wextra ++QMAKE_CFLAGS_WARN_OFF = -w ++QMAKE_CFLAGS_RELEASE = -O2 ++QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO = -O2 -g ++QMAKE_CFLAGS_DEBUG = -g ++QMAKE_CFLAGS_YACC = -Wno-unused -Wno-parentheses ++QMAKE_CFLAGS_SPLIT_SECTIONS = -ffunction-sections ++QMAKE_CFLAGS_SSE2 = -msse2 -mstackrealign ++QMAKE_CFLAGS_SSE3 = -msse3 ++QMAKE_CFLAGS_SSSE3 = -mssse3 ++QMAKE_CFLAGS_SSE4_1 = -msse4.1 ++QMAKE_CFLAGS_SSE4_2 = -msse4.2 ++QMAKE_CFLAGS_AVX = -mavx ++QMAKE_CFLAGS_AVX2 = -mavx2 ++QMAKE_CFLAGS_NEON = -mfpu=neon ++ ++QMAKE_CXX = $${CROSS_COMPILE}g++ ++QMAKE_CXXFLAGS = $$QMAKE_CFLAGS ++QMAKE_CXXFLAGS_DEPS = $$QMAKE_CFLAGS_DEPS ++QMAKE_CXXFLAGS_WARN_ON = $$QMAKE_CFLAGS_WARN_ON ++QMAKE_CXXFLAGS_WARN_OFF = $$QMAKE_CFLAGS_WARN_OFF ++QMAKE_CXXFLAGS_RELEASE = $$QMAKE_CFLAGS_RELEASE ++QMAKE_CXXFLAGS_RELEASE_WITH_DEBUGINFO = $$QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO ++QMAKE_CXXFLAGS_DEBUG = $$QMAKE_CFLAGS_DEBUG ++QMAKE_CXXFLAGS_YACC = $$QMAKE_CFLAGS_YACC ++QMAKE_CXXFLAGS_THREAD = $$QMAKE_CFLAGS_THREAD ++QMAKE_CXXFLAGS_RTTI_ON = -frtti ++QMAKE_CXXFLAGS_RTTI_OFF = -fno-rtti ++QMAKE_CXXFLAGS_EXCEPTIONS_ON = -fexceptions -mthreads ++QMAKE_CXXFLAGS_EXCEPTIONS_OFF = -fno-exceptions ++QMAKE_CXXFLAGS_CXX11 = -std=c++11 ++QMAKE_CXXFLAGS_CXX14 = -std=c++1y ++QMAKE_CXXFLAGS_CXX1Z = -std=c++1z ++QMAKE_CXXFLAGS_GNUCXX11 = -std=gnu++11 ++QMAKE_CXXFLAGS_GNUCXX14 = -std=gnu++1y ++QMAKE_CXXFLAGS_GNUCXX1Z = -std=gnu++1z ++QMAKE_CXXFLAGS_SPLIT_SECTIONS = $$QMAKE_CFLAGS_SPLIT_SECTIONS ++ ++QMAKE_INCDIR = ++ ++QMAKE_RUN_CC = $(CC) -c $(CFLAGS) $(INCPATH) -o $obj $src ++QMAKE_RUN_CC_IMP = $(CC) -c $(CFLAGS) $(INCPATH) -o $@ $< ++QMAKE_RUN_CXX = $(CXX) -c $(CXXFLAGS) $(INCPATH) -o $obj $src ++QMAKE_RUN_CXX_IMP = $(CXX) -c $(CXXFLAGS) $(INCPATH) -o $@ $< ++ ++QMAKE_LINK = $${CROSS_COMPILE}g++ ++QMAKE_LINK_C = $${CROSS_COMPILE}gcc ++QMAKE_LFLAGS = -g ++QMAKE_LFLAGS_EXCEPTIONS_ON = -mthreads ++QMAKE_LFLAGS_EXCEPTIONS_OFF = ++QMAKE_LFLAGS_RELEASE = ++QMAKE_LFLAGS_DEBUG = ++QMAKE_LFLAGS_CONSOLE = -Wl,-subsystem,console ++QMAKE_LFLAGS_WINDOWS = -Wl,-subsystem,windows ++QMAKE_LFLAGS_DLL = -shared ++QMAKE_LFLAGS_CXX11 = ++QMAKE_LFLAGS_CXX14 = ++QMAKE_LFLAGS_CXX1Z = ++QMAKE_LFLAGS_GCSECTIONS = -Wl,--gc-sections ++QMAKE_LINK_OBJECT_MAX = 10 ++QMAKE_LINK_OBJECT_SCRIPT = object_script ++QMAKE_PREFIX_SHLIB = ++QMAKE_EXTENSION_SHLIB = dll ++QMAKE_PREFIX_STATICLIB = lib ++QMAKE_EXTENSION_STATICLIB = a ++QMAKE_EXTENSION_IMPORTLIB = dll.a ++ ++QMAKE_IDL = $${CROSS_COMPILE}widl ++QMAKE_LIB = $${CROSS_COMPILE}ar -rc ++QMAKE_RC = $${CROSS_COMPILE}windres ++QMAKE_DLLTOOL = $${CROSS_COMPILE}dlltool ++QMAKE_LRELEASE = $${CROSS_COMPILE}lrelease-qt5 ++ ++QMAKE_STRIP = $${CROSS_COMPILE}strip ++QMAKE_STRIPFLAGS_LIB += --strip-unneeded ++QMAKE_OBJCOPY = $${CROSS_COMPILE}objcopy ++QMAKE_NM = $${CROSS_COMPILE}nm -P ++ ++PKG_CONFIG = $${CROSS_COMPILE}pkg-config ++QMAKE_PKG_CONFIG = $${CROSS_COMPILE}pkg-config ++ ++QMAKE_LIBS = ++QMAKE_LIBS_CORE = -lole32 -luuid -lwinmm -lws2_32 -ladvapi32 -lshell32 -luser32 -lkernel32 -lz -lpcre16 ++QMAKE_LIBS_GUI = -lgdi32 -lcomdlg32 -loleaut32 -limm32 -lwinmm -lws2_32 -lole32 -luuid -luser32 -ladvapi32 -ljpeg -lpng \ ++ $$system($${QMAKE_PKG_CONFIG} --static --libs harfbuzz) \ ++ $$system($${QMAKE_PKG_CONFIG} --static --libs freetype2) ++QMAKE_LIBS_NETWORK = -lws2_32 -lcrypt32 -ldnsapi ++QMAKE_LIBS_DBUS = $$system($${QMAKE_PKG_CONFIG} --static --libs dbus-1) ++QMAKE_LIBS_OPENGL = -lglu32 -lopengl32 -lgdi32 -luser32 ++QMAKE_LIBS_OPENGL_ES2 = -l$${LIBEGL_NAME} -l$${LIBGLESV2_NAME} -ld3d9 -ldxguid -lgdi32 -luser32 ++QMAKE_LIBS_OPENGL_ES2_DEBUG = -l$${LIBEGL_NAME} -l$${LIBGLESV2_NAME} -ld3d9 -ldxguid -lgdi32 -luser32 ++QMAKE_LIBS_COMPAT = -ladvapi32 -lshell32 -lcomdlg32 -luser32 -lgdi32 -lws2_32 ++QMAKE_LIBS_QT_ENTRY = -lmingw32 -lqt5main ++ ++load(qt_config) +diff --git a/mkspecs/mingw-w64-g++/qplatformdefs.h b/mkspecs/mingw-w64-g++/qplatformdefs.h +new file mode 100644 +index 0000000000..c5a70b1445 +--- /dev/null ++++ b/mkspecs/mingw-w64-g++/qplatformdefs.h +@@ -0,0 +1,155 @@ ++/**************************************************************************** ++** ++** Copyright (C) 2016 The Qt Company Ltd. ++** Contact: https://www.qt.io/licensing/ ++** ++** This file is part of the qmake spec of the Qt Toolkit. ++** ++** $QT_BEGIN_LICENSE:LGPL$ ++** Commercial License Usage ++** Licensees holding valid commercial Qt licenses may use this file in ++** accordance with the commercial license agreement provided with the ++** Software or, alternatively, in accordance with the terms contained in ++** a written agreement between you and The Qt Company. For licensing terms ++** and conditions see https://www.qt.io/terms-conditions. For further ++** information use the contact form at https://www.qt.io/contact-us. ++** ++** GNU Lesser General Public License Usage ++** Alternatively, this file may be used under the terms of the GNU Lesser ++** General Public License version 3 as published by the Free Software ++** Foundation and appearing in the file LICENSE.LGPL3 included in the ++** packaging of this file. Please review the following information to ++** ensure the GNU Lesser General Public License version 3 requirements ++** will be met: https://www.gnu.org/licenses/lgpl-3.0.html. ++** ++** GNU General Public License Usage ++** Alternatively, this file may be used under the terms of the GNU ++** General Public License version 2.0 or (at your option) the GNU General ++** Public license version 3 or any later version approved by the KDE Free ++** Qt Foundation. The licenses are as published by the Free Software ++** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3 ++** included in the packaging of this file. Please review the following ++** information to ensure the GNU General Public License requirements will ++** be met: https://www.gnu.org/licenses/gpl-2.0.html and ++** https://www.gnu.org/licenses/gpl-3.0.html. ++** ++** $QT_END_LICENSE$ ++** ++****************************************************************************/ ++ ++#ifndef QPLATFORMDEFS_H ++#define QPLATFORMDEFS_H ++ ++#ifdef UNICODE ++#ifndef _UNICODE ++#define _UNICODE ++#endif ++#endif ++ ++// Get Qt defines/settings ++ ++#include "qglobal.h" ++ ++#include <tchar.h> ++#include <io.h> ++#include <direct.h> ++#include <stdio.h> ++#include <fcntl.h> ++#include <errno.h> ++#include <sys/stat.h> ++#include <stdlib.h> ++#include <limits.h> ++ ++#if !defined(_WIN32_WINNT) || (_WIN32_WINNT-0 < 0x0500) ++typedef enum { ++ NameUnknown = 0, ++ NameFullyQualifiedDN = 1, ++ NameSamCompatible = 2, ++ NameDisplay = 3, ++ NameUniqueId = 6, ++ NameCanonical = 7, ++ NameUserPrincipal = 8, ++ NameCanonicalEx = 9, ++ NameServicePrincipal = 10, ++ NameDnsDomain = 12 ++} EXTENDED_NAME_FORMAT, *PEXTENDED_NAME_FORMAT; ++#endif ++ ++#ifdef QT_LARGEFILE_SUPPORT ++#define QT_STATBUF struct _stati64 // non-ANSI defs ++#define QT_STATBUF4TSTAT struct _stati64 // non-ANSI defs ++#define QT_STAT ::_stati64 ++#define QT_FSTAT ::_fstati64 ++#else ++#define QT_STATBUF struct _stat // non-ANSI defs ++#define QT_STATBUF4TSTAT struct _stat // non-ANSI defs ++#define QT_STAT ::_stat ++#define QT_FSTAT ::_fstat ++#endif ++#define QT_STAT_REG _S_IFREG ++#define QT_STAT_DIR _S_IFDIR ++#define QT_STAT_MASK _S_IFMT ++#if defined(_S_IFLNK) ++# define QT_STAT_LNK _S_IFLNK ++#endif ++#define QT_FILENO _fileno ++#define QT_OPEN ::_open ++#define QT_CLOSE ::_close ++#ifdef QT_LARGEFILE_SUPPORT ++#define QT_LSEEK ::_lseeki64 ++#ifndef UNICODE ++#define QT_TSTAT ::_stati64 ++#else ++#define QT_TSTAT ::_wstati64 ++#endif ++#else ++#define QT_LSEEK ::_lseek ++#ifndef UNICODE ++#define QT_TSTAT ::_stat ++#else ++#define QT_TSTAT ::_wstat ++#endif ++#endif ++#define QT_READ ::_read ++#define QT_WRITE ::_write ++#define QT_ACCESS ::_access ++#define QT_GETCWD ::_getcwd ++#define QT_CHDIR ::_chdir ++#define QT_MKDIR ::_mkdir ++#define QT_RMDIR ::_rmdir ++#define QT_OPEN_LARGEFILE 0 ++#define QT_OPEN_RDONLY _O_RDONLY ++#define QT_OPEN_WRONLY _O_WRONLY ++#define QT_OPEN_RDWR _O_RDWR ++#define QT_OPEN_CREAT _O_CREAT ++#define QT_OPEN_TRUNC _O_TRUNC ++#define QT_OPEN_APPEND _O_APPEND ++#if defined(O_TEXT) ++# define QT_OPEN_TEXT _O_TEXT ++# define QT_OPEN_BINARY _O_BINARY ++#endif ++ ++#include "../common/c89/qplatformdefs.h" ++ ++#ifdef QT_LARGEFILE_SUPPORT ++#undef QT_FSEEK ++#undef QT_FTELL ++#undef QT_OFF_T ++ ++#define QT_FSEEK ::fseeko64 ++#define QT_FTELL ::ftello64 ++#define QT_OFF_T off64_t ++#endif ++ ++#define QT_SIGNAL_ARGS int ++ ++#define QT_VSNPRINTF ::_vsnprintf ++#define QT_SNPRINTF ::_snprintf ++ ++# define F_OK 0 ++# define X_OK 1 ++# define W_OK 2 ++# define R_OK 4 ++ ++ ++#endif // QPLATFORMDEFS_H +-- +2.11.1 + diff --git a/0001-Fix-qwindows-plugin-linking-with-system-freetype.patch b/0001-Fix-qwindows-plugin-linking-with-system-freetype.patch deleted file mode 100644 index 40f1749fdd3e..000000000000 --- a/0001-Fix-qwindows-plugin-linking-with-system-freetype.patch +++ /dev/null @@ -1,22 +0,0 @@ -From 33a70ca96428d1da21de74c5ddcdb1b0a5015687 Mon Sep 17 00:00:00 2001 -From: Mark Brand <mabrand@mabrand.nl> -Date: Thu, 6 Aug 2015 23:35:08 +0200 -Subject: [PATCH 01/26] Fix qwindows plugin linking with system-freetype - ---- - src/3rdparty/freetype_dependency.pri | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/src/3rdparty/freetype_dependency.pri b/src/3rdparty/freetype_dependency.pri -index 39280deb2f..e152b0dedf 100644 ---- a/src/3rdparty/freetype_dependency.pri -+++ b/src/3rdparty/freetype_dependency.pri -@@ -4,4 +4,5 @@ contains(QT_CONFIG, freetype) { - } else:contains(QT_CONFIG, system-freetype) { - # pull in the proper freetype2 include directory - include($$QT_SOURCE_TREE/config.tests/unix/freetype/freetype.pri) -+ win32:shared:LIBS_PRIVATE += -lfreetype - } --- -2.11.0 - diff --git a/0002-Ensure-GLdouble-is-defined-when-using-dynamic-OpenGL.patch b/0002-Ensure-GLdouble-is-defined-when-using-dynamic-OpenGL.patch new file mode 100644 index 000000000000..3f73b4f545f2 --- /dev/null +++ b/0002-Ensure-GLdouble-is-defined-when-using-dynamic-OpenGL.patch @@ -0,0 +1,27 @@ +From 0223c4145ff17cb79e720ed12b24819262aa5353 Mon Sep 17 00:00:00 2001 +From: Martchus <martchus@gmx.net> +Date: Sun, 18 Sep 2016 13:36:53 +0200 +Subject: [PATCH 02/30] Ensure GLdouble is defined when using dynamic OpenGL + +FIXME: Not sure whether this is still required +--- + src/gui/opengl/qopenglfunctions.h | 2 -- + 1 file changed, 2 deletions(-) + +diff --git a/src/gui/opengl/qopenglfunctions.h b/src/gui/opengl/qopenglfunctions.h +index aad48571b3..46f44d8b91 100644 +--- a/src/gui/opengl/qopenglfunctions.h ++++ b/src/gui/opengl/qopenglfunctions.h +@@ -56,9 +56,7 @@ + + //#define Q_ENABLE_OPENGL_FUNCTIONS_DEBUG + +-#ifdef QT_OPENGL_ES + typedef double GLdouble; +-#endif + + #ifdef Q_ENABLE_OPENGL_FUNCTIONS_DEBUG + #include <stdio.h> +-- +2.11.1 + diff --git a/0002-Fix-oci-config-test-on-windows.patch b/0002-Fix-oci-config-test-on-windows.patch deleted file mode 100644 index c46beae96966..000000000000 --- a/0002-Fix-oci-config-test-on-windows.patch +++ /dev/null @@ -1,21 +0,0 @@ -From 46b5449c24017b2965803ed110601ce4800cb470 Mon Sep 17 00:00:00 2001 -From: Mark Brand <mabrand@mabrand.nl> -Date: Mon, 8 Dec 2014 14:15:12 +0100 -Subject: [PATCH 02/26] Fix oci config test on windows - ---- - config.tests/unix/oci/oci.pro | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/config.tests/unix/oci/oci.pro b/config.tests/unix/oci/oci.pro -index 3ffda1ddd7..39b6f37596 100644 ---- a/config.tests/unix/oci/oci.pro -+++ b/config.tests/unix/oci/oci.pro -@@ -1,3 +1,3 @@ - SOURCES = oci.cpp - CONFIG -= qt dylib --LIBS += -lclntsh -+!win32:LIBS += -lclntsh --- -2.11.0 - diff --git a/0003-Don-t-set-QT_NO_SYSTEMSEMAPHORE-for-Windows.patch b/0003-Don-t-set-QT_NO_SYSTEMSEMAPHORE-for-Windows.patch deleted file mode 100644 index 0e37954246e0..000000000000 --- a/0003-Don-t-set-QT_NO_SYSTEMSEMAPHORE-for-Windows.patch +++ /dev/null @@ -1,25 +0,0 @@ -From 7f9c28d0bd3a4b89ea5ecb44e38c4b0aabcc0026 Mon Sep 17 00:00:00 2001 -From: Mark Brand <mabrand@mabrand.nl> -Date: Thu, 6 Aug 2015 13:24:56 +0200 -Subject: [PATCH 03/26] Don't set QT_NO_SYSTEMSEMAPHORE for Windows - ---- - configure | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/configure b/configure -index ba94d08714..50e6dfbce6 100755 ---- a/configure -+++ b/configure -@@ -4677,7 +4677,7 @@ fi - [ "$XPLATFORM_ANDROID" != "no" ] && QMakeVar add styles "android" - - # check IPC support --if ! compileTest unix/ipc_sysv "ipc_sysv" ; then -+if [ "$XPLATFORM_MINGW" = "no" ] && ! compileTest unix/ipc_sysv "ipc_sysv" ; then - # SYSV IPC is not supported - check POSIX IPC - if compileTest unix/ipc_posix "ipc_posix" ; then - QCONFIG_FLAGS="$QCONFIG_FLAGS QT_POSIX_IPC" --- -2.11.0 - diff --git a/0006-Use-external-ANGLE-library.patch b/0003-Use-external-ANGLE-library.patch index 08e22ce775ce..d7131af6ca40 100644 --- a/0006-Use-external-ANGLE-library.patch +++ b/0003-Use-external-ANGLE-library.patch @@ -1,15 +1,15 @@ -From 22922f121b3dc7865b7d0c553ed033dca700cc74 Mon Sep 17 00:00:00 2001 +From 1ffc87d8805a92fb7666084c656bac46cd276599 Mon Sep 17 00:00:00 2001 From: Martchus <martchus@gmx.net> Date: Sun, 18 Sep 2016 13:41:38 +0200 -Subject: [PATCH 06/26] Use external ANGLE library +Subject: [PATCH 03/30] Use external ANGLE library --- src/gui/Qt5GuiConfigExtras.cmake.in | 4 ++-- - src/gui/gui.pro | 9 ++++----- + src/gui/gui.pro | 8 ++------ src/opengl/opengl.pro | 1 + src/plugins/platforms/windows/windows.pri | 1 + src/src.pro | 4 ---- - 5 files changed, 8 insertions(+), 11 deletions(-) + 5 files changed, 6 insertions(+), 12 deletions(-) diff --git a/src/gui/Qt5GuiConfigExtras.cmake.in b/src/gui/Qt5GuiConfigExtras.cmake.in index 07869efd7d..2e32911a64 100644 @@ -28,71 +28,70 @@ index 07869efd7d..2e32911a64 100644 _qt5_Gui_check_file_exists(${Qt5Gui_EGL_INCLUDE_DIRS}) diff --git a/src/gui/gui.pro b/src/gui/gui.pro -index 462f133ff8..db30dd3440 100644 +index 5f8cbe2cbe..0ebf6b7281 100644 --- a/src/gui/gui.pro +++ b/src/gui/gui.pro -@@ -17,11 +17,6 @@ MODULE_PLUGIN_TYPES = \ +@@ -18,12 +18,6 @@ MODULE_PLUGIN_TYPES = \ imageformats \ egldeviceintegrations -# This is here only because the platform plugin is no module, obviously. --win32:contains(QT_CONFIG, angle)|contains(QT_CONFIG, dynamicgl) { +-qtConfig(angle) { - MODULE_AUX_INCLUDES = \ - \$\$QT_MODULE_INCLUDE_BASE/QtANGLE -} - +- # Code coverage with TestCocoon # The following is required as extra compilers use $$QMAKE_CXX instead of $(CXX). -@@ -33,6 +28,10 @@ testcocoon { + # Without this, testcocoon.prf is read only after $$QMAKE_CXX is used by the +@@ -34,6 +28,8 @@ testcocoon { osx: LIBS_PRIVATE += -framework AppKit -+win32:contains(QT_CONFIG, angle) { -+ LIBS_PRIVATE += -lGLESv2 -+} ++win32:qtConfig(angle): LIBS_PRIVATE += -lGLESv2 + CONFIG += simd optimize_full include(accessible/accessible.pri) diff --git a/src/opengl/opengl.pro b/src/opengl/opengl.pro -index 2386ef5d19..fe3b327f13 100644 +index 718a886809..89965709ed 100644 --- a/src/opengl/opengl.pro +++ b/src/opengl/opengl.pro @@ -11,6 +11,7 @@ QMAKE_DOCS = $$PWD/doc/qtopengl.qdocconf - contains(QT_CONFIG, opengl):CONFIG += opengl - contains(QT_CONFIG, opengles2):CONFIG += opengles2 -+win32:contains(QT_CONFIG, angle): LIBS_PRIVATE += -lGLESv2 + qtConfig(opengl): CONFIG += opengl + qtConfig(opengles2): CONFIG += opengles2 ++win32:qtConfig(angle): LIBS_PRIVATE += -lGLESv2 HEADERS += qgl.h \ qgl_p.h \ diff --git a/src/plugins/platforms/windows/windows.pri b/src/plugins/platforms/windows/windows.pri -index 48c53592d6..3498dbeaa8 100644 +index 20e0b81da9..b55847fc69 100644 --- a/src/plugins/platforms/windows/windows.pri +++ b/src/plugins/platforms/windows/windows.pri -@@ -3,6 +3,7 @@ LIBS *= -lole32 - !wince: LIBS *= -luser32 -lwinspool -limm32 -lwinmm -loleaut32 +@@ -2,6 +2,7 @@ + LIBS += -lole32 -luser32 -lwinspool -limm32 -lwinmm -loleaut32 - contains(QT_CONFIG, opengl):!contains(QT_CONFIG, opengles2):!contains(QT_CONFIG, dynamicgl): LIBS *= -lopengl32 -+contains(QT_CONFIG, angle):LIBS += -lGLESv2 -lEGL + qtConfig(opengl):!qtConfig(opengles2):!qtConfig(dynamicgl): LIBS *= -lopengl32 ++qtConfig(angle):LIBS += -lGLESv2 -lEGL mingw: LIBS *= -luuid # For the dialog helpers: diff --git a/src/src.pro b/src/src.pro -index 3d185408f8..1e4f93d17d 100644 +index 90d7e2b76c..92e89ea39f 100644 --- a/src/src.pro +++ b/src/src.pro -@@ -163,10 +163,6 @@ contains(QT_CONFIG, concurrent):SUBDIRS += src_concurrent +@@ -160,10 +160,6 @@ qtConfig(gui) { SUBDIRS += src_3rdparty_harfbuzzng src_gui.depends += src_3rdparty_harfbuzzng } -- win32:contains(QT_CONFIG, angle)|contains(QT_CONFIG, dynamicgl) { +- qtConfig(angle) { - SUBDIRS += src_angle - src_gui.depends += src_angle - } - contains(QT_CONFIG, png) { + qtConfig(png):!qtConfig(system-png) { SUBDIRS += src_3rdparty_libpng src_3rdparty_freetype.depends += src_3rdparty_libpng -- -2.11.0 +2.11.1 diff --git a/0004-Fix-building-mysql-driver-under-mingw.patch b/0004-Fix-building-mysql-driver-under-mingw.patch deleted file mode 100644 index 81a3038c3fa9..000000000000 --- a/0004-Fix-building-mysql-driver-under-mingw.patch +++ /dev/null @@ -1,25 +0,0 @@ -From 1188f25bbc6ccd2fce5b080b98862aeb8420fc94 Mon Sep 17 00:00:00 2001 -From: Mark Brand <mabrand@mabrand.nl> -Date: Tue, 6 Oct 2015 09:53:20 +0200 -Subject: [PATCH 04/26] Fix building mysql driver under mingw - ---- - src/sql/drivers/mysql/qsql_mysql.pri | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/sql/drivers/mysql/qsql_mysql.pri b/src/sql/drivers/mysql/qsql_mysql.pri -index 3cfb6144a1..8b7063f1e4 100644 ---- a/src/sql/drivers/mysql/qsql_mysql.pri -+++ b/src/sql/drivers/mysql/qsql_mysql.pri -@@ -4,7 +4,7 @@ SOURCES += $$PWD/qsql_mysql.cpp - QMAKE_CXXFLAGS *= $$QT_CFLAGS_MYSQL - LIBS += $$QT_LFLAGS_MYSQL - --unix { -+if (unix|mingw) { - isEmpty(QT_LFLAGS_MYSQL) { - !contains(LIBS, .*mysqlclient.*):!contains(LIBS, .*mysqld.*) { - use_libmysqlclient_r:LIBS += -lmysqlclient_r --- -2.11.0 - diff --git a/0007-Fix-too-many-sections-assemler-error-in-OpenGL-facto.patch b/0004-Fix-too-many-sections-assemler-error-in-OpenGL-facto.patch index 558f13f13dcc..9ab42c0cc6e0 100644 --- a/0007-Fix-too-many-sections-assemler-error-in-OpenGL-facto.patch +++ b/0004-Fix-too-many-sections-assemler-error-in-OpenGL-facto.patch @@ -1,27 +1,29 @@ -From 73e031e4308c76638e67f7e167df47d3988c7c14 Mon Sep 17 00:00:00 2001 +From 447092efb62e94bc69b3899093e1ee10af18d81b Mon Sep 17 00:00:00 2001 From: Martchus <martchus@gmx.net> Date: Sun, 18 Sep 2016 13:48:51 +0200 -Subject: [PATCH 07/26] Fix too many sections assemler error in OpenGL factory +Subject: [PATCH 04/30] Fix too many sections assemler error in OpenGL factory On x86_64 qopenglversionfunctionsfactory.o exceeds the limit of 32768 sections. Hence the assembler option -mbig-obj is required. --- - src/gui/opengl/opengl.pri | 1 + - 1 file changed, 1 insertion(+) + src/gui/opengl/opengl.pri | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/gui/opengl/opengl.pri b/src/gui/opengl/opengl.pri -index b13f258fda..8a9093f4ca 100644 +index 1a1022b3a7..792bdf9e7a 100644 --- a/src/gui/opengl/opengl.pri +++ b/src/gui/opengl/opengl.pri -@@ -4,6 +4,7 @@ contains(QT_CONFIG, opengl):CONFIG += opengl - contains(QT_CONFIG, opengles2):CONFIG += opengles2 +@@ -3,7 +3,8 @@ + qtConfig(opengl): CONFIG += opengl + qtConfig(opengles2): CONFIG += opengles2 - contains(QT_CONFIG, opengl)|contains(QT_CONFIG, opengles2) { +-qtConfig(opengl) { ++qtConfig(opengl)|qtConfig(opengles2) { + mingw:QMAKE_CXXFLAGS+="-Wa,-mbig-obj" HEADERS += opengl/qopengl.h \ opengl/qopengl_p.h \ -- -2.11.0 +2.11.1 diff --git a/0008-Make-sure-.pc-files-are-installed-correctly.patch b/0005-Make-sure-.pc-files-are-installed-correctly.patch index b4249f905c8e..b2221f58bb0d 100644 --- a/0008-Make-sure-.pc-files-are-installed-correctly.patch +++ b/0005-Make-sure-.pc-files-are-installed-correctly.patch @@ -1,7 +1,7 @@ -From fbd42996783866ecf559aae52d73e2871f207b54 Mon Sep 17 00:00:00 2001 +From 74be1cdb27c34b149b4b227a8c3107ca49cc254a Mon Sep 17 00:00:00 2001 From: Martchus <martchus@gmx.net> Date: Sun, 18 Sep 2016 13:54:12 +0200 -Subject: [PATCH 08/26] Make sure *.pc files are installed correctly +Subject: [PATCH 05/30] Make sure *.pc files are installed correctly --- qmake/generators/makefile.cpp | 8 ++++++-- @@ -10,10 +10,10 @@ Subject: [PATCH 08/26] Make sure *.pc files are installed correctly 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/qmake/generators/makefile.cpp b/qmake/generators/makefile.cpp -index d356adada5..fa5c796387 100644 +index 4450e619b9..182fe79238 100644 --- a/qmake/generators/makefile.cpp +++ b/qmake/generators/makefile.cpp -@@ -3149,7 +3149,7 @@ MakefileGenerator::openOutput(QFile &file, const QString &build) const +@@ -3150,7 +3150,7 @@ MakefileGenerator::openOutput(QFile &file, const QString &build) const } QString @@ -22,7 +22,7 @@ index d356adada5..fa5c796387 100644 { QString ret = project->first("QMAKE_PKGCONFIG_FILE").toQString(); if (ret.isEmpty()) { -@@ -3174,7 +3174,11 @@ MakefileGenerator::pkgConfigFileName(bool fixify) +@@ -3175,7 +3175,11 @@ MakefileGenerator::pkgConfigFileName(bool fixify) if(fixify) { if(QDir::isRelativePath(ret) && !project->isEmpty("DESTDIR")) ret.prepend(project->first("DESTDIR").toQString()); @@ -36,7 +36,7 @@ index d356adada5..fa5c796387 100644 return ret; } diff --git a/qmake/generators/makefile.h b/qmake/generators/makefile.h -index a67a0ec0fc..9ec1abfaa8 100644 +index 86fec748eb..cbe23d7e3a 100644 --- a/qmake/generators/makefile.h +++ b/qmake/generators/makefile.h @@ -89,7 +89,7 @@ protected: @@ -49,10 +49,10 @@ index a67a0ec0fc..9ec1abfaa8 100644 void writePkgConfigFile(); // for pkg-config diff --git a/qmake/generators/win32/winmakefile.cpp b/qmake/generators/win32/winmakefile.cpp -index 0846cb2d8f..543e905051 100644 +index 3c029c8004..caa000ea53 100644 --- a/qmake/generators/win32/winmakefile.cpp +++ b/qmake/generators/win32/winmakefile.cpp -@@ -718,7 +718,7 @@ QString Win32MakefileGenerator::defaultInstall(const QString &t) +@@ -721,7 +721,7 @@ QString Win32MakefileGenerator::defaultInstall(const QString &t) } if(!ret.isEmpty()) ret += "\n\t"; @@ -62,5 +62,5 @@ index 0846cb2d8f..543e905051 100644 uninst.append("\n\t"); uninst.append("-$(DEL_FILE) " + escapeFilePath(dst_pc)); -- -2.11.0 +2.11.1 diff --git a/0005-Support-ANGLE-switches-via-configure-shell-script.patch b/0005-Support-ANGLE-switches-via-configure-shell-script.patch deleted file mode 100644 index 7bb3c6b144eb..000000000000 --- a/0005-Support-ANGLE-switches-via-configure-shell-script.patch +++ /dev/null @@ -1,94 +0,0 @@ -From a40c4d89a09af39c8a9b6e07f99aab277139da28 Mon Sep 17 00:00:00 2001 -From: Martchus <martchus@gmx.net> -Date: Sun, 18 Sep 2016 13:36:53 +0200 -Subject: [PATCH 05/26] Support ANGLE switches via configure shell script - -Required when cross-compiling with mingw-w64 because in -this case executing configure.bat is not appropriate ---- - configure | 26 ++++++++++++++++++++++++-- - src/gui/opengl/qopenglfunctions.h | 2 -- - 2 files changed, 24 insertions(+), 4 deletions(-) - -diff --git a/configure b/configure -index 50e6dfbce6..af275de52c 100755 ---- a/configure -+++ b/configure -@@ -1287,6 +1287,7 @@ while [ "$#" -gt 0 ]; do - ;; - opengl) - if [ "$VAL" = "auto" ] || [ "$VAL" = "desktop" ] || -+ [ "$VAL" = "angle" ] || [ "$VAL" = "dynamic" ] || - [ "$VAL" = "yes" ] || [ "$VAL" = "no" ] || - [ "$VAL" = "es2" ]; then - CFG_OPENGL="$VAL" -@@ -5320,7 +5321,7 @@ if [ "$XPLATFORM_MINGW" = "yes" ]; then - fi - if [ "$CFG_OPENGL" = "auto" ] || [ "$CFG_OPENGL" = "yes" ]; then - if compileTest x11/opengl "OpenGL"; then -- CFG_OPENGL=desktop -+ CFG_OPENGL=angle - elif compileTest unix/opengles2 "OpenGL ES 2.0"; then - CFG_OPENGL=es2 - else -@@ -5356,6 +5357,17 @@ if [ "$XPLATFORM_MINGW" = "yes" ]; then - echo " ${XQMAKESPEC}." - exit 1 - fi -+ elif [ "$CFG_OPENGL" = "angle" ]; then -+ compileTest x11/opengl "OpenGL" -+ if [ $? != "0" ]; then -+ echo "The OpenGL functionality test failed!" -+ echo " You might need to modify the include and library search paths by editing" -+ echo " QMAKE_INCDIR_OPENGL, QMAKE_LIBDIR_OPENGL and QMAKE_LIBS_OPENGL in" -+ echo " ${XQMAKESPEC}." -+ exit 1 -+ fi -+ elif [ "$CFG_OPENGL" = "dynamic" ]; then -+ true # FIXME: not sure whether/which test required - elif [ "$CFG_OPENGL" = "desktop" ]; then - # Desktop OpenGL support - compileTest x11/opengl "OpenGL" -@@ -6431,6 +6443,16 @@ if [ "$CFG_OPENGL" = "es2" ]; then - QT_CONFIG="$QT_CONFIG opengles2" - fi - -+if [ "$CFG_OPENGL" = "angle" ]; then -+ QCONFIG_FLAGS="$QCONFIG_FLAGS QT_OPENGL_ES QT_OPENGL_ES_2" -+ QT_CONFIG="$QT_CONFIG opengles2 egl angle" -+fi -+ -+if [ "$CFG_OPENGL" = "dynamic" ]; then -+ QCONFIG_FLAGS="$QCONFIG_FLAGS QT_OPENGL_DYNAMIC" -+ QT_CONFIG="$QT_CONFIG dynamicgl" -+fi -+ - if [ "$CFG_SHARED" = "yes" ]; then - QT_CONFIG="$QT_CONFIG shared" - QTCONFIG_CONFIG="$QTCONFIG_CONFIG shared" -@@ -7479,7 +7501,7 @@ report_support " OpenSSL .............." "$CFG_OPENSSL" yes "loading librarie - report_support " SecureTransport ......" "$CFG_SECURETRANSPORT" - report_support " OpenGL / OpenVG:" - report_support " EGL .................." "$CFG_EGL" --report_support " OpenGL ..............." "$CFG_OPENGL" yes "Desktop OpenGL" es2 "OpenGL ES 2.0+" -+report_support " OpenGL ..............." "$CFG_OPENGL" yes "Desktop OpenGL" es2 "OpenGL ES 2.0+" angle "ANGLE" dynamic "Dynamic OpenGL" - report_support " OpenVG ..............." "$CFG_OPENVG-$CFG_OPENVG_SHIVA" yes-yes "ShivaVG" yes-no "native" - report_support " PCRE ..................." "$CFG_PCRE" yes "system library" qt "bundled copy" - if [ -n "$PKG_CONFIG" ]; then -diff --git a/src/gui/opengl/qopenglfunctions.h b/src/gui/opengl/qopenglfunctions.h -index f6cd0e553e..17214a0545 100644 ---- a/src/gui/opengl/qopenglfunctions.h -+++ b/src/gui/opengl/qopenglfunctions.h -@@ -56,9 +56,7 @@ - - //#define Q_ENABLE_OPENGL_FUNCTIONS_DEBUG - --#ifdef QT_OPENGL_ES - typedef double GLdouble; --#endif - - #ifdef Q_ENABLE_OPENGL_FUNCTIONS_DEBUG - #include <stdio.h> --- -2.11.0 - diff --git a/0009-Don-t-add-resource-files-to-LIBS-parameter.patch b/0006-Don-t-add-resource-files-to-LIBS-parameter.patch index 0cdf983bdea3..49b627790257 100644 --- a/0009-Don-t-add-resource-files-to-LIBS-parameter.patch +++ b/0006-Don-t-add-resource-files-to-LIBS-parameter.patch @@ -1,7 +1,7 @@ -From b98187a679d8a09d1fc1cf08e5ca940cd6152995 Mon Sep 17 00:00:00 2001 +From fee4dff74c2483c2f4a4d7299e062c366431fc53 Mon Sep 17 00:00:00 2001 From: Martchus <martchus@gmx.net> Date: Sun, 18 Sep 2016 13:58:28 +0200 -Subject: [PATCH 09/26] Don't add resource files to LIBS parameter +Subject: [PATCH 06/30] Don't add resource files to LIBS parameter Solves an issue where the generated pkg-config files contained invalid Libs.private references @@ -11,7 +11,7 @@ like .obj/debug/Qt5Cored_resource_res.o 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qmake/generators/win32/mingw_make.cpp b/qmake/generators/win32/mingw_make.cpp -index 382b10c37b..3caad900a8 100644 +index 8d5a9a7d0f..d2cf8d9afc 100644 --- a/qmake/generators/win32/mingw_make.cpp +++ b/qmake/generators/win32/mingw_make.cpp @@ -196,7 +196,7 @@ void MingwMakefileGenerator::init() @@ -24,5 +24,5 @@ index 382b10c37b..3caad900a8 100644 if (project->isActiveConfig("dll")) { QString destDir = ""; -- -2.11.0 +2.11.1 diff --git a/0010-Prevent-debug-library-names-in-pkg-config-files.patch b/0007-Prevent-debug-library-names-in-pkg-config-files.patch index dfbf6ae9c4d9..690e8bea741a 100644 --- a/0010-Prevent-debug-library-names-in-pkg-config-files.patch +++ b/0007-Prevent-debug-library-names-in-pkg-config-files.patch @@ -1,7 +1,7 @@ -From b32d821f76823f529a35afdb698633870fc18936 Mon Sep 17 00:00:00 2001 +From 995313e0795df5500fd84350e80a3f88202b473d Mon Sep 17 00:00:00 2001 From: Martchus <martchus@gmx.net> Date: Sun, 18 Sep 2016 14:01:14 +0200 -Subject: [PATCH 10/26] Prevent debug library names in pkg-config files +Subject: [PATCH 07/30] Prevent debug library names in pkg-config files qmake generates the pkgconfig .pc files two times, once for the release build and once for the debug build (which we're not actually @@ -15,10 +15,10 @@ files for the debug build an unique file name. 1 file changed, 3 insertions(+) diff --git a/qmake/generators/makefile.cpp b/qmake/generators/makefile.cpp -index fa5c796387..04c0210eb9 100644 +index 182fe79238..a762443fe2 100644 --- a/qmake/generators/makefile.cpp +++ b/qmake/generators/makefile.cpp -@@ -3163,6 +3163,9 @@ MakefileGenerator::pkgConfigFileName(bool fixify, bool onlyPrependDestdir) +@@ -3164,6 +3164,9 @@ MakefileGenerator::pkgConfigFileName(bool fixify, bool onlyPrependDestdir) if (dot != -1) ret = ret.left(dot); } @@ -29,5 +29,5 @@ index fa5c796387..04c0210eb9 100644 QString subdir = project->first("QMAKE_PKGCONFIG_DESTDIR").toQString(); if(!subdir.isEmpty()) { -- -2.11.0 +2.11.1 diff --git a/0008-Fix-linking-against-shared-static-libpng.patch b/0008-Fix-linking-against-shared-static-libpng.patch new file mode 100644 index 000000000000..066b62496483 --- /dev/null +++ b/0008-Fix-linking-against-shared-static-libpng.patch @@ -0,0 +1,26 @@ +From f3a39738bcf7560f023bd280017aedaeb756e5c2 Mon Sep 17 00:00:00 2001 +From: Martchus <martchus@gmx.net> +Date: Thu, 26 Jan 2017 17:51:31 +0100 +Subject: [PATCH 08/30] Fix linking against shared/static libpng + +--- + src/gui/configure.json | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/src/gui/configure.json b/src/gui/configure.json +index 1f5011617c..5006ff5a3a 100644 +--- a/src/gui/configure.json ++++ b/src/gui/configure.json +@@ -161,7 +161,8 @@ + "sources": [ + { "type": "pkgConfig", "args": "libpng" }, + { "libs": "-llibpng", "condition": "config.msvc" }, +- { "libs": "-lpng", "condition": "!config.msvc" } ++ { "libs": "-lpng -lz", "condition": "!config.msvc && !features.shared" }, ++ { "libs": "-lpng", "condition": "!config.msvc && features.shared" } + ] + }, + "mirclient": { +-- +2.11.1 + diff --git a/0009-Fix-linking-against-static-D-Bus.patch b/0009-Fix-linking-against-static-D-Bus.patch new file mode 100644 index 000000000000..db59848868f4 --- /dev/null +++ b/0009-Fix-linking-against-static-D-Bus.patch @@ -0,0 +1,66 @@ +From 3379bc4d4d65124ec08aa8dade1b6b2a7b25f61e Mon Sep 17 00:00:00 2001 +From: Martchus <martchus@gmx.net> +Date: Fri, 3 Feb 2017 19:36:25 +0100 +Subject: [PATCH 09/30] Fix linking against static D-Bus + +--- + config.tests/unix/dbus/dbus.cpp | 4 ++++ + configure.json | 6 +++++- + src/dbus/qdbus_symbols_p.h | 4 ++++ + 3 files changed, 13 insertions(+), 1 deletion(-) + +diff --git a/config.tests/unix/dbus/dbus.cpp b/config.tests/unix/dbus/dbus.cpp +index 295c904400..80d3e9c044 100644 +--- a/config.tests/unix/dbus/dbus.cpp ++++ b/config.tests/unix/dbus/dbus.cpp +@@ -37,6 +37,10 @@ + ** + ****************************************************************************/ + ++#ifdef QT_STATIC ++# define DBUS_STATIC_BUILD ++#endif ++ + #define DBUS_API_SUBJECT_TO_CHANGE + #include <dbus/dbus.h> + +diff --git a/configure.json b/configure.json +index f774291d22..12714da714 100644 +--- a/configure.json ++++ b/configure.json +@@ -158,12 +158,16 @@ + "sources": [ + { "type": "pkgConfig", "args": "dbus-1 >= 1.2" }, + { ++ "libs": "-ldbus-1 -lws2_32 -liphlpapi", ++ "condition": "config.win32 && !features.shared" ++ }, ++ { + "libs": "", + "builds": { + "debug": "-ldbus-1d", + "release": "-ldbus-1" + }, +- "condition": "config.win32" ++ "condition": "config.win32 && features.shared" + }, + { "libs": "-ldbus-1", "condition": "!config.win32" } + ] +diff --git a/src/dbus/qdbus_symbols_p.h b/src/dbus/qdbus_symbols_p.h +index cfc0e12046..65f1397cd6 100644 +--- a/src/dbus/qdbus_symbols_p.h ++++ b/src/dbus/qdbus_symbols_p.h +@@ -57,6 +57,10 @@ + + #ifndef QT_NO_DBUS + ++#ifdef QT_STATIC ++# define DBUS_STATIC_BUILD ++#endif ++ + #ifdef QT_LINKED_LIBDBUS + # include <dbus/dbus.h> + #else +-- +2.11.1 + diff --git a/0010-Fix-linking-against-static-freetype2.patch b/0010-Fix-linking-against-static-freetype2.patch new file mode 100644 index 000000000000..bfdc43d6236e --- /dev/null +++ b/0010-Fix-linking-against-static-freetype2.patch @@ -0,0 +1,30 @@ +From 24c3bda7db1733545350436d8c2f489be5395650 Mon Sep 17 00:00:00 2001 +From: Martchus <martchus@gmx.net> +Date: Fri, 3 Feb 2017 20:51:19 +0100 +Subject: [PATCH 10/30] Fix linking against static freetype2 + +--- + src/gui/configure.json | 7 +++++-- + 1 file changed, 5 insertions(+), 2 deletions(-) + +diff --git a/src/gui/configure.json b/src/gui/configure.json +index 5006ff5a3a..6530357be9 100644 +--- a/src/gui/configure.json ++++ b/src/gui/configure.json +@@ -99,8 +99,11 @@ + "label": "FreeType", + "test": "unix/freetype", + "sources": [ +- { "type": "pkgConfig", "args": "freetype2" }, +- { "type": "freetype", "libs": "-lfreetype" } ++ { "type": "pkgConfig", "args": "--static --libs freetype2", "condition": "!features.shared" }, ++ { "type": "pkgConfig", "args": "--libs freetype2", "condition": "features.shared" }, ++ { "libs": "-lfreetype -lharfbuzz -lfreetype -lglib-2.0 -lintl -lws2_32 -lole32 -lwinmm -lshlwapi -lpcre -lintl -lpcre -lintl -liconv -lgraphite2 -lbz2", "condition": "!features.shared" }, ++ { "libs": "-Wl,-Bdynamic -lfreetype -Wl,-Bstatic", "condition": "!features.shared" }, ++ { "libs": "-lfreetype", "condition": "features.shared" } + ] + }, + "fontconfig": { +-- +2.11.1 + diff --git a/0011-Fix-linking-against-static-D-Bus.patch b/0011-Fix-linking-against-static-D-Bus.patch deleted file mode 100644 index da7ac99385bf..000000000000 --- a/0011-Fix-linking-against-static-D-Bus.patch +++ /dev/null @@ -1,43 +0,0 @@ -From c9836f2d0b0d86b47ff5607d581d133f9e3f06c6 Mon Sep 17 00:00:00 2001 -From: Martchus <martchus@gmx.net> -Date: Sun, 18 Sep 2016 14:07:02 +0200 -Subject: [PATCH 11/26] Fix linking against static D-Bus - ---- - config.tests/unix/dbus/dbus.cpp | 4 ++++ - src/dbus/qdbus_symbols_p.h | 4 ++++ - 2 files changed, 8 insertions(+) - -diff --git a/config.tests/unix/dbus/dbus.cpp b/config.tests/unix/dbus/dbus.cpp -index 295c904400..80d3e9c044 100644 ---- a/config.tests/unix/dbus/dbus.cpp -+++ b/config.tests/unix/dbus/dbus.cpp -@@ -37,6 +37,10 @@ - ** - ****************************************************************************/ - -+#ifdef QT_STATIC -+# define DBUS_STATIC_BUILD -+#endif -+ - #define DBUS_API_SUBJECT_TO_CHANGE - #include <dbus/dbus.h> - -diff --git a/src/dbus/qdbus_symbols_p.h b/src/dbus/qdbus_symbols_p.h -index fbeea61c95..8e73e9eec8 100644 ---- a/src/dbus/qdbus_symbols_p.h -+++ b/src/dbus/qdbus_symbols_p.h -@@ -57,6 +57,10 @@ - - #ifndef QT_NO_DBUS - -+#ifdef QT_STATIC -+# define DBUS_STATIC_BUILD -+#endif -+ - #ifdef QT_LINKED_LIBDBUS - # include <dbus/dbus.h> - #else --- -2.11.0 - diff --git a/0011-Fix-linking-against-static-harfbuzz.patch b/0011-Fix-linking-against-static-harfbuzz.patch new file mode 100644 index 000000000000..cb9f7ecfc986 --- /dev/null +++ b/0011-Fix-linking-against-static-harfbuzz.patch @@ -0,0 +1,29 @@ +From 52c34159dec8c829d1f2928d2c9a56bb7299fbff Mon Sep 17 00:00:00 2001 +From: Martchus <martchus@gmx.net> +Date: Sun, 18 Sep 2016 14:22:56 +0200 +Subject: [PATCH 11/30] Fix linking against static harfbuzz + +--- + src/gui/configure.json | 6 +++++- + 1 file changed, 5 insertions(+), 1 deletion(-) + +diff --git a/src/gui/configure.json b/src/gui/configure.json +index 6530357be9..c5b9b1542a 100644 +--- a/src/gui/configure.json ++++ b/src/gui/configure.json +@@ -125,7 +125,11 @@ + "label": "HarfBuzz", + "test": "unix/harfbuzz", + "sources": [ +- "-lharfbuzz" ++ { "type": "pkgConfig", "args": "--static --libs harfbuzz", "condition": "!features.shared" }, ++ { "type": "pkgConfig", "args": "--libs harfbuzz", "condition": "features.shared" }, ++ { "libs": "-lharfbuzz -lfreetype -lharfbuzz -lglib-2.0 -lintl -lws2_32 -lole32 -lwinmm -lshlwapi -lpcre -lintl -lpcre -lintl -liconv -lgraphite2 -lbz2", "condition": "!features.shared" }, ++ { "libs": "-Wl,-Bdynamic -lharfbuzz -Wl,-Bstatic", "condition": "!features.shared" }, ++ { "libs": "-lharfbuzz", "condition": "features.shared" } + ] + }, + "imf": { +-- +2.11.1 + diff --git a/0012-Adjust-win32-g-mkspecs-profile.patch b/0012-Adjust-win32-g-mkspecs-profile.patch deleted file mode 100644 index 9c064d453dff..000000000000 --- a/0012-Adjust-win32-g-mkspecs-profile.patch +++ /dev/null @@ -1,75 +0,0 @@ -From 5c8fa53c4690db11914df6470853958a09e6f0e2 Mon Sep 17 00:00:00 2001 -From: Martchus <martchus@gmx.net> -Date: Sun, 18 Sep 2016 14:15:08 +0200 -Subject: [PATCH 12/26] Adjust win32-g++ mkspecs profile - -- Use default compile flags for mingw-w64 packages - under Arch Linux -- Adjust libraries and tools ---- - mkspecs/win32-g++/qmake.conf | 25 +++++++++++++++---------- - 1 file changed, 15 insertions(+), 10 deletions(-) - -diff --git a/mkspecs/win32-g++/qmake.conf b/mkspecs/win32-g++/qmake.conf -index 6ed39745ae..3ee820e54b 100644 ---- a/mkspecs/win32-g++/qmake.conf -+++ b/mkspecs/win32-g++/qmake.conf -@@ -26,7 +26,7 @@ QMAKE_LEX = flex - QMAKE_LEXFLAGS = - QMAKE_YACC = bison -y - QMAKE_YACCFLAGS = -d --QMAKE_CFLAGS = -pipe -fno-keep-inline-dllexport -+QMAKE_CFLAGS = -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions --param=ssp-buffer-size=4 -fno-keep-inline-dllexport $${CROSS_COMPILE_CFLAGS} - QMAKE_CFLAGS_DEPS = -M - QMAKE_CFLAGS_WARN_ON = -Wall -Wextra - QMAKE_CFLAGS_WARN_OFF = -w -@@ -75,10 +75,10 @@ QMAKE_RUN_CXX_IMP = $(CXX) -c $(CXXFLAGS) $(INCPATH) -o $@ $< - - QMAKE_LINK = $${CROSS_COMPILE}g++ - QMAKE_LINK_C = $${CROSS_COMPILE}gcc --QMAKE_LFLAGS = -+QMAKE_LFLAGS = -g - QMAKE_LFLAGS_EXCEPTIONS_ON = -mthreads - QMAKE_LFLAGS_EXCEPTIONS_OFF = --QMAKE_LFLAGS_RELEASE = -Wl,-s -+QMAKE_LFLAGS_RELEASE = - QMAKE_LFLAGS_DEBUG = - QMAKE_LFLAGS_CONSOLE = -Wl,-subsystem,console - QMAKE_LFLAGS_WINDOWS = -Wl,-subsystem,windows -@@ -96,21 +96,26 @@ QMAKE_EXTENSION_STATICLIB = a - QMAKE_LIB_EXTENSIONS = a dll.a - - QMAKE_LIBS = --QMAKE_LIBS_CORE = -lole32 -luuid -lws2_32 -ladvapi32 -lshell32 -luser32 -lkernel32 --QMAKE_LIBS_GUI = -lgdi32 -lcomdlg32 -loleaut32 -limm32 -lwinmm -lws2_32 -lole32 -luuid -luser32 -ladvapi32 --QMAKE_LIBS_NETWORK = -lws2_32 -+QMAKE_LIBS_CORE = -lole32 -luuid -lws2_32 -ladvapi32 -lshell32 -luser32 -lkernel32 -lz -lpcre16 -+QMAKE_LIBS_GUI = -lgdi32 -lcomdlg32 -loleaut32 -limm32 -lwinmm -lws2_32 -lole32 -luuid -luser32 -ladvapi32 -ljpeg -lpng $$system($${CROSS_COMPILE}pkg-config --static --libs harfbuzz) $$system($${CROSS_COMPILE}pkg-config --static --libs freetype2) -+QMAKE_LIBS_NETWORK = -lws2_32 -lcrypt32 -ldnsapi - QMAKE_LIBS_OPENGL = -lglu32 -lopengl32 -lgdi32 -luser32 --QMAKE_LIBS_OPENGL_ES2 = -l$${LIBEGL_NAME} -l$${LIBGLESV2_NAME} -lgdi32 -luser32 --QMAKE_LIBS_OPENGL_ES2_DEBUG = -l$${LIBEGL_NAME}d -l$${LIBGLESV2_NAME}d -lgdi32 -luser32 -+QMAKE_LIBS_OPENGL_ES2 = -l$${LIBEGL_NAME} -l$${LIBGLESV2_NAME} -ld3d9 -ldxguid -lgdi32 -luser32 -+QMAKE_LIBS_OPENGL_ES2_DEBUG = -l$${LIBEGL_NAME} -l$${LIBGLESV2_NAME} -ld3d9 -ldxguid -lgdi32 -luser32 - QMAKE_LIBS_COMPAT = -ladvapi32 -lshell32 -lcomdlg32 -luser32 -lgdi32 -lws2_32 --QMAKE_LIBS_QT_ENTRY = -lmingw32 -lqtmain -+QMAKE_LIBS_QT_ENTRY = -lmingw32 -lqt5main - --QMAKE_IDL = midl -+QMAKE_IDL = $${CROSS_COMPILE}widl - QMAKE_LIB = $${CROSS_COMPILE}ar -rc - QMAKE_RC = $${CROSS_COMPILE}windres -+QMAKE_DLLTOOL = $${CROSS_COMPILE}dlltool -+QMAKE_LRELEASE = $${CROSS_COMPILE}lrelease-qt5 - - QMAKE_STRIP = $${CROSS_COMPILE}strip - QMAKE_STRIPFLAGS_LIB += --strip-unneeded - QMAKE_OBJCOPY = $${CROSS_COMPILE}objcopy - QMAKE_NM = $${CROSS_COMPILE}nm -P -+ -+PKG_CONFIG = $${CROSS_COMPILE}pkg-config -+ - load(qt_config) --- -2.11.0 - diff --git a/0014-Fix-linking-against-static-pcre.patch b/0012-Fix-linking-against-static-pcre.patch index 28a357f21ddc..17d52dbb6ca9 100644 --- a/0014-Fix-linking-against-static-pcre.patch +++ b/0012-Fix-linking-against-static-pcre.patch @@ -1,14 +1,14 @@ -From edcc4cad1376de4e843212cca56cb74aa5d7a7dd Mon Sep 17 00:00:00 2001 +From e2c35b81ed48f46c2260ad9e59ff7f50b073e9d4 Mon Sep 17 00:00:00 2001 From: Martchus <martchus@gmx.net> Date: Sun, 18 Sep 2016 14:24:01 +0200 -Subject: [PATCH 14/26] Fix linking against static pcre +Subject: [PATCH 12/30] Fix linking against static pcre --- src/corelib/tools/qregularexpression.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/corelib/tools/qregularexpression.cpp b/src/corelib/tools/qregularexpression.cpp -index e7f86ddf6b..63fc683c68 100644 +index 4a30daa72c..3d7c811124 100644 --- a/src/corelib/tools/qregularexpression.cpp +++ b/src/corelib/tools/qregularexpression.cpp @@ -54,6 +54,10 @@ @@ -23,5 +23,5 @@ index e7f86ddf6b..63fc683c68 100644 QT_BEGIN_NAMESPACE -- -2.11.0 +2.11.1 diff --git a/0013-Fix-linking-against-external-harfbuzz.patch b/0013-Fix-linking-against-external-harfbuzz.patch deleted file mode 100644 index 738b8664bd72..000000000000 --- a/0013-Fix-linking-against-external-harfbuzz.patch +++ /dev/null @@ -1,36 +0,0 @@ -From e08f71f26c964c3f5a82eb208d871fc883869f23 Mon Sep 17 00:00:00 2001 -From: Martchus <martchus@gmx.net> -Date: Sun, 18 Sep 2016 14:22:56 +0200 -Subject: [PATCH 13/26] Fix linking against external harfbuzz - ---- - config.tests/unix/harfbuzz/harfbuzz.pro | 3 ++- - src/3rdparty/harfbuzz_dependency.pri | 4 +++- - 2 files changed, 5 insertions(+), 2 deletions(-) - -diff --git a/config.tests/unix/harfbuzz/harfbuzz.pro b/config.tests/unix/harfbuzz/harfbuzz.pro -index 32edd6e358..cc40fc1678 100644 ---- a/config.tests/unix/harfbuzz/harfbuzz.pro -+++ b/config.tests/unix/harfbuzz/harfbuzz.pro -@@ -1,3 +1,4 @@ - SOURCES = harfbuzz.cpp - CONFIG -= qt dylib --LIBS += -lharfbuzz -+contains(CONFIG, static): LIBS += $$system($$PKG_CONFIG --static --libs harfbuzz) -+else: LIBS += $$system($$PKG_CONFIG --libs harfbuzz) -diff --git a/src/3rdparty/harfbuzz_dependency.pri b/src/3rdparty/harfbuzz_dependency.pri -index 74433688f6..2932f059e9 100644 ---- a/src/3rdparty/harfbuzz_dependency.pri -+++ b/src/3rdparty/harfbuzz_dependency.pri -@@ -2,5 +2,7 @@ contains(QT_CONFIG, harfbuzz) { - INCLUDEPATH += $$PWD/harfbuzz-ng/include - LIBS_PRIVATE += -L$$QT_BUILD_TREE/lib -lqtharfbuzzng$$qtPlatformTargetSuffix() - } else:contains(QT_CONFIG, system-harfbuzz) { -- LIBS_PRIVATE += -lharfbuzz -+ # can't use 'feature' link_pkgconfig here because it would add harfbuzz to LIBS rather than LIBS_PRIVATE -+ contains(QT_CONFIG, static): LIBS_PRIVATE += $$system($$PKG_CONFIG --static --libs harfbuzz) -+ else: LIBS_PRIVATE += $$system($$PKG_CONFIG --libs harfbuzz) - } --- -2.11.0 - diff --git a/0013-Fix-linking-against-shared-static-MariaDB.patch b/0013-Fix-linking-against-shared-static-MariaDB.patch new file mode 100644 index 000000000000..0bd7adfb93e2 --- /dev/null +++ b/0013-Fix-linking-against-shared-static-MariaDB.patch @@ -0,0 +1,26 @@ +From acbc69f1a6d40c8a4106e4b931650b6921a40503 Mon Sep 17 00:00:00 2001 +From: Martchus <martchus@gmx.net> +Date: Sun, 18 Sep 2016 18:56:55 +0200 +Subject: [PATCH 13/30] Fix linking against shared/static MariaDB + +--- + src/sql/configure.json | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/src/sql/configure.json b/src/sql/configure.json +index 96c82e84f9..7219926cf5 100644 +--- a/src/sql/configure.json ++++ b/src/sql/configure.json +@@ -58,6 +58,9 @@ + "label": "MySQL", + "test": "unix/mysql", + "sources": [ ++ { "libs": "-lmariadbclient -lssl -lcrypto -lws2_32 -lpthread -lz -lm", "condition": "config.win32 && !features.shared" }, ++ { "libs": "-Wl,-Bdynamic -lmariadb -Wl,-Bstatic", "condition": "config.win32 && !features.shared" }, ++ { "libs": "-lmariadb", "condition": "config.win32 && features.shared" }, + { "type": "mysqlConfig", "query": "--libs_r" }, + { "type": "mysqlConfig", "query": "--libs" }, + { "libs": "-lmysqlclient_r", "condition": "!config.win32" }, +-- +2.11.1 + diff --git a/0014-Fix-linking-against-shared-static-PostgreSQL.patch b/0014-Fix-linking-against-shared-static-PostgreSQL.patch new file mode 100644 index 000000000000..af474c80177c --- /dev/null +++ b/0014-Fix-linking-against-shared-static-PostgreSQL.patch @@ -0,0 +1,29 @@ +From 0712fd493611c503092fe616b4bd1c75e1d5d5ee Mon Sep 17 00:00:00 2001 +From: Martchus <martchus@gmx.net> +Date: Sun, 18 Sep 2016 18:58:25 +0200 +Subject: [PATCH 14/30] Fix linking against shared/static PostgreSQL + +--- + src/sql/configure.json | 5 +++-- + 1 file changed, 3 insertions(+), 2 deletions(-) + +diff --git a/src/sql/configure.json b/src/sql/configure.json +index 7219926cf5..713254b8cf 100644 +--- a/src/sql/configure.json ++++ b/src/sql/configure.json +@@ -72,9 +72,10 @@ + "label": "PostgreSQL", + "test": "unix/psql", + "sources": [ +- { "type": "pkgConfig", "args": "libpq" }, + { "type": "psqlConfig" }, +- { "type": "psqlEnv", "libs": "-llibpq -lws2_32 -ladvapi32", "condition": "config.win32" }, ++ { "type": "psqlEnv", "libs": "-lpq -lintl -lssl -lcrypto -lshell32 -lws2_32 -lsecur32", "condition": "config.win32 && !features.shared" }, ++ { "type": "psqlEnv", "libs": "-Wl,-Bdynamic -lpq -Wl,-Bstatic", "condition": "config.win32 && !features.shared" }, ++ { "type": "psqlEnv", "libs": "-lpq", "condition": "config.win32 && features.shared" }, + { "type": "psqlEnv", "libs": "-lpq", "condition": "!config.win32" } + ] + }, +-- +2.11.1 + diff --git a/0015-Rename-qtmain-to-qt5main.patch b/0015-Rename-qtmain-to-qt5main.patch index 4398ab7ddf9b..3eae2223d770 100644 --- a/0015-Rename-qtmain-to-qt5main.patch +++ b/0015-Rename-qtmain-to-qt5main.patch @@ -1,7 +1,7 @@ -From 23032a6a5efa261c73b40adbc708cec7fe309b3d Mon Sep 17 00:00:00 2001 +From c15379dee443b353a9e1b1a5aff4301c29f3341b Mon Sep 17 00:00:00 2001 From: Martchus <martchus@gmx.net> Date: Sun, 18 Sep 2016 14:25:40 +0200 -Subject: [PATCH 15/26] Rename qtmain to qt5main +Subject: [PATCH 15/30] Rename qtmain to qt5main Prevents conflict with mingw-w64-qt4 package --- @@ -11,7 +11,7 @@ Prevents conflict with mingw-w64-qt4 package 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/mkspecs/features/create_cmake.prf b/mkspecs/features/create_cmake.prf -index 11fb52a0b1..4adacf6762 100644 +index 1099e14b17..ed9b82fba9 100644 --- a/mkspecs/features/create_cmake.prf +++ b/mkspecs/features/create_cmake.prf @@ -225,8 +225,8 @@ mac { @@ -26,7 +26,7 @@ index 11fb52a0b1..4adacf6762 100644 !isEmpty(CMAKE_STATIC_TYPE) { CMAKE_STATIC_WINDOWS_BUILD = "true" diff --git a/mkspecs/features/win32/windows.prf b/mkspecs/features/win32/windows.prf -index 986067fc8c..339ac15efe 100644 +index ecb167bf18..7c9368c3b3 100644 --- a/mkspecs/features/win32/windows.prf +++ b/mkspecs/features/win32/windows.prf @@ -5,7 +5,7 @@ contains(TEMPLATE, ".*app") { @@ -39,7 +39,7 @@ index 986067fc8c..339ac15efe 100644 QMAKE_LIBS += -L$$QT.core.libs CONFIG(debug, debug|release): QMAKE_LIBS += $${entryLib}$${QT_LIBINFIX}d diff --git a/src/winmain/winmain.pro b/src/winmain/winmain.pro -index b4977653ce..d63a684a18 100644 +index 4140ae48de..9ae73db74b 100644 --- a/src/winmain/winmain.pro +++ b/src/winmain/winmain.pro @@ -2,7 +2,7 @@ @@ -52,5 +52,5 @@ index b4977653ce..d63a684a18 100644 CONFIG += static -- -2.11.0 +2.11.1 diff --git a/0016-Build-dynamic-host-libraries.patch b/0016-Build-dynamic-host-libraries.patch index 8a299a72b9d2..0ac1d3241e74 100644 --- a/0016-Build-dynamic-host-libraries.patch +++ b/0016-Build-dynamic-host-libraries.patch @@ -1,7 +1,7 @@ -From 5b1b584626a4b89500bd8925dee62a61f869f179 Mon Sep 17 00:00:00 2001 +From 008256f455bb1e28f28cd9b492a0ecd34c05c0aa Mon Sep 17 00:00:00 2001 From: Martchus <martchus@gmx.net> Date: Sun, 18 Sep 2016 14:27:28 +0200 -Subject: [PATCH 16/26] Build dynamic host libraries +Subject: [PATCH 16/30] Build dynamic host libraries For better accordance with Arch Linux packaging standards @@ -11,10 +11,10 @@ standards 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/mkspecs/features/qt_module.prf b/mkspecs/features/qt_module.prf -index d9011f5482..cb29009970 100644 +index 31d628596c..360c99ac73 100644 --- a/mkspecs/features/qt_module.prf +++ b/mkspecs/features/qt_module.prf -@@ -25,7 +25,7 @@ isEmpty(VERSION): error("Module does not define version.") +@@ -24,7 +24,7 @@ requires(!$$skip) # Compile as shared/DLL or static according to the option given to configure # unless overridden. Host builds are always static @@ -34,5 +34,5 @@ index c3ed27d979..30d2114aa1 100644 -INSTALLS = lib +INSTALLS += lib -- -2.11.0 +2.11.1 diff --git a/0017-Enable-rpath-for-build-tools.patch b/0017-Enable-rpath-for-build-tools.patch index 3c6f1eb830fc..8029e9630147 100644 --- a/0017-Enable-rpath-for-build-tools.patch +++ b/0017-Enable-rpath-for-build-tools.patch @@ -1,7 +1,7 @@ -From 1fae399984442e1ece149022f4411c4cac7c16ad Mon Sep 17 00:00:00 2001 +From 25cdf3efda8669c68df7c8ad0332bdaddbf4d628 Mon Sep 17 00:00:00 2001 From: Martchus <martchus@gmx.net> Date: Sun, 18 Sep 2016 17:59:27 +0200 -Subject: [PATCH 17/26] Enable rpath for build tools +Subject: [PATCH 17/30] Enable rpath for build tools - Required because library various tools depend on (libQt5Bootstrap.so) resides in folder /usr/${_arch}/lib @@ -11,7 +11,7 @@ Subject: [PATCH 17/26] Enable rpath for build tools 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mkspecs/features/qt_app.prf b/mkspecs/features/qt_app.prf -index 46aca50cc2..e7636027aa 100644 +index cb84ae0da8..8d9471ed0a 100644 --- a/mkspecs/features/qt_app.prf +++ b/mkspecs/features/qt_app.prf @@ -20,6 +20,7 @@ isEmpty(QMAKE_INFO_PLIST): CONFIG -= app_bundle @@ -20,16 +20,16 @@ index 46aca50cc2..e7636027aa 100644 host_build: QT -= gui # no host tool will ever use gui +host_build: QMAKE_RPATHDIR += $$[QT_INSTALL_LIBS/dev] # force rpath host_build:force_bootstrap { - !build_pass:contains(QT_CONFIG, release_tools): CONFIG += release + !build_pass:qtConfig(release_tools): CONFIG += release contains(QT, core(-private)?|xml) { @@ -30,7 +31,6 @@ host_build:force_bootstrap { } else { - !build_pass:contains(QT_CONFIG, debug_and_release): CONFIG += release + !build_pass:qtConfig(debug_and_release): CONFIG += release target.path = $$[QT_INSTALL_BINS] - CONFIG += relative_qt_rpath # Qt's tools and apps should be relocatable } INSTALLS += target -- -2.11.0 +2.11.1 diff --git a/0018-Use-system-zlib-for-build-tools.patch b/0018-Use-system-zlib-for-build-tools.patch index fdf6e4422a97..63e1b560bfa3 100644 --- a/0018-Use-system-zlib-for-build-tools.patch +++ b/0018-Use-system-zlib-for-build-tools.patch @@ -1,25 +1,25 @@ -From 3dc08a44504c948ee201bc214277fa634940fa54 Mon Sep 17 00:00:00 2001 +From 206e25be29ac115c84076a2b58bae3a6d0900eb1 Mon Sep 17 00:00:00 2001 From: Martchus <martchus@gmx.net> Date: Sun, 18 Sep 2016 18:04:42 +0200 -Subject: [PATCH 18/26] Use system zlib for build tools +Subject: [PATCH 18/30] Use system zlib for build tools --- src/tools/bootstrap/bootstrap.pro | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tools/bootstrap/bootstrap.pro b/src/tools/bootstrap/bootstrap.pro -index a43105297f..b97ff0aa31 100644 +index d51f9e98a4..2242b7c4f1 100644 --- a/src/tools/bootstrap/bootstrap.pro +++ b/src/tools/bootstrap/bootstrap.pro -@@ -134,7 +134,7 @@ macx { +@@ -127,7 +127,7 @@ macx { ../../corelib/io/qstandardpaths_win.cpp } --contains(QT_CONFIG, zlib)|cross_compile { -+contains(QT_CONFIG, zlib) { +-!qtConfig(system-zlib)|cross_compile { ++!qtConfig(system-zlib) { include(../../3rdparty/zlib.pri) } else { CONFIG += no_core_dep -- -2.11.0 +2.11.1 diff --git a/0019-Disable-determing-default-include-and-lib-dirs-at-qm.patch b/0019-Disable-determing-default-include-and-lib-dirs-at-qm.patch index e4cdc0c91872..b849cbf70d43 100644 --- a/0019-Disable-determing-default-include-and-lib-dirs-at-qm.patch +++ b/0019-Disable-determing-default-include-and-lib-dirs-at-qm.patch @@ -1,7 +1,7 @@ -From 6b99dac278b4c41000fd6f92c8d400a82cbe484a Mon Sep 17 00:00:00 2001 +From 698d1f283e96c2d04e7482dc51bb43d43e6fd17c Mon Sep 17 00:00:00 2001 From: Martchus <martchus@gmx.net> Date: Sun, 18 Sep 2016 18:20:25 +0200 -Subject: [PATCH 19/26] Disable determing default include and lib dirs at qmake +Subject: [PATCH 19/30] Disable determing default include and lib dirs at qmake time when building with mingw-w64 --- @@ -9,10 +9,10 @@ Subject: [PATCH 19/26] Disable determing default include and lib dirs at qmake 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mkspecs/features/toolchain.prf b/mkspecs/features/toolchain.prf -index 7691b7db34..d262097f09 100644 +index 3f266dd2a4..258d374ee0 100644 --- a/mkspecs/features/toolchain.prf +++ b/mkspecs/features/toolchain.prf -@@ -3,7 +3,7 @@ isEmpty(QMAKE_DEFAULT_INCDIRS):!host_build { +@@ -13,7 +13,7 @@ isEmpty(QMAKE_DEFAULT_INCDIRS):!host_build { # # Get default include and library paths from compiler # @@ -22,5 +22,5 @@ index 7691b7db34..d262097f09 100644 cmd_prefix = "LC_ALL=C" cmd_suffix = "</dev/null >/dev/null" -- -2.11.0 +2.11.1 diff --git a/0020-Use-.dll.a-as-import-lib-extension.patch b/0020-Use-.dll.a-as-import-lib-extension.patch index d86cb4642eb0..0f840ab8ae7a 100644 --- a/0020-Use-.dll.a-as-import-lib-extension.patch +++ b/0020-Use-.dll.a-as-import-lib-extension.patch @@ -1,16 +1,17 @@ -From dd6f19fca955ac5918c3b0dca245f9eec9f0755e Mon Sep 17 00:00:00 2001 +From 6993d2146fb9adf79f7e1f28b44b12a2104ed71c Mon Sep 17 00:00:00 2001 From: Martchus <martchus@gmx.net> Date: Sun, 18 Sep 2016 18:26:18 +0200 -Subject: [PATCH 20/26] Use *.dll.a as import lib extension +Subject: [PATCH 20/30] Use *.dll.a as import lib extension +The variables used here are provided by +mingw-w64 specific mkspec --- mkspecs/features/create_cmake.prf | 5 +++-- - mkspecs/win32-g++/qmake.conf | 2 +- qmake/generators/win32/winmakefile.cpp | 17 ++++++++++++----- - 3 files changed, 16 insertions(+), 8 deletions(-) + 2 files changed, 15 insertions(+), 7 deletions(-) diff --git a/mkspecs/features/create_cmake.prf b/mkspecs/features/create_cmake.prf -index 4adacf6762..0ff1c6d142 100644 +index ed9b82fba9..461a7fdff5 100644 --- a/mkspecs/features/create_cmake.prf +++ b/mkspecs/features/create_cmake.prf @@ -236,8 +236,9 @@ mac { @@ -25,21 +26,8 @@ index 4adacf6762..0ff1c6d142 100644 } } else { CMAKE_WINMAIN_FILE_LOCATION_DEBUG = qtmain$${QT_LIBINFIX}d.lib -diff --git a/mkspecs/win32-g++/qmake.conf b/mkspecs/win32-g++/qmake.conf -index 3ee820e54b..44253a2a37 100644 ---- a/mkspecs/win32-g++/qmake.conf -+++ b/mkspecs/win32-g++/qmake.conf -@@ -93,7 +93,7 @@ QMAKE_PREFIX_SHLIB = - QMAKE_EXTENSION_SHLIB = dll - QMAKE_PREFIX_STATICLIB = lib - QMAKE_EXTENSION_STATICLIB = a --QMAKE_LIB_EXTENSIONS = a dll.a -+QMAKE_EXTENSION_IMPORTLIB = dll.a - - QMAKE_LIBS = - QMAKE_LIBS_CORE = -lole32 -luuid -lws2_32 -ladvapi32 -lshell32 -luser32 -lkernel32 -lz -lpcre16 diff --git a/qmake/generators/win32/winmakefile.cpp b/qmake/generators/win32/winmakefile.cpp -index 543e905051..456f21cedb 100644 +index caa000ea53..e6338546bb 100644 --- a/qmake/generators/win32/winmakefile.cpp +++ b/qmake/generators/win32/winmakefile.cpp @@ -80,10 +80,14 @@ Win32MakefileGenerator::parseLibFlag(const ProString &flag, ProString *arg) @@ -61,7 +49,7 @@ index 543e905051..456f21cedb 100644 static const char * const lflags[] = { "QMAKE_LIBS", "QMAKE_LIBS_PRIVATE", 0 }; for (int i = 0; lflags[i]; i++) { ProStringList &l = project->values(lflags[i]); -@@ -228,9 +232,12 @@ void Win32MakefileGenerator::fixTargetExt() +@@ -231,9 +235,12 @@ void Win32MakefileGenerator::fixTargetExt() if (!project->values("QMAKE_APP_FLAG").isEmpty()) { project->values("TARGET_EXT").append(".exe"); } else if (project->isActiveConfig("shared")) { @@ -76,5 +64,5 @@ index 543e905051..456f21cedb 100644 + project->first("QMAKE_EXTENSION_SHLIB")); project->values("TARGET").first() = project->first("QMAKE_PREFIX_SHLIB") + project->first("TARGET"); -- -2.11.0 +2.11.1 diff --git a/0021-Merge-shared-and-static-library-trees.patch b/0021-Merge-shared-and-static-library-trees.patch index b100204767ca..0036722c8e0d 100644 --- a/0021-Merge-shared-and-static-library-trees.patch +++ b/0021-Merge-shared-and-static-library-trees.patch @@ -1,66 +1,72 @@ -From 4a2456d3e7372aaacf0aa25a116f85aebf21ef5b Mon Sep 17 00:00:00 2001 +From 96f65c5db2dfb4c4a646eabd48b4f864850b5121 Mon Sep 17 00:00:00 2001 From: Martchus <martchus@gmx.net> Date: Sun, 18 Sep 2016 18:45:08 +0200 -Subject: [PATCH 21/26] Merge shared and static library trees +Subject: [PATCH 21/30] Merge shared and static library trees Allow installation of shared and static build in the same prefix --- - configure | 6 ++++++ - mkspecs/features/default_post.prf | 8 ++++++++ - mkspecs/features/qt.prf | 12 ++++++++++++ + configure.pri | 7 +++++++ + mkspecs/features/default_post.prf | 11 +++++++++++ + mkspecs/features/qt.prf | 15 +++++++++++++++ mkspecs/features/spec_pre.prf | 11 ++++++++--- qmake/generators/makefile.cpp | 9 ++++++--- - 5 files changed, 40 insertions(+), 6 deletions(-) + 5 files changed, 47 insertions(+), 6 deletions(-) -diff --git a/configure b/configure -index af275de52c..9ecc7f9ada 100755 ---- a/configure -+++ b/configure -@@ -7187,6 +7187,12 @@ host_build { - } - QT_CONFIG += $QT_CONFIG +diff --git a/configure.pri b/configure.pri +index 19719736a9..0c4b8ebbf8 100644 +--- a/configure.pri ++++ b/configure.pri +@@ -555,3 +555,10 @@ QMAKE_POST_CONFIGURE += \ + # load and process input from configure.sh/.exe + include($$shadowed($$PWD)/config.tests/configure.cfg) ++ ++# merge shared and static library trees +contains(CONFIG, static) { + CONFIG -= shared + QT_CONFIG += static jpeg gif + QT_CONFIG -= shared +} -+ - #versioning - QT_VERSION = $QT_VERSION - QT_MAJOR_VERSION = $QT_MAJOR_VERSION diff --git a/mkspecs/features/default_post.prf b/mkspecs/features/default_post.prf -index e7e9a5bd87..799278d445 100644 +index e7e9a5bd87..72305ad9b8 100644 --- a/mkspecs/features/default_post.prf +++ b/mkspecs/features/default_post.prf -@@ -120,3 +120,11 @@ c++11|c++14|c++1z { +@@ -1,5 +1,16 @@ + # This file is loaded by qmake right after loading the actual project file. - QMAKE_INCDIR += $$QMAKE_INCDIR_POST - QMAKE_LIBDIR += $$QMAKE_LIBDIR_POST -+ +win32:contains(CONFIG, static) { -+ DEFINES += QT_STATIC QT_DESIGNER_STATIC ++ # Ensure defines are set correctly for static build + DEFINES -= QT_SHARED -+ contains(QT_CONFIG, angle): DEFINES += QT_OPENGL_ES_2_ANGLE_STATIC ++ DEFINES *= QT_STATIC QT_DESIGNER_STATIC ++ contains(QT_CONFIG, angle): DEFINES *= QT_OPENGL_ES_2_ANGLE_STATIC ++ # Ensure we link against all dependencies statically + QMAKE_LFLAGS += -static -static-libstdc++ -static-libgcc -+ QMAKE_EXT_PRL=.static.prl # prevents qmake from finding the prl file for shared libs ++ # Prevent qmake from finding the prl file for shared libs ++ QMAKE_EXT_PRL = .static.prl +} ++ + contains(TEMPLATE, ".*(lib|app)"):CONFIG += have_target + + !have_target:!force_qt: CONFIG -= qt diff --git a/mkspecs/features/qt.prf b/mkspecs/features/qt.prf -index bb52f23378..1815ba3241 100644 +index 98f794c485..1799622edd 100644 --- a/mkspecs/features/qt.prf +++ b/mkspecs/features/qt.prf -@@ -150,6 +150,18 @@ for(ever) { +@@ -152,6 +152,21 @@ for(ever) { !isEmpty(MODULE_WINRT_CAPABILITIES_DEVICE): \ WINRT_MANIFEST.capabilities_device_default += $$MODULE_WINRT_CAPABILITIES_DEVICE } + -+ win32:CONFIG(static) { ++ # Ensure linking against all required static libraries as defined in mingw-w64-g++ mkspec ++ win32:contains(CONFIG, static) { + isEqual(MODULE_NAME, QtCore) { + LIBS$$var_sfx += $$QMAKE_LIBS_CORE + } else:isEqual(MODULE_NAME, QtGui) { + LIBS$$var_sfx += $$QMAKE_LIBS_GUI + } else:isEqual(MODULE_NAME, QtNetwork) { + LIBS$$var_sfx += $$QMAKE_LIBS_NETWORK ++ } else:isEqual(MODULE_NAME, QtDBus) { ++ LIBS$$var_sfx += $$QMAKE_LIBS_DBUS + } else:isEqual(MODULE_NAME, QtOpenGL) { + LIBS$$var_sfx += $$QMAKE_LIBS_OPENGL + } @@ -69,7 +75,7 @@ index bb52f23378..1815ba3241 100644 !isEmpty(BAD_QT):error("Unknown module(s) in QT$$var_sfx: $$replace(BAD_QT, _private$, -private)") diff --git a/mkspecs/features/spec_pre.prf b/mkspecs/features/spec_pre.prf -index 090f348ebf..05d28636b9 100644 +index 51ea3a8321..275e080ae4 100644 --- a/mkspecs/features/spec_pre.prf +++ b/mkspecs/features/spec_pre.prf @@ -14,9 +14,14 @@ QMAKE_EXT_H = .h .hpp .hh .hxx @@ -91,10 +97,10 @@ index 090f348ebf..05d28636b9 100644 QMAKE_EXT_YACC = .y diff --git a/qmake/generators/makefile.cpp b/qmake/generators/makefile.cpp -index 04c0210eb9..f05a039d2f 100644 +index a762443fe2..8ac3a0f647 100644 --- a/qmake/generators/makefile.cpp +++ b/qmake/generators/makefile.cpp -@@ -3166,6 +3166,9 @@ MakefileGenerator::pkgConfigFileName(bool fixify, bool onlyPrependDestdir) +@@ -3167,6 +3167,9 @@ MakefileGenerator::pkgConfigFileName(bool fixify, bool onlyPrependDestdir) if (project->isActiveConfig("debug")) { ret += "d"; } @@ -104,7 +110,7 @@ index 04c0210eb9..f05a039d2f 100644 ret += Option::pkgcfg_ext; QString subdir = project->first("QMAKE_PKGCONFIG_DESTDIR").toQString(); if(!subdir.isEmpty()) { -@@ -3339,9 +3342,9 @@ MakefileGenerator::writePkgConfigFile() +@@ -3340,9 +3343,9 @@ MakefileGenerator::writePkgConfigFile() t << endl; // requires @@ -118,5 +124,5 @@ index 04c0210eb9..f05a039d2f 100644 t << endl; -- -2.11.0 +2.11.1 diff --git a/0022-Allow-usage-of-static-version-with-CMake.patch b/0022-Allow-usage-of-static-version-with-CMake.patch index 614e2d442c38..2e36f158c9c2 100644 --- a/0022-Allow-usage-of-static-version-with-CMake.patch +++ b/0022-Allow-usage-of-static-version-with-CMake.patch @@ -1,7 +1,7 @@ -From 5e519508a93e9b6229f2f7f8052f2c1abf8f7ef1 Mon Sep 17 00:00:00 2001 +From 90dd18c931134b3a872d54e9f51df638f0ce8b4b Mon Sep 17 00:00:00 2001 From: Martchus <martchus@gmx.net> Date: Sun, 18 Sep 2016 18:32:00 +0200 -Subject: [PATCH 22/26] Allow usage of static version with CMake +Subject: [PATCH 22/30] Allow usage of static version with CMake - Fix plugin detection and various details - Allow selecting between dynamic and static Qt versions @@ -18,7 +18,7 @@ Subject: [PATCH 22/26] Allow usage of static version with CMake 6 files changed, 358 insertions(+), 151 deletions(-) diff --git a/mkspecs/features/create_cmake.prf b/mkspecs/features/create_cmake.prf -index 0ff1c6d142..d0d4a7fc1a 100644 +index 461a7fdff5..c4afc5251b 100644 --- a/mkspecs/features/create_cmake.prf +++ b/mkspecs/features/create_cmake.prf @@ -38,7 +38,8 @@ split_incpath { @@ -31,7 +31,7 @@ index 0ff1c6d142..d0d4a7fc1a 100644 !build_pass:QMAKE_SUBSTITUTES += \ cmake_extra_source_includes -@@ -90,6 +91,8 @@ win32:!wince:!static:!staticlib { +@@ -90,6 +91,8 @@ win32:!static:!staticlib { } static|staticlib:CMAKE_STATIC_TYPE = true @@ -815,10 +815,10 @@ index 5baf0fdb10..54345e4117 100644 -list(APPEND Qt5$${CMAKE_MODULE_NAME}_PLUGINS Qt5::$$CMAKE_PLUGIN_NAME) +endif() diff --git a/qmake/generators/makefile.cpp b/qmake/generators/makefile.cpp -index f05a039d2f..831d7c74c0 100644 +index 8ac3a0f647..ed4a1f5c30 100644 --- a/qmake/generators/makefile.cpp +++ b/qmake/generators/makefile.cpp -@@ -997,6 +997,13 @@ MakefileGenerator::writePrlFile(QTextStream &t) +@@ -998,6 +998,13 @@ MakefileGenerator::writePrlFile(QTextStream &t) for (ProStringList::Iterator it = libs.begin(); it != libs.end(); ++it) t << qv(project->values((*it).toKey())); t << endl; @@ -833,7 +833,7 @@ index f05a039d2f..831d7c74c0 100644 } diff --git a/src/corelib/Qt5CoreConfigExtras.cmake.in b/src/corelib/Qt5CoreConfigExtras.cmake.in -index a5ed8b2ea3..3375e1eeea 100644 +index 545b9a3d1e..fd5c947b5f 100644 --- a/src/corelib/Qt5CoreConfigExtras.cmake.in +++ b/src/corelib/Qt5CoreConfigExtras.cmake.in @@ -1,4 +1,10 @@ @@ -900,7 +900,7 @@ index a5ed8b2ea3..3375e1eeea 100644 -set_property(TARGET Qt5::Core PROPERTY INTERFACE_COMPILE_FEATURES cxx_decltype) +set_property(TARGET ${IMPORTED_TARGET_NAME} PROPERTY INTERFACE_COMPILE_FEATURES cxx_decltype) - !!IF contains(QT_CONFIG, reduce_exports) + !!IF qtConfig(reduce_exports) set(QT_VISIBILITY_AVAILABLE \"True\") @@ -162,14 +168,14 @@ if (NOT TARGET Qt5::WinMain) set(_isWin32 $<BOOL:$<TARGET_PROPERTY:WIN32_EXECUTABLE>>) @@ -968,5 +968,5 @@ index 2e32911a64..31567d7da2 100644 ${Qt5Gui_EGL_LIBRARIES} ${Qt5Gui_OPENGL_LIBRARIES} ) -- -2.11.0 +2.11.1 diff --git a/0023-Use-correct-pkg-config-static-flag.patch b/0023-Use-correct-pkg-config-static-flag.patch index 356037840ffa..9c57e11316bc 100644 --- a/0023-Use-correct-pkg-config-static-flag.patch +++ b/0023-Use-correct-pkg-config-static-flag.patch @@ -1,28 +1,26 @@ -From 737579eb780ab8a22e075d8032a5ce983d397064 Mon Sep 17 00:00:00 2001 +From 58f6e5d904464923eebcbb80ec0c774a30b30569 Mon Sep 17 00:00:00 2001 From: Martchus <martchus@gmx.net> Date: Sun, 18 Sep 2016 18:50:21 +0200 -Subject: [PATCH 23/26] Use correct pkg-config --static flag +Subject: [PATCH 23/30] Use correct pkg-config --static flag --- - configure | 5 +++++ - 1 file changed, 5 insertions(+) + configure.pri | 3 +++ + 1 file changed, 3 insertions(+) -diff --git a/configure b/configure -index 9ecc7f9ada..40db8b196a 100755 ---- a/configure -+++ b/configure -@@ -4166,6 +4166,11 @@ if [ -z "$PKG_CONFIG" ]; then - # See if PKG_CONFIG is set in the mkspec: - PKG_CONFIG="`"$CFG_QMAKE_PATH" -qtconf "$QTCONFFILE" -E -nocache -spec "$XQMAKESPEC" "CONFIG=" $DEV_NULL 2>&1 | sed -n -e 's,^PKG_CONFIG = \(.*\),\1,p'`" - [ -n "$PKG_CONFIG" ] && [ "$OPT_VERBOSE" = "yes" ] && echo "Found pkg-config from mkspec: $PKG_CONFIG" -+ -+ if [ "$CFG_SHARED" = "no" ] ; then -+ PKG_CONFIG="$PKG_CONFIG --static" -+ [ "$OPT_VERBOSE" = "yes" ] && echo "Using '$PKG_CONFIG' because we're doing a static build" -+ fi - fi - if [ -z "$PKG_CONFIG" ]; then - PKG_CONFIG=`"$WHICH" pkg-config 2>/dev/null` +diff --git a/configure.pri b/configure.pri +index 0c4b8ebbf8..8afb893e88 100644 +--- a/configure.pri ++++ b/configure.pri +@@ -138,6 +138,9 @@ defineTest(qtConfTest_detectPkgConfig) { + qtLog("Found pkg-config from path: $$pkgConfig") + } + } ++ !isEmpty(pkgConfig):qtConfig(static) { ++ pkgConfig = "$$pkgConfig --static" ++ } + + $$qtConfEvaluate("features.cross_compile") { + # cross compiling, check that pkg-config is set up sanely -- -2.11.0 +2.11.1 diff --git a/0026-Fix-qt5_wrap_ui-macro.patch b/0024-Fix-qt5_wrap_ui-macro.patch index 858792f5d41b..5f383e7eb8df 100644 --- a/0026-Fix-qt5_wrap_ui-macro.patch +++ b/0024-Fix-qt5_wrap_ui-macro.patch @@ -1,7 +1,7 @@ -From 681c27e949a6c2469c4bbd3ea403432b2b6a301d Mon Sep 17 00:00:00 2001 +From 40049fa696cc4b02cab01cf3a79f5ea76b92d364 Mon Sep 17 00:00:00 2001 From: Martchus <martchus@gmx.net> Date: Sun, 4 Dec 2016 20:35:47 +0100 -Subject: [PATCH 26/26] Fix qt5_wrap_ui() macro +Subject: [PATCH 24/30] Fix qt5_wrap_ui() macro See https://github.com/Martchus/PKGBUILDs/issues/11 --- @@ -24,5 +24,5 @@ index f5e7b7f050..18d120f0c7 100644 MAIN_DEPENDENCY ${infile} VERBATIM) list(APPEND ${outfiles} ${outfile}) -- -2.11.0 +2.11.1 diff --git a/0024-Use-shared-static-version-of-MariaDB.patch b/0024-Use-shared-static-version-of-MariaDB.patch deleted file mode 100644 index d20a6e920464..000000000000 --- a/0024-Use-shared-static-version-of-MariaDB.patch +++ /dev/null @@ -1,25 +0,0 @@ -From c207ebb10833de703bbdb23fbbb6863456ae7475 Mon Sep 17 00:00:00 2001 -From: Martchus <martchus@gmx.net> -Date: Sun, 18 Sep 2016 18:56:55 +0200 -Subject: [PATCH 24/26] Use shared/static version of MariaDB - ---- - config.tests/unix/mysql/mysql.pro | 6 +++++- - 1 file changed, 5 insertions(+), 1 deletion(-) - -diff --git a/config.tests/unix/mysql/mysql.pro b/config.tests/unix/mysql/mysql.pro -index 06d1880f08..5dadbfbf2f 100644 ---- a/config.tests/unix/mysql/mysql.pro -+++ b/config.tests/unix/mysql/mysql.pro -@@ -1,3 +1,7 @@ - SOURCES = mysql.cpp - CONFIG -= qt dylib --LIBS += -lmysqlclient -+contains(CONFIG, static) { -+ LIBS += -lmariadbclient -lws2_32 -lpthread -lz -lm -lssl -lcrypto -+} else { -+ LIBS += -lmariadbclient -+} --- -2.11.0 - diff --git a/0025-Ignore-errors-about-missing-feature-static.patch b/0025-Ignore-errors-about-missing-feature-static.patch new file mode 100644 index 000000000000..bf976fd6ed83 --- /dev/null +++ b/0025-Ignore-errors-about-missing-feature-static.patch @@ -0,0 +1,36 @@ +From 4f2f3f020a8fb463532afa4aa9ffeaae211208d5 Mon Sep 17 00:00:00 2001 +From: Martchus <martchus@gmx.net> +Date: Wed, 25 Jan 2017 20:59:54 +0100 +Subject: [PATCH 25/30] Ignore errors about missing feature static + +Not sure why this error occurs, let's hope for the best +--- + mkspecs/features/qt_build_config.prf | 2 +- + mkspecs/features/qt_functions.prf | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/mkspecs/features/qt_build_config.prf b/mkspecs/features/qt_build_config.prf +index 3762c14f98..a58200a297 100644 +--- a/mkspecs/features/qt_build_config.prf ++++ b/mkspecs/features/qt_build_config.prf +@@ -132,5 +132,5 @@ defineTest(qtConfig) { + contains(QT.$${module}.disabled_features, $$1): \ + return(false) + } +- error("Could not find feature $${1}.") ++ !equals($$1, "static"): error("Could not find feature $${1}.") + } +diff --git a/mkspecs/features/qt_functions.prf b/mkspecs/features/qt_functions.prf +index 999cd18154..6bf08ea583 100644 +--- a/mkspecs/features/qt_functions.prf ++++ b/mkspecs/features/qt_functions.prf +@@ -349,5 +349,5 @@ defineTest(qtConfig) { + contains(QT.$${module}.disabled_features, $$1): \ + return(false) + } +- error("Could not find feature $${1}.") ++ !equals($$1, "static"): error("Could not find feature $${1}.") + } +-- +2.11.1 + diff --git a/0025-Use-shared-static-version-of-PostgreSQL.patch b/0025-Use-shared-static-version-of-PostgreSQL.patch deleted file mode 100644 index 6696363f2216..000000000000 --- a/0025-Use-shared-static-version-of-PostgreSQL.patch +++ /dev/null @@ -1,25 +0,0 @@ -From 81894b88cdd2e46c211da26ec94e43b1e34de7f8 Mon Sep 17 00:00:00 2001 -From: Martchus <martchus@gmx.net> -Date: Sun, 18 Sep 2016 18:58:25 +0200 -Subject: [PATCH 25/26] Use shared/static version of PostgreSQL - ---- - config.tests/unix/psql/psql.pro | 6 +++++- - 1 file changed, 5 insertions(+), 1 deletion(-) - -diff --git a/config.tests/unix/psql/psql.pro b/config.tests/unix/psql/psql.pro -index d0f3761bfb..58f163843e 100644 ---- a/config.tests/unix/psql/psql.pro -+++ b/config.tests/unix/psql/psql.pro -@@ -1,3 +1,7 @@ - SOURCES = psql.cpp - CONFIG -= qt dylib --LIBS *= -lpq -+contains(CONFIG, static) { -+ LIBS *= -lpq -lintl -liconv -lssl -lcrypto -lwldap32 -lshfolder -lwsock32 -lws2_32 -lsecur32 -lgdi32 -+} else { -+ LIBS *= -lpq -+} --- -2.11.0 - diff --git a/0026-Enable-anf-fix-use-of-iconv.patch b/0026-Enable-anf-fix-use-of-iconv.patch new file mode 100644 index 000000000000..977ad6acfe4e --- /dev/null +++ b/0026-Enable-anf-fix-use-of-iconv.patch @@ -0,0 +1,82 @@ +From 29b4407c73d05bb98afb3a3a65e987cd825aa7f8 Mon Sep 17 00:00:00 2001 +From: Martchus <martchus@gmx.net> +Date: Wed, 25 Jan 2017 21:08:20 +0100 +Subject: [PATCH 26/30] Enable anf fix use of iconv + +--- + config.tests/unix/gnu-libiconv/gnu-libiconv.cpp | 2 +- + src/corelib/codecs/qiconvcodec.cpp | 7 +++---- + src/corelib/configure.json | 4 ++-- + 3 files changed, 6 insertions(+), 7 deletions(-) + +diff --git a/config.tests/unix/gnu-libiconv/gnu-libiconv.cpp b/config.tests/unix/gnu-libiconv/gnu-libiconv.cpp +index 1276311e08..993a12c7ee 100644 +--- a/config.tests/unix/gnu-libiconv/gnu-libiconv.cpp ++++ b/config.tests/unix/gnu-libiconv/gnu-libiconv.cpp +@@ -46,7 +46,7 @@ int main(int, char **) + { + iconv_t x = iconv_open("", ""); + +- const char *inp; ++ char *inp; + char *outp; + size_t inbytes, outbytes; + iconv(x, &inp, &inbytes, &outp, &outbytes); +diff --git a/src/corelib/codecs/qiconvcodec.cpp b/src/corelib/codecs/qiconvcodec.cpp +index e4fb359f2c..771b1fa9f2 100644 +--- a/src/corelib/codecs/qiconvcodec.cpp ++++ b/src/corelib/codecs/qiconvcodec.cpp +@@ -50,7 +50,6 @@ QT_REQUIRE_CONFIG(iconv); + #include <errno.h> + #include <locale.h> + #include <stdio.h> +-#include <dlfcn.h> + + // unistd.h is needed for the _XOPEN_UNIX macro + #include <unistd.h> +@@ -183,7 +182,7 @@ QString QIconvCodec::convertToUnicode(const char* chars, int len, ConverterState + IconvState *state = *pstate; + size_t inBytesLeft = len; + // best case assumption, each byte is converted into one UTF-16 character, plus 2 bytes for the BOM +-#if !QT_CONFIG(posix_libiconv) ++#if !QT_CONFIG(posix_libiconv) && !defined(Q_OS_WIN) + // GNU doesn't disagree with POSIX :/ + const char *inBytes = chars; + #else +@@ -282,7 +281,7 @@ static bool setByteOrder(iconv_t cd) + size_t outBytesLeft = sizeof buf; + size_t inBytesLeft = sizeof bom; + +-#if !QT_CONFIG(posix_libiconv) ++#if !QT_CONFIG(posix_libiconv) && !defined(Q_OS_WIN) + const char **inBytesPtr = const_cast<const char **>(&inBytes); + #else + char **inBytesPtr = &inBytes; +@@ -304,7 +303,7 @@ QByteArray QIconvCodec::convertFromUnicode(const QChar *uc, int len, ConverterSt + char *outBytes; + size_t inBytesLeft; + +-#if !QT_CONFIG(posix_libiconv) ++#if !QT_CONFIG(posix_libiconv) && !defined(Q_OS_WIN) + const char **inBytesPtr = const_cast<const char **>(&inBytes); + #else + char **inBytesPtr = &inBytes; +diff --git a/src/corelib/configure.json b/src/corelib/configure.json +index 0d1954c3a8..32bbe92f57 100644 +--- a/src/corelib/configure.json ++++ b/src/corelib/configure.json +@@ -263,9 +263,9 @@ + }, + "gnu-libiconv": { + "label": "GNU iconv", +- "enable": "input.iconv == 'gnu'", ++ "enable": "'enabling via -gnu-iconv fails' == 'enabling via -gnu-iconv fails'", + "disable": "input.iconv == 'posix' || input.iconv == 'sun' || input.iconv == 'no'", +- "condition": "!config.win32 && !config.qnx && !config.android && !config.darwin && !features.posix-libiconv && !features.sun-libiconv && libs.gnu_iconv", ++ "condition": "!config.qnx && !config.android && !config.darwin && !features.posix-libiconv && !features.sun-libiconv && libs.gnu_iconv", + "output": [ "privateFeature" ] + }, + "icu": { +-- +2.11.1 + diff --git a/0027-Ignore-failing-pkg-config-test.patch b/0027-Ignore-failing-pkg-config-test.patch new file mode 100644 index 000000000000..5a8f8e0ad0d7 --- /dev/null +++ b/0027-Ignore-failing-pkg-config-test.patch @@ -0,0 +1,25 @@ +From 4388424c4c7545480e4a06421aab9fe096a8d259 Mon Sep 17 00:00:00 2001 +From: Martchus <martchus@gmx.net> +Date: Wed, 25 Jan 2017 21:08:48 +0100 +Subject: [PATCH 27/30] Ignore failing pkg-config test + +Didn't investigate why it fails, let's hope for the best +--- + configure.json | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/configure.json b/configure.json +index 12714da714..adc54e439c 100644 +--- a/configure.json ++++ b/configure.json +@@ -472,7 +472,6 @@ + "pkg-config": { + "label": "Using pkg-config", + "autoDetect": "!config.darwin && !config.win32", +- "condition": "tests.pkg-config", + "output": [ + "publicFeature", + { "type": "publicQtConfig", "negative": true }, +-- +2.11.1 + diff --git a/0028-Include-uiviewsettingsinterop.h-correctly.patch b/0028-Include-uiviewsettingsinterop.h-correctly.patch new file mode 100644 index 000000000000..caa72122de35 --- /dev/null +++ b/0028-Include-uiviewsettingsinterop.h-correctly.patch @@ -0,0 +1,25 @@ +From 37a65bf51b0747f9d306eb5c466f9b34096aa8a6 Mon Sep 17 00:00:00 2001 +From: Martchus <martchus@gmx.net> +Date: Wed, 25 Jan 2017 23:41:16 +0100 +Subject: [PATCH 28/30] Include uiviewsettingsinterop.h correctly + +--- + src/plugins/platforms/windows/qwin10helpers.cpp | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/plugins/platforms/windows/qwin10helpers.cpp b/src/plugins/platforms/windows/qwin10helpers.cpp +index 977bbfd11b..12cccd124b 100644 +--- a/src/plugins/platforms/windows/qwin10helpers.cpp ++++ b/src/plugins/platforms/windows/qwin10helpers.cpp +@@ -57,7 +57,7 @@ + #endif + + #ifdef HAS_UI_VIEW_SETTINGS_INTEROP +-# include <UIViewSettingsInterop.h> ++# include <uiviewsettingsinterop.h> + #endif + + #ifndef HAS_UI_VIEW_SETTINGS_INTEROP +-- +2.11.1 + diff --git a/0029-Hardcode-linker-flags-for-libqwindows.dll.patch b/0029-Hardcode-linker-flags-for-libqwindows.dll.patch new file mode 100644 index 000000000000..bfb961cae8b8 --- /dev/null +++ b/0029-Hardcode-linker-flags-for-libqwindows.dll.patch @@ -0,0 +1,45 @@ +From 511bcf53d5fdf051becd7707e816dc6ad1111790 Mon Sep 17 00:00:00 2001 +From: Martchus <martchus@gmx.net> +Date: Wed, 25 Jan 2017 23:42:30 +0100 +Subject: [PATCH 29/30] Hardcode linker flags for libqwindows.dll + +Otherwise incorrect order of libs leads to linker +errors +--- + src/plugins/platforms/windows/windows.pro | 19 +++++++++++++++---- + 1 file changed, 15 insertions(+), 4 deletions(-) + +diff --git a/src/plugins/platforms/windows/windows.pro b/src/plugins/platforms/windows/windows.pro +index 23168c10dc..e27cf1a248 100644 +--- a/src/plugins/platforms/windows/windows.pro ++++ b/src/plugins/platforms/windows/windows.pro +@@ -1,11 +1,22 @@ + TARGET = qwindows + + QT += \ +- core-private gui-private \ +- eventdispatcher_support-private accessibility_support-private \ +- fontdatabase_support-private theme_support-private ++ core-private gui-private + +-LIBS += -lgdi32 -ldwmapi ++# Fix linker error when building libqwindows.dll by specifying linker flags for ++# required modules manually (otherwise order is messed) ++LIBS += \ ++ -lQt5EventDispatcherSupport \ ++ -lQt5AccessibilitySupport \ ++ -lQt5FontDatabaseSupport \ ++ -lQt5ThemeSupport \ ++ -lfreetype -lole32 -lgdi32 -ldwmapi ++# However, this workaround leads to the necessity of specifying include dirs manually ++INCLUDEPATH += \ ++ $$QT_SOURCE_TREE/include/QtEventDispatcherSupport/5.8.0 \ ++ $$QT_SOURCE_TREE/include/QtAccessibilitySupport/5.8.0 \ ++ $$QT_SOURCE_TREE/include/QtFontDatabaseSupport/5.8.0 \ ++ $$QT_SOURCE_TREE/include/QtThemeSupport/5.8.0 + + include(windows.pri) + +-- +2.11.1 + diff --git a/0030-Prevent-qmake-from-messing-static-lib-dependencies.patch b/0030-Prevent-qmake-from-messing-static-lib-dependencies.patch new file mode 100644 index 000000000000..f330e92d6745 --- /dev/null +++ b/0030-Prevent-qmake-from-messing-static-lib-dependencies.patch @@ -0,0 +1,43 @@ +From 15b374d87ff91c3a20d9022d5036a97c1252bb98 Mon Sep 17 00:00:00 2001 +From: Martchus <martchus@gmx.net> +Date: Tue, 7 Feb 2017 18:25:28 +0100 +Subject: [PATCH 30/30] Prevent qmake from messing static lib dependencies + +In particular, it messes resolving cyclic dependency between +static freetype2 and harfbuzz +--- + qmake/generators/unix/unixmake.cpp | 3 +++ + qmake/generators/win32/winmakefile.cpp | 3 +++ + 2 files changed, 6 insertions(+) + +diff --git a/qmake/generators/unix/unixmake.cpp b/qmake/generators/unix/unixmake.cpp +index 349dcd2f40..f6d3d1fa29 100644 +--- a/qmake/generators/unix/unixmake.cpp ++++ b/qmake/generators/unix/unixmake.cpp +@@ -394,6 +394,9 @@ UnixMakefileGenerator::fixLibFlag(const ProString &lib) + bool + UnixMakefileGenerator::findLibraries(bool linkPrl, bool mergeLflags) + { ++ if(project->isActiveConfig("staticlib")) { ++ return false; // prevent qmake from messing static lib dependencies ++ } + QList<QMakeLocalFileName> libdirs, frameworkdirs; + int libidx = 0, fwidx = 0; + for (const ProString &dlib : project->values("QMAKE_DEFAULT_LIBDIRS")) +diff --git a/qmake/generators/win32/winmakefile.cpp b/qmake/generators/win32/winmakefile.cpp +index e6338546bb..2407d26a5a 100644 +--- a/qmake/generators/win32/winmakefile.cpp ++++ b/qmake/generators/win32/winmakefile.cpp +@@ -87,6 +87,9 @@ Win32MakefileGenerator::findLibraries(bool linkPrl, bool mergeLflags) + impexts.append(project->values("QMAKE_EXTENSION_IMPORTLIB")); + impexts.append(project->values("QMAKE_EXTENSION_STATICLIB")); + } ++ if(project->isActiveConfig("staticlib")) { ++ return false; // prevent qmake from messing static lib dependencies ++ } + QList<QMakeLocalFileName> dirs; + static const char * const lflags[] = { "QMAKE_LIBS", "QMAKE_LIBS_PRIVATE", 0 }; + for (int i = 0; lflags[i]; i++) { +-- +2.11.1 + @@ -77,7 +77,7 @@ isNoOpenGL() { } pkgname=mingw-w64-qt5-base -pkgver=5.7.1 +pkgver=5.8.0 pkgrel=1 pkgdesc='A cross-platform application and UI framework (mingw-w64)' # The static variant doesn't contain any executables which need to be executed on the build machine @@ -87,26 +87,26 @@ license=('GPL3' 'LGPL3' 'FDL' 'custom') depends=('mingw-w64-crt' 'mingw-w64-zlib' 'mingw-w64-libjpeg-turbo' 'mingw-w64-sqlite' 'mingw-w64-libpng' 'mingw-w64-openssl' 'mingw-w64-dbus' 'mingw-w64-harfbuzz' 'mingw-w64-pcre') -groups=('mingw-w64-qt' 'mingw-w64-qt5') +groups=('mingw-w64-qt5') optdepends=('mingw-w64-postgresql: PostgreSQL support' 'mingw-w64-mariadb-connector-c: MySQL support') makedepends=('mingw-w64-gcc' 'mingw-w64-postgresql' 'mingw-w64-mariadb-connector-c' 'mingw-w64-pkg-config') -options=(!strip !buildflags staticlibs !emptydirs) +options=('!strip' '!buildflags' 'staticlibs' '!emptydirs') _pkgfqn="qtbase-opensource-src-${pkgver}" source=("https://download.qt.io/official_releases/qt/${pkgver:0:3}/${pkgver}/submodules/${_pkgfqn}.tar.xz" - '0001-Fix-qwindows-plugin-linking-with-system-freetype.patch' - '0002-Fix-oci-config-test-on-windows.patch' - '0003-Don-t-set-QT_NO_SYSTEMSEMAPHORE-for-Windows.patch' - '0004-Fix-building-mysql-driver-under-mingw.patch' - '0005-Support-ANGLE-switches-via-configure-shell-script.patch' - '0006-Use-external-ANGLE-library.patch' - '0007-Fix-too-many-sections-assemler-error-in-OpenGL-facto.patch' - '0008-Make-sure-.pc-files-are-installed-correctly.patch' - '0009-Don-t-add-resource-files-to-LIBS-parameter.patch' - '0010-Prevent-debug-library-names-in-pkg-config-files.patch' - '0011-Fix-linking-against-static-D-Bus.patch' - '0012-Adjust-win32-g-mkspecs-profile.patch' - '0013-Fix-linking-against-external-harfbuzz.patch' - '0014-Fix-linking-against-static-pcre.patch' + '0001-Add-profile-for-cross-compilation-with-mingw-w64.patch' + '0002-Ensure-GLdouble-is-defined-when-using-dynamic-OpenGL.patch' + '0003-Use-external-ANGLE-library.patch' + '0004-Fix-too-many-sections-assemler-error-in-OpenGL-facto.patch' + '0005-Make-sure-.pc-files-are-installed-correctly.patch' + '0006-Don-t-add-resource-files-to-LIBS-parameter.patch' + '0007-Prevent-debug-library-names-in-pkg-config-files.patch' + '0008-Fix-linking-against-shared-static-libpng.patch' + '0009-Fix-linking-against-static-D-Bus.patch' + '0010-Fix-linking-against-static-freetype2.patch' + '0011-Fix-linking-against-static-harfbuzz.patch' + '0012-Fix-linking-against-static-pcre.patch' + '0013-Fix-linking-against-shared-static-MariaDB.patch' + '0014-Fix-linking-against-shared-static-PostgreSQL.patch' '0015-Rename-qtmain-to-qt5main.patch' '0016-Build-dynamic-host-libraries.patch' '0017-Enable-rpath-for-build-tools.patch' @@ -116,86 +116,44 @@ source=("https://download.qt.io/official_releases/qt/${pkgver:0:3}/${pkgver}/sub '0021-Merge-shared-and-static-library-trees.patch' '0022-Allow-usage-of-static-version-with-CMake.patch' '0023-Use-correct-pkg-config-static-flag.patch' - '0024-Use-shared-static-version-of-MariaDB.patch' - '0025-Use-shared-static-version-of-PostgreSQL.patch' - '0001-Fix-qwindows-plugin-linking-with-system-freetype.patch' - '0002-Fix-oci-config-test-on-windows.patch' - '0003-Don-t-set-QT_NO_SYSTEMSEMAPHORE-for-Windows.patch' - '0004-Fix-building-mysql-driver-under-mingw.patch' - '0005-Support-ANGLE-switches-via-configure-shell-script.patch' - '0006-Use-external-ANGLE-library.patch' - '0007-Fix-too-many-sections-assemler-error-in-OpenGL-facto.patch' - '0008-Make-sure-.pc-files-are-installed-correctly.patch' - '0009-Don-t-add-resource-files-to-LIBS-parameter.patch' - '0010-Prevent-debug-library-names-in-pkg-config-files.patch' - '0011-Fix-linking-against-static-D-Bus.patch' - '0012-Adjust-win32-g-mkspecs-profile.patch' - '0013-Fix-linking-against-external-harfbuzz.patch' - '0014-Fix-linking-against-static-pcre.patch' - '0015-Rename-qtmain-to-qt5main.patch' - '0016-Build-dynamic-host-libraries.patch' - '0017-Enable-rpath-for-build-tools.patch' - '0018-Use-system-zlib-for-build-tools.patch' - '0019-Disable-determing-default-include-and-lib-dirs-at-qm.patch' - '0020-Use-.dll.a-as-import-lib-extension.patch' - '0021-Merge-shared-and-static-library-trees.patch' - '0022-Allow-usage-of-static-version-with-CMake.patch' - '0023-Use-correct-pkg-config-static-flag.patch' - '0024-Use-shared-static-version-of-MariaDB.patch' - '0025-Use-shared-static-version-of-PostgreSQL.patch' - '0026-Fix-qt5_wrap_ui-macro.patch') -md5sums=('f0809befe04160fbb73bbf38a06a2073' - '14ea9353fcc9234a9c7cb98ef14050a3' - '34c9df86a43132f58b18bd3061305b36' - '94f3ec6cdb456cc9b0535bd549cf2859' - 'eb118e7a01ff8e39f608e715758ac3dd' - 'c5184ae70974aaeaf5e1996dc7af6ec0' - '917a3439afa97afab1b0b722082d640b' - 'bea9eb1a5be8e5e1ee2592007b112fe5' - '281a81a7c32cc2f4bfeb83f5bea29d59' - 'ec262ef6bcf2f12832f83aad30d2f728' - '10c24aec6ca3743d01ca7e0f2704b024' - 'bfa3574a0d44f831e412befba235b2ca' - '366b8209ba35b00e2fe4ddcf448ed015' - '0c17f618cbee73a49d7829da7c816cd7' - '11f26a2237acd5e78d5a3db4de2d6d90' - '632765f81a4b72b540376255a10b4c2e' - '1f57d40dc492822f2e931bdd3a0b7435' - '758afe3653d7ce126ebae03e6a8f222f' - 'd616bd0fd1ac1ae0d749f93fcba0aeb1' - '6847671b013c249aaa2dd7d7e646e4e6' - '9e3c6cee969a55b15558f6a46f7aad20' - '7bf4cf112551bea4c4d3dd91ed7e1461' - '97ece0bb54a249aa0a1fc662eedc93de' - '4bdbf113772fdfe4cc6da53c866216b2' - '399555789f729477d65861179efaf9e3' - '295d83b50278474289727dc49a688e95' - '14ea9353fcc9234a9c7cb98ef14050a3' - '34c9df86a43132f58b18bd3061305b36' - '94f3ec6cdb456cc9b0535bd549cf2859' - 'eb118e7a01ff8e39f608e715758ac3dd' - 'c5184ae70974aaeaf5e1996dc7af6ec0' - '917a3439afa97afab1b0b722082d640b' - 'bea9eb1a5be8e5e1ee2592007b112fe5' - '281a81a7c32cc2f4bfeb83f5bea29d59' - 'ec262ef6bcf2f12832f83aad30d2f728' - '10c24aec6ca3743d01ca7e0f2704b024' - 'bfa3574a0d44f831e412befba235b2ca' - '366b8209ba35b00e2fe4ddcf448ed015' - '0c17f618cbee73a49d7829da7c816cd7' - '11f26a2237acd5e78d5a3db4de2d6d90' - '632765f81a4b72b540376255a10b4c2e' - '1f57d40dc492822f2e931bdd3a0b7435' - '758afe3653d7ce126ebae03e6a8f222f' - 'd616bd0fd1ac1ae0d749f93fcba0aeb1' - '6847671b013c249aaa2dd7d7e646e4e6' - '9e3c6cee969a55b15558f6a46f7aad20' - '7bf4cf112551bea4c4d3dd91ed7e1461' - '97ece0bb54a249aa0a1fc662eedc93de' - '4bdbf113772fdfe4cc6da53c866216b2' - '399555789f729477d65861179efaf9e3' - '295d83b50278474289727dc49a688e95' - '541413adc439b0650ad236f13c47e28e') + '0024-Fix-qt5_wrap_ui-macro.patch' + '0025-Ignore-errors-about-missing-feature-static.patch' + '0026-Enable-anf-fix-use-of-iconv.patch' + '0027-Ignore-failing-pkg-config-test.patch' + '0028-Include-uiviewsettingsinterop.h-correctly.patch' + '0029-Hardcode-linker-flags-for-libqwindows.dll.patch' + '0030-Prevent-qmake-from-messing-static-lib-dependencies.patch') +md5sums=('6e1f7f6fb6333eb66e563b175c4e87e9' + '4870da8aa8e01334f0daf09be09e7f32' + 'e86ad52f472a4c4a70f9061b5474b947' + '4c7c1df53c99182e296932d8cf398c5f' + 'd18a5d3fc8570b03aed954a72b68739a' + '685860a2ac1410c49ab82648bc24f510' + 'e1a1ca7caf93e8033a1915af457b7b98' + 'bd7c1c99dca91ed604c84cf9632f7e0d' + '7fbfcbb581e07563ab87e17c33a6b48b' + 'df541beb0bc0cc8054aae93f462c5923' + '4711804aaf43ec810e70898c32948237' + '3d4294c3279e69864fcdf87b6f852122' + '55c3593dc03079c794e97ed88136845b' + '5d04636091f7768b940d090178997384' + 'd4cc6c6394c795a2e6708e797e49b616' + '8e234c3b077a8f942ee9a7e8209bfc79' + '6685fe994d64f3e1b2a4bfe6a645bb6a' + 'a0fa368726934c21d3a0e8a5a61023c9' + '3dc9e1efaed892d0eb24dfa68769d0f2' + '53c06c4a646a9572b40982c4e29b5ce4' + '61f4848e9e0a8a6e183458c871070a53' + 'fd2e8c22fdbb3f9415ee500bde5980fc' + '6a7539edc09f66bae5dfad7e3d210614' + '440f7d221985abcb781a519d1bc26ee7' + '504e6a091aa8b35a5b6b5a8c77b7d4e3' + 'e85f6106f31bcd8da1213f670575941a' + '4046dcb53c3a6c735f6d7d4b866d80a0' + 'c964ad83bff270380aa5ac0991e57c10' + '3921c665e46cbe39e012432db704089d' + '8f47783a83f54c82650502a120af4f16' + '2bc5f6f3d2c1cd0e2590a8e8e1cf0ff1') _architectures='i686-w64-mingw32 x86_64-w64-mingw32' #_architectures='x86_64-w64-mingw32 i686-w64-mingw32' @@ -259,6 +217,7 @@ build() { unset CFLAGS unset CXXFLAGS unset LDFLAGS + unset PKG_CONFIG_PATH for _arch in ${_architectures}; do # Phonon is disabled for now because we lack the directx headers @@ -272,14 +231,13 @@ build() { # (sloppiness must be set to pch_defines,time_macros in ccache config) local qt_configure_args="\ - -xplatform win32-g++ \ + -xplatform mingw-w64-g++ \ -optimized-qmake \ -verbose \ -opensource \ -confirm-license \ -force-pkg-config \ -force-debug-info \ - -audio-backend \ -system-zlib \ -system-libpng \ -system-libjpeg \ @@ -288,11 +246,14 @@ build() { -system-harfbuzz \ -system-pcre \ -no-fontconfig \ - -iconv \ + -sql-mysql \ + -sql-psql \ + -sql-sqlite \ -openssl \ -dbus-linked \ -no-glib \ -no-icu \ + -iconv \ -release \ -nomake examples \ -make tools \ @@ -329,29 +290,16 @@ build() { qt_configure_args+=' -opengl dynamic' else msg2 'Using ANGLE as OpenGL backend' - qt_configure_args+=' -opengl angle' + qt_configure_args+=' -angle' fi # GL_GLEXT_PROTOTYPES must be defined to enable declarations of GLES functions qt_configure_args+=' -DGL_GLEXT_PROTOTYPES' fi - unset PKG_CONFIG_PATH - - # Fix MySQL - if ! isStatic; then - export QT_LFLAGS_MYSQL="-L/usr/${_arch}/lib -lmysql" - fi - # Qt doesn't detect mysql correctly, so use this: - export QT_CFLAGS_MYSQL="-I/usr/${_arch}/include/mariadb" - # Hardcode MySQL flags into configure (really nice solution :( ) - sed -e "s|^QT_CFLAGS_MYSQL=.*$|QT_CFLAGS_MYSQL=\"${QT_CFLAGS_MYSQL}\"|g" -i "${srcdir}/${_pkgfqn}/configure" - sed -e "s|^QT_LFLAGS_MYSQL=.*$|QT_LFLAGS_MYSQL=\"${QT_LFLAGS_MYSQL}\"|g" -i "${srcdir}/${_pkgfqn}/configure" - #sed -e "s|^QT_LFLAGS_MYSQL_R=.*$|QT_LFLAGS_MYSQL_R=\"${QT_LFLAGS_MYSQL_R}\"|g" -i "${srcdir}/${_pkgfqn}/configure" - qt_configure_args_mysql="-mysql_config /this/file/should/not/exist" - # TODO: test whether this workaround is still requried + # Fix MariaDB + qt_configure_args+=" -I/usr/${_arch}/include/mariadb" mkdir -p ../build-${_arch} && pushd ../build-${_arch} - if isStatic; then ../${_pkgfqn}/configure -static $qt_configure_args $qt_configure_args_mysql make @@ -378,11 +326,16 @@ package() { # Drop Qt5Bootstrap and libraries which are only provided as static lib # and are hence already present in shared build (such as Qt5OpenGLExtensions) rm -f "${pkgdir}/usr/${_arch}/lib/"{lib,}qt5main* \ + "${pkgdir}/usr/${_arch}/lib/"{lib,}Qt5AccessibilitySupport* \ + "${pkgdir}/usr/${_arch}/lib/"{lib,}Qt5DeviceDiscoverySupport* \ + "${pkgdir}/usr/${_arch}/lib/"{lib,}Qt5EventDispatcherSupport* \ + "${pkgdir}/usr/${_arch}/lib/"{lib,}Qt5FbSupport* \ + "${pkgdir}/usr/${_arch}/lib/"{lib,}Qt5FontDatabaseSupport* \ + "${pkgdir}/usr/${_arch}/lib/"{lib,}Qt5PlatformCompositorSupport* \ + "${pkgdir}/usr/${_arch}/lib/"{lib,}Qt5ThemeSupport* \ "${pkgdir}/usr/${_arch}/lib/"{lib,}Qt5OpenGLExtensions* \ "${pkgdir}/usr/${_arch}/lib/"{lib,}Qt5PlatformSupport* \ "${pkgdir}/usr/${_arch}/lib/"libQt5Bootstrap* \ - "${pkgdir}/usr/${_arch}/lib/"libqtpng.a \ - "${pkgdir}/usr/${_arch}/lib/"qtpng.static.prl # Also ensure config files don't conflict with shared version pushd "${pkgdir}/usr/${_arch}/lib/cmake" |