--- /dev/null
+From 0bf90de93b9fe21df32319e27b2507154fa8a21d Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?J=C3=B6rg=20Krause?= <joerg.krause@embedded.rocks>
+Date: Fri, 15 Apr 2016 00:37:26 +0200
+Subject: [PATCH] Fix for platform socklen_t on other C libraries than glibc
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+This helps to make sure that QT_SOCKLEN_T is defined to be 'int'
+only when its glibc < 2 and not also for the libraries which may define
+it as per standards but are not glibc, e.g. musl.
+
+This patch is adapted from Qt5 [1].
+
+[1]
+https://github.com/qtproject/qtbase/commit/813f468a14fb84af43c1f8fc0a1430277358eba2
+
+Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
+---
+ mkspecs/linux-g++/qplatformdefs.h | 6 +++---
+ 1 file changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/mkspecs/linux-g++/qplatformdefs.h b/mkspecs/linux-g++/qplatformdefs.h
+index de751dd..d4146ed 100644
+--- a/mkspecs/linux-g++/qplatformdefs.h
++++ b/mkspecs/linux-g++/qplatformdefs.h
+@@ -86,10 +86,10 @@
+
+ #undef QT_SOCKLEN_T
+
+-#if defined(__GLIBC__) && (__GLIBC__ >= 2)
+-#define QT_SOCKLEN_T socklen_t
+-#else
++#if defined(__GLIBC__) && (__GLIBC__ < 2)
+ #define QT_SOCKLEN_T int
++#else
++#define QT_SOCKLEN_T socklen_t
+ #endif
+
+ #if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 500)
+--
+2.8.0
+
+++ /dev/null
-From 7a912823158a4113256c3113a34c38d6b241d275 Mon Sep 17 00:00:00 2001
-From: Alexey Brodkin <abrodkin@synopsys.com>
-Date: Wed, 13 Jan 2016 20:15:36 +0300
-Subject: [PATCH] Fix library inclusion order when building statically
-
-When building application statically it's important to keep
-libraries we're linking against in order. Otherwise if libA depends on
-libB but it is mentioned after libB in linker command line
-there will be unresolved symbols.
-
-Consider real example - configuration of Qt with glib for static build.
-Initially reported by Buildroot autobuilder here:
-http://autobuild.buildroot.net/results/174/174c6e47eb761f9897275b6fedff742ace2f3081
-
-What happens here:
-
-[1] Qt's configuration script tries to build glib test app
- (in config.tests/unix/glib)
-
-[2] For that it first asks which libs to use during linkage this way:
- QT_LIBS_GLIB=`$PKG_CONFIG --libs glib-2.0 gthread-2.0 2>/dev/null`
-
- In our case we're getting something like this:
- -L/.../sysroot/usr/lib -lintl -lgthread-2.0 -pthread -lglib-2.0 \
- -lintl -pthread -lintl
-
- Note "-lintl" is mentioned 3 times because libgthread depends on
- libthread and both of them plus libglib all depend on libintl - so
- we're getting "lintl" for each separate library mentioned above.
-
-[3] Now we execute "compileTest" for real heavy lifting this way:
- compileTest unix/glib "Glib" $QT_CFLAGS_GLIB $QT_LIBS_GLIB ...
-
-[4] compileTest (the one for unix) parses command-line passed to it
- groups all entries with "-l" prefix and puts them in LFLAGS
- variable. And finally executes qmake passing it that kind of
- construction:
- $OUTDIR/bin/qmake ..."LIBS*=$LFLAGS"
-
-[5] When qmake sees construction "MYVAR*=MYVAL" it populates MYVAR with
- unique values from MYVAL string.
-
-[6] As a result qmake generated Makefile with the following:
- LIBS = $(SUBLIBS) -pthread -L/.../sysroot/usr/lib -lintl -lgthread-2.0 \
- -lglib-2.0
-
-[7] And essentially on attempt to link glib test app a failure happens
- because libglib needs libintl, i.e. "-lintl" must follow "-lglib-2.0":
--------------------->8------------------
-linking glib
-
-g++ -static -Wl,-O1 -o glib glib.o -pthread -L/.../sysroot/usr/lib \
--lintl -lgthread-2.0 -lglib-2.0
-
-/.../sysroot/usr/lib/libglib-2.0.a(libglib_2_0_la-ggettext.o): In function '_g_dgettext_should_translate':
-ggettext.c:(.text+0x28): undefined reference to `libintl_textdomain'
-ggettext.c:(.text+0x36): undefined reference to `libintl_gettext'
-/.../sysroot/usr/lib/libglib-2.0.a(libglib_2_0_la-ggettext.o): In function `ensure_gettext_initialized':
-ggettext.c:(.text+0xe6): undefined reference to `libintl_bindtextdomain'
-ggettext.c:(.text+0xf6): undefined reference to `libintl_bind_textdomain_codeset'
-/.../sysroot/usr/lib/libglib-2.0.a(libglib_2_0_la-ggettext.o): In function `g_dgettext':
-ggettext.c:(.text+0x148): undefined reference to `libintl_dgettext'
-/.../sysroot/usr/lib/libglib-2.0.a(libglib_2_0_la-ggettext.o): In function `g_dcgettext':
-ggettext.c:(.text+0x2dc): undefined reference to `libintl_dcgettext'
-/.../sysroot/usr/lib/libglib-2.0.a(libglib_2_0_la-ggettext.o): In function `g_dngettext':
-ggettext.c:(.text+0x32a): undefined reference to `libintl_dngettext'
-collect2: error: ld returned 1 exit status
-Makefile:99: recipe for target 'glib' failed
-make: *** [glib] Error 1
-
-Glib disabled.
-Glib support cannot be enabled due to functionality tests!
- Turn on verbose messaging (-v) to ./configure to see the final report.
- If you believe this message is in error you may use the continue
- switch (-continue) to ./configure to continue.
--------------------->8------------------
-
-Solution to this problem is simple we have to pass all libraries exactly
-in order of their initial mention by upper layers.
-
-Change-Id: I7ff00901031a8eb85b4fbd7889b0e0c02be806bb
-
-This fix was sent to Qt Gerrit for review here:
-https://codereview.qt-project.org/#/c/145967/
-
----
- config.tests/unix/compile.test | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/config.tests/unix/compile.test b/config.tests/unix/compile.test
-index f484f03..dac0a4f 100755
---- a/config.tests/unix/compile.test
-+++ b/config.tests/unix/compile.test
-@@ -73,7 +73,7 @@ test -r Makefile && $MAKE distclean >/dev/null 2>&1
- rm -f "$EXE" "${EXE}.exe"
-
- echo "QT_BUILD_TREE = $OUTDIR" > "$OUTDIR/$TEST/.qmake.cache"
--"$OUTDIR/bin/qmake" -spec "$QMKSPEC" "CONFIG+=$QMAKE_CONFIG" "CONFIG-=debug_and_release" "LIBS*=$LFLAGS" "LIBS+=$MAC_ARCH_LFLAGS" "INCLUDEPATH*=$INCLUDEPATH" "QMAKE_CXXFLAGS*=$CXXFLAGS" "QMAKE_CXXFLAGS+=$MAC_ARCH_CXXFLAGS" "$SRCDIR/$TEST/$EXE.pro" -o "$OUTDIR/$TEST/Makefile"
-+"$OUTDIR/bin/qmake" -spec "$QMKSPEC" "CONFIG+=$QMAKE_CONFIG" "CONFIG-=debug_and_release" "LIBS=$LFLAGS" "LIBS+=$MAC_ARCH_LFLAGS" "INCLUDEPATH*=$INCLUDEPATH" "QMAKE_CXXFLAGS*=$CXXFLAGS" "QMAKE_CXXFLAGS+=$MAC_ARCH_CXXFLAGS" "$SRCDIR/$TEST/$EXE.pro" -o "$OUTDIR/$TEST/Makefile"
-
- if [ "$VERBOSE" = "yes" ]; then
- $MAKE
---
-2.4.3
-
+++ /dev/null
-From 0bf90de93b9fe21df32319e27b2507154fa8a21d Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?J=C3=B6rg=20Krause?= <joerg.krause@embedded.rocks>
-Date: Fri, 15 Apr 2016 00:37:26 +0200
-Subject: [PATCH] Fix for platform socklen_t on other C libraries than glibc
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-This helps to make sure that QT_SOCKLEN_T is defined to be 'int'
-only when its glibc < 2 and not also for the libraries which may define
-it as per standards but are not glibc, e.g. musl.
-
-This patch is adapted from Qt5 [1].
-
-[1]
-https://github.com/qtproject/qtbase/commit/813f468a14fb84af43c1f8fc0a1430277358eba2
-
-Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
----
- mkspecs/linux-g++/qplatformdefs.h | 6 +++---
- 1 file changed, 3 insertions(+), 3 deletions(-)
-
-diff --git a/mkspecs/linux-g++/qplatformdefs.h b/mkspecs/linux-g++/qplatformdefs.h
-index de751dd..d4146ed 100644
---- a/mkspecs/linux-g++/qplatformdefs.h
-+++ b/mkspecs/linux-g++/qplatformdefs.h
-@@ -86,10 +86,10 @@
-
- #undef QT_SOCKLEN_T
-
--#if defined(__GLIBC__) && (__GLIBC__ >= 2)
--#define QT_SOCKLEN_T socklen_t
--#else
-+#if defined(__GLIBC__) && (__GLIBC__ < 2)
- #define QT_SOCKLEN_T int
-+#else
-+#define QT_SOCKLEN_T socklen_t
- #endif
-
- #if defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 500)
---
-2.8.0
-
--- /dev/null
+From 438f088ad520ac91ae47dba9a515ab0d1088c89c Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?J=C3=B6rg=20Krause?= <joerg.krause@embedded.rocks>
+Date: Fri, 15 Apr 2016 03:32:02 +0200
+Subject: [PATCH] Link with -ldl option only when it is supported
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+`-ldl` option is used unconditionally in `QMAKE_LIBS_DYNLOAD` while libdl is
+not supported when libc is static. As the value of `QMAKE_LIBS_DYNLOAD` goes
+into 'Libs.private' field of the pkgconfig files created by qmake, static
+linking with qt will fail with:
+ /usr/bin/ld: cannot find -ldl
+
+Fix this issue by adding a build test to configure to check if libdl is
+supported. `QMAKE_LIBS_DYNLOAD` in "src/corelib/plugin/plugin.pri" is now used
+only if libdl is available.
+
+Backported from Qt5:
+https://github.com/qtproject/qtbase/commit/f669ea0d54302de31456d57286aa0e4ca1443e98
+
+Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
+---
+ config.tests/unix/libdl/libdl.cpp | 39 +++++++++++++++++++++++++++++++++++++++
+ config.tests/unix/libdl/libdl.pro | 3 +++
+ configure | 6 ++++++
+ src/corelib/plugin/plugin.pri | 2 +-
+ 4 files changed, 49 insertions(+), 1 deletion(-)
+ create mode 100644 config.tests/unix/libdl/libdl.cpp
+ create mode 100644 config.tests/unix/libdl/libdl.pro
+
+diff --git a/config.tests/unix/libdl/libdl.cpp b/config.tests/unix/libdl/libdl.cpp
+new file mode 100644
+index 0000000..28a8233
+--- /dev/null
++++ b/config.tests/unix/libdl/libdl.cpp
+@@ -0,0 +1,39 @@
++/****************************************************************************
++**
++** Copyright (C) 2015 The Qt Company Ltd.
++** Contact: http://www.qt.io/licensing/
++**
++** This file is part of the config.tests of the Qt Toolkit.
++**
++** $QT_BEGIN_LICENSE:LGPL21$
++** 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 http://www.qt.io/terms-conditions. For further
++** information use the contact form at http://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 2.1 or version 3 as published by the Free
++** Software Foundation and appearing in the file LICENSE.LGPLv21 and
++** LICENSE.LGPLv3 included in the packaging of this file. Please review the
++** following information to ensure the GNU Lesser General Public License
++** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
++** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
++**
++** As a special exception, The Qt Company gives you certain additional
++** rights. These rights are described in The Qt Company LGPL Exception
++** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
++**
++** $QT_END_LICENSE$
++**
++****************************************************************************/
++
++#include <dlfcn.h>
++
++int main(int, char **)
++{
++ dlopen(0, 0);
++}
+diff --git a/config.tests/unix/libdl/libdl.pro b/config.tests/unix/libdl/libdl.pro
+new file mode 100644
+index 0000000..a643934
+--- /dev/null
++++ b/config.tests/unix/libdl/libdl.pro
+@@ -0,0 +1,3 @@
++SOURCES = libdl.cpp
++CONFIG -= qt dylib
++LIBS += -ldl
+\ No newline at end of file
+diff --git a/configure b/configure
+index 10ad7ca..1c70691 100755
+--- a/configure
++++ b/configure
+@@ -5506,6 +5506,12 @@ if [ "$CFG_LIBPNG" = "auto" ]; then
+ fi
+ fi
+
++# detect dl
++if ! compileTest unix/libdl "libdl"; then
++ QMakeVar add DEFINES QT_NO_DYNAMIC_LIBRARY
++ QMAKE_CONFIG="$QMAKE_CONFIG no-libdl"
++fi
++
+ # detect accessibility
+ if [ "$CFG_ACCESSIBILITY" = "auto" ]; then
+ if [ "$XPLATFORM_SYMBIAN" = "yes" ]; then
+diff --git a/src/corelib/plugin/plugin.pri b/src/corelib/plugin/plugin.pri
+index eb7a7f7..c342f2e 100644
+--- a/src/corelib/plugin/plugin.pri
++++ b/src/corelib/plugin/plugin.pri
+@@ -32,4 +32,4 @@ integrity {
+ SOURCES += plugin/qlibrary_unix.cpp
+ }
+
+-LIBS_PRIVATE += $$QMAKE_LIBS_DYNLOAD
++!no-libdl: LIBS_PRIVATE += $$QMAKE_LIBS_DYNLOAD
+--
+2.8.0
+
+++ /dev/null
-From 438f088ad520ac91ae47dba9a515ab0d1088c89c Mon Sep 17 00:00:00 2001
-From: =?UTF-8?q?J=C3=B6rg=20Krause?= <joerg.krause@embedded.rocks>
-Date: Fri, 15 Apr 2016 03:32:02 +0200
-Subject: [PATCH] Link with -ldl option only when it is supported
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-`-ldl` option is used unconditionally in `QMAKE_LIBS_DYNLOAD` while libdl is
-not supported when libc is static. As the value of `QMAKE_LIBS_DYNLOAD` goes
-into 'Libs.private' field of the pkgconfig files created by qmake, static
-linking with qt will fail with:
- /usr/bin/ld: cannot find -ldl
-
-Fix this issue by adding a build test to configure to check if libdl is
-supported. `QMAKE_LIBS_DYNLOAD` in "src/corelib/plugin/plugin.pri" is now used
-only if libdl is available.
-
-Backported from Qt5:
-https://github.com/qtproject/qtbase/commit/f669ea0d54302de31456d57286aa0e4ca1443e98
-
-Signed-off-by: Jörg Krause <joerg.krause@embedded.rocks>
----
- config.tests/unix/libdl/libdl.cpp | 39 +++++++++++++++++++++++++++++++++++++++
- config.tests/unix/libdl/libdl.pro | 3 +++
- configure | 6 ++++++
- src/corelib/plugin/plugin.pri | 2 +-
- 4 files changed, 49 insertions(+), 1 deletion(-)
- create mode 100644 config.tests/unix/libdl/libdl.cpp
- create mode 100644 config.tests/unix/libdl/libdl.pro
-
-diff --git a/config.tests/unix/libdl/libdl.cpp b/config.tests/unix/libdl/libdl.cpp
-new file mode 100644
-index 0000000..28a8233
---- /dev/null
-+++ b/config.tests/unix/libdl/libdl.cpp
-@@ -0,0 +1,39 @@
-+/****************************************************************************
-+**
-+** Copyright (C) 2015 The Qt Company Ltd.
-+** Contact: http://www.qt.io/licensing/
-+**
-+** This file is part of the config.tests of the Qt Toolkit.
-+**
-+** $QT_BEGIN_LICENSE:LGPL21$
-+** 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 http://www.qt.io/terms-conditions. For further
-+** information use the contact form at http://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 2.1 or version 3 as published by the Free
-+** Software Foundation and appearing in the file LICENSE.LGPLv21 and
-+** LICENSE.LGPLv3 included in the packaging of this file. Please review the
-+** following information to ensure the GNU Lesser General Public License
-+** requirements will be met: https://www.gnu.org/licenses/lgpl.html and
-+** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
-+**
-+** As a special exception, The Qt Company gives you certain additional
-+** rights. These rights are described in The Qt Company LGPL Exception
-+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
-+**
-+** $QT_END_LICENSE$
-+**
-+****************************************************************************/
-+
-+#include <dlfcn.h>
-+
-+int main(int, char **)
-+{
-+ dlopen(0, 0);
-+}
-diff --git a/config.tests/unix/libdl/libdl.pro b/config.tests/unix/libdl/libdl.pro
-new file mode 100644
-index 0000000..a643934
---- /dev/null
-+++ b/config.tests/unix/libdl/libdl.pro
-@@ -0,0 +1,3 @@
-+SOURCES = libdl.cpp
-+CONFIG -= qt dylib
-+LIBS += -ldl
-\ No newline at end of file
-diff --git a/configure b/configure
-index 10ad7ca..1c70691 100755
---- a/configure
-+++ b/configure
-@@ -5506,6 +5506,12 @@ if [ "$CFG_LIBPNG" = "auto" ]; then
- fi
- fi
-
-+# detect dl
-+if ! compileTest unix/libdl "libdl"; then
-+ QMakeVar add DEFINES QT_NO_DYNAMIC_LIBRARY
-+ QMAKE_CONFIG="$QMAKE_CONFIG no-libdl"
-+fi
-+
- # detect accessibility
- if [ "$CFG_ACCESSIBILITY" = "auto" ]; then
- if [ "$XPLATFORM_SYMBIAN" = "yes" ]; then
-diff --git a/src/corelib/plugin/plugin.pri b/src/corelib/plugin/plugin.pri
-index eb7a7f7..c342f2e 100644
---- a/src/corelib/plugin/plugin.pri
-+++ b/src/corelib/plugin/plugin.pri
-@@ -32,4 +32,4 @@ integrity {
- SOURCES += plugin/qlibrary_unix.cpp
- }
-
--LIBS_PRIVATE += $$QMAKE_LIBS_DYNLOAD
-+!no-libdl: LIBS_PRIVATE += $$QMAKE_LIBS_DYNLOAD
---
-2.8.0
-
--- /dev/null
+From 87c9c18fad02744238336a6cf1ce70d3ec2c89c2 Mon Sep 17 00:00:00 2001
+From: Bernd Kuhls <bernd.kuhls@t-online.de>
+Date: Sat, 11 Jun 2016 17:03:07 +0200
+Subject: [PATCH 1/1] OpenGL/EGL: Avoid X11 header collision
+
+Including X11 headers via EGL/egl.h leads to a collision of defines
+between Qt and X11. To fix this qt5 added
+ DEFINES += MESA_EGL_NO_X11_HEADERS
+in various files:
+
+https://github.com/qtproject/qtbase/blob/dev/src/platformsupport/eglconvenience/eglconvenience.pri#L19
+https://github.com/qtproject/qtbase/blob/dev/src/plugins/platforms/minimalegl/minimalegl.pro#L10
+https://github.com/qtproject/qtbase/blob/dev/src/plugins/platforms/eglfs/deviceintegration/eglfs_x11/eglfs_x11.pro#L6
+[...]
+
+This patch fixes a similar compile error in qt4:
+http://autobuild.buildroot.net/results/9b0/9b0ed92984eead89d148eaa71aff6e2f1e117837/
+http://autobuild.buildroot.org/results/4fd/4fd57553336d36439fab32a7221fc8639758e887/
+http://autobuild.buildroot.org/results/5cb/5cb8072f8220f7203fa79936eedcc43eab53ec66/
+
+Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
+(patch not sent upstream because qt4 branch is closed:
+ http://blog.qt.io/blog/2015/05/26/qt-4-8-7-released/)
+---
+
+ src/gui/egl/egl.pri | 3 +++
+ src/opengl/opengl.pro | 3 +++
+ 2 files changed, 6 insertions(+)
+
+diff --git a/src/gui/egl/egl.pri b/src/gui/egl/egl.pri
+index 8e8664c..715ffd7 100644
+--- a/src/gui/egl/egl.pri
++++ b/src/gui/egl/egl.pri
+@@ -22,6 +22,9 @@ contains(QT_CONFIG, egl): {
+ !isEmpty(QMAKE_LIBS_EGL): LIBS += $$QMAKE_LIBS_EGL
+ }
+
++ # Avoid X11 header collision
++ DEFINES += MESA_EGL_NO_X11_HEADERS
++
+ wince*: SOURCES += egl/qegl_wince.cpp
+
+ unix {
+diff --git a/src/opengl/opengl.pro b/src/opengl/opengl.pro
+index ce1a5d2..65b1031 100644
+--- a/src/opengl/opengl.pro
++++ b/src/opengl/opengl.pro
+@@ -149,6 +149,9 @@ embedded {
+ qglwindowsurface_qws_p.h \
+ qgl_egl_p.h
+
++ # Avoid X11 header collision
++ DEFINES += MESA_EGL_NO_X11_HEADERS
++
+ contains(QT_CONFIG, fontconfig) {
+ include($$QT_SOURCE_TREE/config.tests/unix/freetype/freetype.pri)
+ } else {
+--
+2.8.1
+
+++ /dev/null
-From 87c9c18fad02744238336a6cf1ce70d3ec2c89c2 Mon Sep 17 00:00:00 2001
-From: Bernd Kuhls <bernd.kuhls@t-online.de>
-Date: Sat, 11 Jun 2016 17:03:07 +0200
-Subject: [PATCH 1/1] OpenGL/EGL: Avoid X11 header collision
-
-Including X11 headers via EGL/egl.h leads to a collision of defines
-between Qt and X11. To fix this qt5 added
- DEFINES += MESA_EGL_NO_X11_HEADERS
-in various files:
-
-https://github.com/qtproject/qtbase/blob/dev/src/platformsupport/eglconvenience/eglconvenience.pri#L19
-https://github.com/qtproject/qtbase/blob/dev/src/plugins/platforms/minimalegl/minimalegl.pro#L10
-https://github.com/qtproject/qtbase/blob/dev/src/plugins/platforms/eglfs/deviceintegration/eglfs_x11/eglfs_x11.pro#L6
-[...]
-
-This patch fixes a similar compile error in qt4:
-http://autobuild.buildroot.net/results/9b0/9b0ed92984eead89d148eaa71aff6e2f1e117837/
-http://autobuild.buildroot.org/results/4fd/4fd57553336d36439fab32a7221fc8639758e887/
-http://autobuild.buildroot.org/results/5cb/5cb8072f8220f7203fa79936eedcc43eab53ec66/
-
-Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
-(patch not sent upstream because qt4 branch is closed:
- http://blog.qt.io/blog/2015/05/26/qt-4-8-7-released/)
----
-
- src/gui/egl/egl.pri | 3 +++
- src/opengl/opengl.pro | 3 +++
- 2 files changed, 6 insertions(+)
-
-diff --git a/src/gui/egl/egl.pri b/src/gui/egl/egl.pri
-index 8e8664c..715ffd7 100644
---- a/src/gui/egl/egl.pri
-+++ b/src/gui/egl/egl.pri
-@@ -22,6 +22,9 @@ contains(QT_CONFIG, egl): {
- !isEmpty(QMAKE_LIBS_EGL): LIBS += $$QMAKE_LIBS_EGL
- }
-
-+ # Avoid X11 header collision
-+ DEFINES += MESA_EGL_NO_X11_HEADERS
-+
- wince*: SOURCES += egl/qegl_wince.cpp
-
- unix {
-diff --git a/src/opengl/opengl.pro b/src/opengl/opengl.pro
-index ce1a5d2..65b1031 100644
---- a/src/opengl/opengl.pro
-+++ b/src/opengl/opengl.pro
-@@ -149,6 +149,9 @@ embedded {
- qglwindowsurface_qws_p.h \
- qgl_egl_p.h
-
-+ # Avoid X11 header collision
-+ DEFINES += MESA_EGL_NO_X11_HEADERS
-+
- contains(QT_CONFIG, fontconfig) {
- include($$QT_SOURCE_TREE/config.tests/unix/freetype/freetype.pri)
- } else {
---
-2.8.1
-