From b4e270f9e2e5c632f0958af1a5131efb45bcd799 Mon Sep 17 00:00:00 2001 From: Martin Jansa Date: Wed, 4 Jun 2014 17:12:58 +0200 Subject: qtbase: Refresh patches to match with stable* branches on github.com/meta-qt5 Signed-off-by: Martin Jansa --- recipes-qt/qt5/nativesdk-qtbase_git.bb | 23 +- .../qtbase-git/0001-Add-linux-oe-g-platform.patch | 4 +- ...01-Revert-Use-the-gcc-feature-in-simd.prf.patch | 29 -- .../0002-Add-external-hostbindir-option.patch | 296 --------------------- ...o-allow-to-set-qt.conf-from-the-outside-u.patch | 39 +++ .../0003-Add-external-hostbindir-option.patch | 296 +++++++++++++++++++++ ...o-allow-to-set-qt.conf-from-the-outside-u.patch | 39 --- ...p-Prefix-default-LIBDIRS-and-INCDIRS-with.patch | 4 +- ...lfs-Print-the-chosen-config-in-debug-mode.patch | 56 ---- ...le-Fix-pkgconfig-and-libtool-replacements.patch | 81 ++++++ .../qt5/qtbase-git/0006-Always-build-uic.patch | 31 --- ...lfs-Print-the-chosen-config-in-debug-mode.patch | 56 ++++ ...-build-it-in-configure-but-allow-to-build.patch | 50 ---- ...reserve-built-qmake-and-swap-with-native-.patch | 29 -- ...gl-error-for-platforms-only-supporting-on.patch | 72 ----- ...mintegration-Undefine-CursorShape-from-X..patch | 30 +++ ...ump-path-length-from-256-to-512-character.patch | 6 +- ...mintegration-Undefine-CursorShape-from-X..patch | 30 --- ...gl-error-for-platforms-only-supporting-on.patch | 72 +++++ ...10-Revert-Use-the-gcc-feature-in-simd.prf.patch | 26 ++ .../qt5/qtbase-git/0011-Always-build-uic.patch | 31 +++ ...-build-it-in-configure-but-allow-to-build.patch | 50 ++++ ...reserve-built-qmake-and-swap-with-native-.patch | 30 +++ recipes-qt/qt5/qtbase-native_git.bb | 20 +- recipes-qt/qt5/qtbase_git.bb | 24 +- 25 files changed, 756 insertions(+), 668 deletions(-) delete mode 100644 recipes-qt/qt5/qtbase-git/0001-Revert-Use-the-gcc-feature-in-simd.prf.patch delete mode 100644 recipes-qt/qt5/qtbase-git/0002-Add-external-hostbindir-option.patch create mode 100644 recipes-qt/qt5/qtbase-git/0002-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch create mode 100644 recipes-qt/qt5/qtbase-git/0003-Add-external-hostbindir-option.patch delete mode 100644 recipes-qt/qt5/qtbase-git/0003-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch delete mode 100644 recipes-qt/qt5/qtbase-git/0005-Revert-eglfs-Print-the-chosen-config-in-debug-mode.patch create mode 100644 recipes-qt/qt5/qtbase-git/0005-qt_module-Fix-pkgconfig-and-libtool-replacements.patch delete mode 100644 recipes-qt/qt5/qtbase-git/0006-Always-build-uic.patch create mode 100644 recipes-qt/qt5/qtbase-git/0006-Revert-eglfs-Print-the-chosen-config-in-debug-mode.patch delete mode 100644 recipes-qt/qt5/qtbase-git/0006-qmake-don-t-build-it-in-configure-but-allow-to-build.patch delete mode 100644 recipes-qt/qt5/qtbase-git/0007-configure-preserve-built-qmake-and-swap-with-native-.patch delete mode 100644 recipes-qt/qt5/qtbase-git/0007-eglfs-fix-egl-error-for-platforms-only-supporting-on.patch create mode 100644 recipes-qt/qt5/qtbase-git/0007-qeglplatformintegration-Undefine-CursorShape-from-X..patch delete mode 100644 recipes-qt/qt5/qtbase-git/0008-qeglplatformintegration-Undefine-CursorShape-from-X..patch create mode 100644 recipes-qt/qt5/qtbase-git/0009-eglfs-fix-egl-error-for-platforms-only-supporting-on.patch create mode 100644 recipes-qt/qt5/qtbase-git/0010-Revert-Use-the-gcc-feature-in-simd.prf.patch create mode 100644 recipes-qt/qt5/qtbase-git/0011-Always-build-uic.patch create mode 100644 recipes-qt/qt5/qtbase-git/0011-qmake-don-t-build-it-in-configure-but-allow-to-build.patch create mode 100644 recipes-qt/qt5/qtbase-git/0012-configure-preserve-built-qmake-and-swap-with-native-.patch diff --git a/recipes-qt/qt5/nativesdk-qtbase_git.bb b/recipes-qt/qt5/nativesdk-qtbase_git.bb index 7c456931..252cadaf 100644 --- a/recipes-qt/qt5/nativesdk-qtbase_git.bb +++ b/recipes-qt/qt5/nativesdk-qtbase_git.bb @@ -8,25 +8,28 @@ SRC_URI = "\ git://qt.gitorious.org/qt/${QT_MODULE}.git;branch=${QT_MODULE_BRANCH} \ " -# common with -native +# common with -native and -nativesdk SRC_URI += "\ file://0001-Add-linux-oe-g-platform.patch \ - file://0002-Add-external-hostbindir-option.patch \ - file://0003-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch \ + file://0002-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch \ + file://0003-Add-external-hostbindir-option.patch \ file://0004-configureapp-Prefix-default-LIBDIRS-and-INCDIRS-with.patch \ - file://0005-Revert-eglfs-Print-the-chosen-config-in-debug-mode.patch \ - file://0001-Revert-Use-the-gcc-feature-in-simd.prf.patch \ + file://0005-qt_module-Fix-pkgconfig-and-libtool-replacements.patch \ + file://0006-Revert-eglfs-Print-the-chosen-config-in-debug-mode.patch \ + file://0007-qeglplatformintegration-Undefine-CursorShape-from-X..patch \ + file://0008-configure-bump-path-length-from-256-to-512-character.patch \ + file://0009-eglfs-fix-egl-error-for-platforms-only-supporting-on.patch \ + file://0010-Revert-Use-the-gcc-feature-in-simd.prf.patch \ " -# common with native version +# common with -native version SRC_URI += " \ - file://0006-Always-build-uic.patch \ + file://0011-Always-build-uic.patch \ " # specific for nativesdk version SRC_URI += " \ - file://0007-configure-preserve-built-qmake-and-swap-with-native-.patch \ - file://0008-configure-bump-path-length-from-256-to-512-character.patch \ + file://0012-configure-preserve-built-qmake-and-swap-with-native-.patch \ " -SRCREV = "267ba8b63e0fbf02cde4d2709397ed0e12f34ee2" +SRCREV = "80b6fbc2d9dfc753d6570e971aa4cf4f3420585c" diff --git a/recipes-qt/qt5/qtbase-git/0001-Add-linux-oe-g-platform.patch b/recipes-qt/qt5/qtbase-git/0001-Add-linux-oe-g-platform.patch index 95841ce3..eca6b36d 100644 --- a/recipes-qt/qt5/qtbase-git/0001-Add-linux-oe-g-platform.patch +++ b/recipes-qt/qt5/qtbase-git/0001-Add-linux-oe-g-platform.patch @@ -1,7 +1,7 @@ -From e70bd40730582e5e5531fca51a1574cb306c40d3 Mon Sep 17 00:00:00 2001 +From 9c7d71880c6ec5b07e3030b7c7a23e004d5c60a2 Mon Sep 17 00:00:00 2001 From: Martin Jansa Date: Mon, 15 Apr 2013 04:29:32 +0200 -Subject: [PATCH 1/8] Add linux-oe-g++ platform +Subject: [PATCH 01/12] Add linux-oe-g++ platform * This qmake.conf unlike other platforms reads most variables from shell environment, because it's easier for qt recipes to export diff --git a/recipes-qt/qt5/qtbase-git/0001-Revert-Use-the-gcc-feature-in-simd.prf.patch b/recipes-qt/qt5/qtbase-git/0001-Revert-Use-the-gcc-feature-in-simd.prf.patch deleted file mode 100644 index 88f5c122..00000000 --- a/recipes-qt/qt5/qtbase-git/0001-Revert-Use-the-gcc-feature-in-simd.prf.patch +++ /dev/null @@ -1,29 +0,0 @@ -From 9d33599f12787f85a19e8147604f919ac40c02c1 Mon Sep 17 00:00:00 2001 -From: Martin Jansa -Date: Wed, 4 Jun 2014 15:26:11 +0200 -Subject: [PATCH] Revert "Use the "gcc" feature in simd.prf" - -It's causing linker issues, see my comment in: -https://bugreports.qt-project.org/browse/QTBUG-38544 - -This reverts commit 3b00cc480400d47c59c29d3507c7fcdc9be2a489. ---- - mkspecs/features/simd.prf | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/mkspecs/features/simd.prf b/mkspecs/features/simd.prf -index 62a63f9..4f86f60 100644 ---- a/mkspecs/features/simd.prf -+++ b/mkspecs/features/simd.prf -@@ -18,7 +18,7 @@ QT_CPU_FEATURES = $$eval(QT_CPU_FEATURES.$$QT_ARCH) - # - # Set up compilers for SIMD (SSE/AVX, NEON etc) - # --gcc { # includes intel_icc and clang variants -+*-g++*|intel_icc|*-clang*|*-qcc* { - sse2 { - HEADERS += $$SSE2_HEADERS - --- -2.0.0 - diff --git a/recipes-qt/qt5/qtbase-git/0002-Add-external-hostbindir-option.patch b/recipes-qt/qt5/qtbase-git/0002-Add-external-hostbindir-option.patch deleted file mode 100644 index 81f18674..00000000 --- a/recipes-qt/qt5/qtbase-git/0002-Add-external-hostbindir-option.patch +++ /dev/null @@ -1,296 +0,0 @@ -From eaa4a4c13e65e29e2214a01b69b77b9c6f2ada05 Mon Sep 17 00:00:00 2001 -From: Martin Jansa -Date: Sat, 6 Apr 2013 13:15:07 +0200 -Subject: [PATCH 2/8] Add -external-hostbindir option - -* when cross-compiling it's sometimes useful to use existing tools from machine - (or in OpenEmbedded built with separate native recipe) when building for target - -* this way we can skip bootstraping tools we already have - -* qt_functions: temporary remove isEmpty check -* now we assume that every build will provide QT_EXTERNAL_HOST_BINS value -* isEmpty works correctly only with qmake variables (e.g. $$FOO - - isEmpty(FOO)), but doesn't work with system properties like $$[FOO]. - -* cmake: Use OE_QMAKE_PATH_EXTERNAL_HOST_BINS to determine path to host binaries - -Upstream-Status: Pending - is a lot better for upstreaming (and it was already sort of approved by - Oswald) but in 5.2.0 I've noticed that he added something similar for - android builds - -Signed-off-by: Martin Jansa -Signed-off-by: Simon Busch ---- - configure | 15 +++++++++++++++ - mkspecs/features/qt_functions.prf | 2 +- - mkspecs/features/qt_tool.prf | 3 +-- - qmake/property.cpp | 1 + - qtbase.pro | 12 +++++++++--- - src/corelib/Qt5CoreConfigExtras.cmake.in | 6 +++--- - src/corelib/global/qlibraryinfo.cpp | 3 ++- - src/corelib/global/qlibraryinfo.h | 1 + - src/dbus/Qt5DBusConfigExtras.cmake.in | 4 ++-- - src/widgets/Qt5WidgetsConfigExtras.cmake.in | 2 +- - tools/configure/configureapp.cpp | 8 ++++++++ - 11 files changed, 44 insertions(+), 13 deletions(-) - -diff --git a/configure b/configure -index 4eae0d3..48d5119 100755 ---- a/configure -+++ b/configure -@@ -777,6 +777,7 @@ QT_HOST_BINS= - QT_HOST_LIBS= - QT_HOST_DATA= - QT_EXT_PREFIX= -+QT_EXTERNAL_HOST_BINS= - - #flags for SQL drivers - QT_CFLAGS_PSQL= -@@ -896,6 +897,7 @@ while [ "$#" -gt 0 ]; do - -testsdir| \ - -hostdatadir| \ - -hostbindir| \ -+ -external-hostbindir| \ - -hostlibdir| \ - -extprefix| \ - -sysroot| \ -@@ -1110,6 +1112,9 @@ while [ "$#" -gt 0 ]; do - extprefix) - QT_EXT_PREFIX="$VAL" - ;; -+ external-hostbindir) -+ QT_EXTERNAL_HOST_BINS="$VAL" -+ ;; - pkg-config) - if [ "$VAL" = "yes" ] || [ "$VAL" = "no" ]; then - CFG_PKGCONFIG="$VAL" -@@ -2248,6 +2253,10 @@ Installation options: - -hostdatadir . Data used by qmake will be installed to - (default HOSTPREFIX) - -+ -external-hostbindir Use external host executables instead of building them -+ (not used by defaut) -+ -+ - Configure options: - - The defaults (*) are usually acceptable. A plus (+) denotes a default value -@@ -2915,6 +2924,11 @@ fi - # command line and environment validation - #------------------------------------------------------------------------------- - -+# default is empty, don't call makeabs if it is empty -+if [ ! -z "$QT_EXTERNAL_HOST_BINS" ]; then -+ QT_EXTERNAL_HOST_BINS=`"$relpath/config.tests/unix/makeabs" "$QT_EXTERNAL_HOST_BINS"` -+fi -+ - # update QT_CONFIG to show our current predefined configuration - CFG_QCONFIG_PATH=$relpath/src/corelib/global/qconfig-${CFG_QCONFIG}.h - case "$CFG_QCONFIG" in -@@ -3595,6 +3609,7 @@ static const char qt_configure_prefix_path_strs[][256 + 12] = { - "qt_hbinpath=$QT_HOST_BINS", - "qt_hlibpath=$QT_HOST_LIBS", - "qt_hdatpath=$QT_HOST_DATA", -+ "qt_ebinpath=$QT_EXTERNAL_HOST_BINS", - "qt_targspec=$shortxspec", - "qt_hostspec=$shortspec", - #endif -diff --git a/mkspecs/features/qt_functions.prf b/mkspecs/features/qt_functions.prf -index d41fe3b..050a4a7 100644 ---- a/mkspecs/features/qt_functions.prf -+++ b/mkspecs/features/qt_functions.prf -@@ -193,7 +193,7 @@ defineTest(qtAddRpathLink) { - defineTest(qtPrepareTool) { - cmd = $$eval(QT_TOOL.$${2}.binary) - isEmpty(cmd) { -- cmd = $$[QT_HOST_BINS]/$$2 -+ cmd = $$[QT_EXTERNAL_HOST_BINS]/$$2 - exists($${cmd}.pl) { - cmd = perl -w $$system_path($${cmd}.pl) - } else: contains(QMAKE_HOST.os, Windows) { -diff --git a/mkspecs/features/qt_tool.prf b/mkspecs/features/qt_tool.prf -index 1d3e88c..bd44754 100644 ---- a/mkspecs/features/qt_tool.prf -+++ b/mkspecs/features/qt_tool.prf -@@ -15,8 +15,7 @@ CONFIG += console - - # If we are doing a prefix build, create a "module" pri which enables - # qtPrepareTool() to work with the non-installed build. --# Non-bootstrapped tools always need this because of the environment setup. --!build_pass:if(!host_build|!force_bootstrap|force_independent) { -+!build_pass:if(!host_build|!force_bootstrap|force_independent):!exists($$[QT_EXTERNAL_HOST_BINS]) { - isEmpty(MODULE):MODULE = $$TARGET - - !host_build|!force_bootstrap: MODULE_DEPENDS = $$replace(QT, -private$, _private) -diff --git a/qmake/property.cpp b/qmake/property.cpp -index e50485c..71291ad 100644 ---- a/qmake/property.cpp -+++ b/qmake/property.cpp -@@ -75,6 +75,7 @@ static const struct { - { "QT_HOST_DATA", QLibraryInfo::HostDataPath, true }, - { "QT_HOST_BINS", QLibraryInfo::HostBinariesPath, true }, - { "QT_HOST_LIBS", QLibraryInfo::HostLibrariesPath, true }, -+ { "QT_EXTERNAL_HOST_BINS", QLibraryInfo::ExternalHostBinariesPath, true }, - { "QMAKE_SPEC", QLibraryInfo::HostSpecPath, true }, - { "QMAKE_XSPEC", QLibraryInfo::TargetSpecPath, true }, - }; -diff --git a/qtbase.pro b/qtbase.pro -index d6861cf..92e6a83 100644 ---- a/qtbase.pro -+++ b/qtbase.pro -@@ -71,16 +71,22 @@ CONFIG -= qt - - #qmake - qmake.path = $$[QT_HOST_BINS] -+qmake.files = $$OUT_PWD/bin/qmake -+!isEmpty($$[QT_EXTERNAL_HOST_BINS]) { -+ qmake.files = $$[QT_EXTERNAL_HOST_BINS]/bin/qmake -+} - equals(QMAKE_HOST.os, Windows) { -- qmake.files = $$OUT_PWD/bin/qmake.exe --} else { -- qmake.files = $$OUT_PWD/bin/qmake -+ qmake.files = $${qmake.files}.exe - } - INSTALLS += qmake - - #syncqt - syncqt.path = $$[QT_HOST_BINS] - syncqt.files = $$PWD/bin/syncqt.pl -+syncqt.files = $$PWD/bin/syncqt.pl -+!isEmpty($$[QT_EXTERNAL_HOST_BINS]) { -+ syncqt.files = $$[QT_EXTERNAL_HOST_BINS]/bin/syncqt.pl -+} - INSTALLS += syncqt - - # If we are doing a prefix build, create a "module" pri which enables -diff --git a/src/corelib/Qt5CoreConfigExtras.cmake.in b/src/corelib/Qt5CoreConfigExtras.cmake.in -index 9bda70e..6e3605a 100644 ---- a/src/corelib/Qt5CoreConfigExtras.cmake.in -+++ b/src/corelib/Qt5CoreConfigExtras.cmake.in -@@ -5,7 +5,7 @@ if (NOT TARGET Qt5::qmake) - !!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE) - set(imported_location \"${_qt5Core_install_prefix}/$${CMAKE_BIN_DIR}qmake$$CMAKE_BIN_SUFFIX\") - !!ELSE -- set(imported_location \"$${CMAKE_BIN_DIR}qmake$$CMAKE_BIN_SUFFIX\") -+ set(imported_location \"${OE_QMAKE_PATH_EXTERNAL_HOST_BINS}/qmake$$CMAKE_BIN_SUFFIX\") - !!ENDIF - _qt5_Core_check_file_exists(${imported_location}) - -@@ -20,7 +20,7 @@ if (NOT TARGET Qt5::moc) - !!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE) - set(imported_location \"${_qt5Core_install_prefix}/$${CMAKE_BIN_DIR}moc$$CMAKE_BIN_SUFFIX\") - !!ELSE -- set(imported_location \"$${CMAKE_BIN_DIR}moc$$CMAKE_BIN_SUFFIX\") -+ set(imported_location \"${OE_QMAKE_PATH_EXTERNAL_HOST_BINS}/moc$$CMAKE_BIN_SUFFIX\") - !!ENDIF - _qt5_Core_check_file_exists(${imported_location}) - -@@ -37,7 +37,7 @@ if (NOT TARGET Qt5::rcc) - !!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE) - set(imported_location \"${_qt5Core_install_prefix}/$${CMAKE_BIN_DIR}rcc$$CMAKE_BIN_SUFFIX\") - !!ELSE -- set(imported_location \"$${CMAKE_BIN_DIR}rcc$$CMAKE_BIN_SUFFIX\") -+ set(imported_location \"${OE_QMAKE_PATH_EXTERNAL_HOST_BINS}/rcc$$CMAKE_BIN_SUFFIX\") - !!ENDIF - _qt5_Core_check_file_exists(${imported_location}) - -diff --git a/src/corelib/global/qlibraryinfo.cpp b/src/corelib/global/qlibraryinfo.cpp -index 6d25325..3686b17 100644 ---- a/src/corelib/global/qlibraryinfo.cpp -+++ b/src/corelib/global/qlibraryinfo.cpp -@@ -333,7 +333,7 @@ QLibraryInfo::isDebugBuild() - */ - - static const struct { -- char key[19], value[13]; -+ char key[21], value[13]; - } qtConfEntries[] = { - { "Prefix", "." }, - { "Documentation", "doc" }, // should be ${Data}/doc -@@ -359,6 +359,7 @@ static const struct { - { "HostBinaries", "bin" }, - { "HostLibraries", "lib" }, - { "HostData", "." }, -+ { "ExternalHostBinaries", "" }, - { "TargetSpec", "" }, - { "HostSpec", "" }, - #endif -diff --git a/src/corelib/global/qlibraryinfo.h b/src/corelib/global/qlibraryinfo.h -index 0b573c2..b5535ee 100644 ---- a/src/corelib/global/qlibraryinfo.h -+++ b/src/corelib/global/qlibraryinfo.h -@@ -88,6 +88,7 @@ public: - HostBinariesPath, - HostLibrariesPath, - HostDataPath, -+ ExternalHostBinariesPath, - TargetSpecPath, - HostSpecPath, - LastHostPath = HostSpecPath, -diff --git a/src/dbus/Qt5DBusConfigExtras.cmake.in b/src/dbus/Qt5DBusConfigExtras.cmake.in -index 1d94715..301af8f 100644 ---- a/src/dbus/Qt5DBusConfigExtras.cmake.in -+++ b/src/dbus/Qt5DBusConfigExtras.cmake.in -@@ -5,7 +5,7 @@ if (NOT TARGET Qt5::qdbuscpp2xml) - !!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE) - set(imported_location \"${_qt5DBus_install_prefix}/$${CMAKE_BIN_DIR}qdbuscpp2xml$$CMAKE_BIN_SUFFIX\") - !!ELSE -- set(imported_location \"$${CMAKE_BIN_DIR}qdbuscpp2xml$$CMAKE_BIN_SUFFIX\") -+ set(imported_location \"${OE_QMAKE_PATH_EXTERNAL_HOST_BINS}/qdbuscpp2xml$$CMAKE_BIN_SUFFIX\") - !!ENDIF - _qt5_DBus_check_file_exists(${imported_location}) - -@@ -20,7 +20,7 @@ if (NOT TARGET Qt5::qdbusxml2cpp) - !!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE) - set(imported_location \"${_qt5DBus_install_prefix}/$${CMAKE_BIN_DIR}qdbusxml2cpp$$CMAKE_BIN_SUFFIX\") - !!ELSE -- set(imported_location \"$${CMAKE_BIN_DIR}qdbusxml2cpp$$CMAKE_BIN_SUFFIX\") -+ set(imported_location \"${OE_QMAKE_PATH_EXTERNAL_HOST_BINS}/qdbusxml2cpp$$CMAKE_BIN_SUFFIX\") - !!ENDIF - _qt5_DBus_check_file_exists(${imported_location}) - -diff --git a/src/widgets/Qt5WidgetsConfigExtras.cmake.in b/src/widgets/Qt5WidgetsConfigExtras.cmake.in -index 99d87e2..5621dc0 100644 ---- a/src/widgets/Qt5WidgetsConfigExtras.cmake.in -+++ b/src/widgets/Qt5WidgetsConfigExtras.cmake.in -@@ -5,7 +5,7 @@ if (NOT TARGET Qt5::uic) - !!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE) - set(imported_location \"${_qt5Widgets_install_prefix}/$${CMAKE_BIN_DIR}uic$$CMAKE_BIN_SUFFIX\") - !!ELSE -- set(imported_location \"$${CMAKE_BIN_DIR}uic$$CMAKE_BIN_SUFFIX\") -+ set(imported_location \"${OE_QMAKE_PATH_EXTERNAL_HOST_BINS}/uic$$CMAKE_BIN_SUFFIX\") - !!ENDIF - _qt5_Widgets_check_file_exists(${imported_location}) - -diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp -index b756509..7e61845 100644 ---- a/tools/configure/configureapp.cpp -+++ b/tools/configure/configureapp.cpp -@@ -1213,6 +1213,13 @@ void Configure::parseCmdLine() - dictionary[ "QT_EXT_PREFIX" ] = configCmdLine.at(i); - } - -+ else if (configCmdLine.at(i) == "-external-hostbindir") { -+ ++i; -+ if (i == argCount) -+ break; -+ dictionary[ "QT_EXTERNAL_HOST_BINS" ] = configCmdLine.at(i); -+ } -+ - else if (configCmdLine.at(i) == "-make-tool") { - ++i; - if (i == argCount) -@@ -3983,6 +3990,7 @@ void Configure::generateQConfigCpp() - << " \"qt_hbinpath=" << formatPath(dictionary["QT_HOST_BINS"]) << "\"," << endl - << " \"qt_hlibpath=" << formatPath(dictionary["QT_HOST_LIBS"]) << "\"," << endl - << " \"qt_hdatpath=" << formatPath(dictionary["QT_HOST_DATA"]) << "\"," << endl -+ << " \"qt_ebinpath=" << formatPath(dictionary["QT_EXTERNAL_HOST_BINS"]) << "\"," << endl - << " \"qt_targspec=" << targSpec << "\"," << endl - << " \"qt_hostspec=" << hostSpec << "\"," << endl - << "#endif" << endl --- -2.0.0 - diff --git a/recipes-qt/qt5/qtbase-git/0002-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch b/recipes-qt/qt5/qtbase-git/0002-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch new file mode 100644 index 00000000..29f788e7 --- /dev/null +++ b/recipes-qt/qt5/qtbase-git/0002-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch @@ -0,0 +1,39 @@ +From ad884ab378939e685a3b00af03bb6875d9bdc1d5 Mon Sep 17 00:00:00 2001 +From: Holger Freyther +Date: Wed, 26 Sep 2012 17:22:30 +0200 +Subject: [PATCH 02/12] qlibraryinfo: allow to set qt.conf from the outside + using the environment + +Allow to set a qt.conf from the outside using the environment. This allows +to inject new prefixes and other paths into qmake. This is needed when using +the same qmake binary to build qt/x11 and qt/embedded + +Upstream-Status: Inappropriate [embedded specific] + again very OE specific to read everything from environment (reusing the same + qmake from sstate and replacing all configured paths in it with qt.conf from + environment). + +Signed-off-by: Martin Jansa +--- + src/corelib/global/qlibraryinfo.cpp | 5 ++++- + 1 file changed, 4 insertions(+), 1 deletion(-) + +diff --git a/src/corelib/global/qlibraryinfo.cpp b/src/corelib/global/qlibraryinfo.cpp +index 6d25325..80e0f30 100644 +--- a/src/corelib/global/qlibraryinfo.cpp ++++ b/src/corelib/global/qlibraryinfo.cpp +@@ -153,7 +153,10 @@ QLibrarySettings::QLibrarySettings() + + QSettings *QLibraryInfoPrivate::findConfiguration() + { +- QString qtconfig = QStringLiteral(":/qt/etc/qt.conf"); ++ QByteArray config = getenv("QT_CONF_PATH"); ++ QString qtconfig = QFile::decodeName(config); ++ if(!QFile::exists(qtconfig)) ++ qtconfig = QStringLiteral(":/qt/etc/qt.conf"); + #ifdef QT_BOOTSTRAPPED + if(!QFile::exists(qtconfig)) + qtconfig = qt_libraryInfoFile(); +-- +2.0.0 + diff --git a/recipes-qt/qt5/qtbase-git/0003-Add-external-hostbindir-option.patch b/recipes-qt/qt5/qtbase-git/0003-Add-external-hostbindir-option.patch new file mode 100644 index 00000000..44d17ca6 --- /dev/null +++ b/recipes-qt/qt5/qtbase-git/0003-Add-external-hostbindir-option.patch @@ -0,0 +1,296 @@ +From b45d963702c139ea4f5b5ce572d046511a878d81 Mon Sep 17 00:00:00 2001 +From: Martin Jansa +Date: Sat, 6 Apr 2013 13:15:07 +0200 +Subject: [PATCH 03/12] Add -external-hostbindir option + +* when cross-compiling it's sometimes useful to use existing tools from machine + (or in OpenEmbedded built with separate native recipe) when building for target + +* this way we can skip bootstraping tools we already have + +* qt_functions: temporary remove isEmpty check +* now we assume that every build will provide QT_EXTERNAL_HOST_BINS value +* isEmpty works correctly only with qmake variables (e.g. $$FOO - + isEmpty(FOO)), but doesn't work with system properties like $$[FOO]. + +* cmake: Use OE_QMAKE_PATH_EXTERNAL_HOST_BINS to determine path to host binaries + +Upstream-Status: Pending + is a lot better for upstreaming (and it was already sort of approved by + Oswald) but in 5.2.0 I've noticed that he added something similar for + android builds + +Signed-off-by: Martin Jansa +Signed-off-by: Simon Busch +--- + configure | 15 +++++++++++++++ + mkspecs/features/qt_functions.prf | 2 +- + mkspecs/features/qt_tool.prf | 3 +-- + qmake/property.cpp | 1 + + qtbase.pro | 12 +++++++++--- + src/corelib/Qt5CoreConfigExtras.cmake.in | 6 +++--- + src/corelib/global/qlibraryinfo.cpp | 3 ++- + src/corelib/global/qlibraryinfo.h | 1 + + src/dbus/Qt5DBusConfigExtras.cmake.in | 4 ++-- + src/widgets/Qt5WidgetsConfigExtras.cmake.in | 2 +- + tools/configure/configureapp.cpp | 8 ++++++++ + 11 files changed, 44 insertions(+), 13 deletions(-) + +diff --git a/configure b/configure +index 4eae0d3..48d5119 100755 +--- a/configure ++++ b/configure +@@ -777,6 +777,7 @@ QT_HOST_BINS= + QT_HOST_LIBS= + QT_HOST_DATA= + QT_EXT_PREFIX= ++QT_EXTERNAL_HOST_BINS= + + #flags for SQL drivers + QT_CFLAGS_PSQL= +@@ -896,6 +897,7 @@ while [ "$#" -gt 0 ]; do + -testsdir| \ + -hostdatadir| \ + -hostbindir| \ ++ -external-hostbindir| \ + -hostlibdir| \ + -extprefix| \ + -sysroot| \ +@@ -1110,6 +1112,9 @@ while [ "$#" -gt 0 ]; do + extprefix) + QT_EXT_PREFIX="$VAL" + ;; ++ external-hostbindir) ++ QT_EXTERNAL_HOST_BINS="$VAL" ++ ;; + pkg-config) + if [ "$VAL" = "yes" ] || [ "$VAL" = "no" ]; then + CFG_PKGCONFIG="$VAL" +@@ -2248,6 +2253,10 @@ Installation options: + -hostdatadir . Data used by qmake will be installed to + (default HOSTPREFIX) + ++ -external-hostbindir Use external host executables instead of building them ++ (not used by defaut) ++ ++ + Configure options: + + The defaults (*) are usually acceptable. A plus (+) denotes a default value +@@ -2915,6 +2924,11 @@ fi + # command line and environment validation + #------------------------------------------------------------------------------- + ++# default is empty, don't call makeabs if it is empty ++if [ ! -z "$QT_EXTERNAL_HOST_BINS" ]; then ++ QT_EXTERNAL_HOST_BINS=`"$relpath/config.tests/unix/makeabs" "$QT_EXTERNAL_HOST_BINS"` ++fi ++ + # update QT_CONFIG to show our current predefined configuration + CFG_QCONFIG_PATH=$relpath/src/corelib/global/qconfig-${CFG_QCONFIG}.h + case "$CFG_QCONFIG" in +@@ -3595,6 +3609,7 @@ static const char qt_configure_prefix_path_strs[][256 + 12] = { + "qt_hbinpath=$QT_HOST_BINS", + "qt_hlibpath=$QT_HOST_LIBS", + "qt_hdatpath=$QT_HOST_DATA", ++ "qt_ebinpath=$QT_EXTERNAL_HOST_BINS", + "qt_targspec=$shortxspec", + "qt_hostspec=$shortspec", + #endif +diff --git a/mkspecs/features/qt_functions.prf b/mkspecs/features/qt_functions.prf +index d41fe3b..050a4a7 100644 +--- a/mkspecs/features/qt_functions.prf ++++ b/mkspecs/features/qt_functions.prf +@@ -193,7 +193,7 @@ defineTest(qtAddRpathLink) { + defineTest(qtPrepareTool) { + cmd = $$eval(QT_TOOL.$${2}.binary) + isEmpty(cmd) { +- cmd = $$[QT_HOST_BINS]/$$2 ++ cmd = $$[QT_EXTERNAL_HOST_BINS]/$$2 + exists($${cmd}.pl) { + cmd = perl -w $$system_path($${cmd}.pl) + } else: contains(QMAKE_HOST.os, Windows) { +diff --git a/mkspecs/features/qt_tool.prf b/mkspecs/features/qt_tool.prf +index 1d3e88c..bd44754 100644 +--- a/mkspecs/features/qt_tool.prf ++++ b/mkspecs/features/qt_tool.prf +@@ -15,8 +15,7 @@ CONFIG += console + + # If we are doing a prefix build, create a "module" pri which enables + # qtPrepareTool() to work with the non-installed build. +-# Non-bootstrapped tools always need this because of the environment setup. +-!build_pass:if(!host_build|!force_bootstrap|force_independent) { ++!build_pass:if(!host_build|!force_bootstrap|force_independent):!exists($$[QT_EXTERNAL_HOST_BINS]) { + isEmpty(MODULE):MODULE = $$TARGET + + !host_build|!force_bootstrap: MODULE_DEPENDS = $$replace(QT, -private$, _private) +diff --git a/qmake/property.cpp b/qmake/property.cpp +index e50485c..71291ad 100644 +--- a/qmake/property.cpp ++++ b/qmake/property.cpp +@@ -75,6 +75,7 @@ static const struct { + { "QT_HOST_DATA", QLibraryInfo::HostDataPath, true }, + { "QT_HOST_BINS", QLibraryInfo::HostBinariesPath, true }, + { "QT_HOST_LIBS", QLibraryInfo::HostLibrariesPath, true }, ++ { "QT_EXTERNAL_HOST_BINS", QLibraryInfo::ExternalHostBinariesPath, true }, + { "QMAKE_SPEC", QLibraryInfo::HostSpecPath, true }, + { "QMAKE_XSPEC", QLibraryInfo::TargetSpecPath, true }, + }; +diff --git a/qtbase.pro b/qtbase.pro +index d6861cf..92e6a83 100644 +--- a/qtbase.pro ++++ b/qtbase.pro +@@ -71,16 +71,22 @@ CONFIG -= qt + + #qmake + qmake.path = $$[QT_HOST_BINS] ++qmake.files = $$OUT_PWD/bin/qmake ++!isEmpty($$[QT_EXTERNAL_HOST_BINS]) { ++ qmake.files = $$[QT_EXTERNAL_HOST_BINS]/bin/qmake ++} + equals(QMAKE_HOST.os, Windows) { +- qmake.files = $$OUT_PWD/bin/qmake.exe +-} else { +- qmake.files = $$OUT_PWD/bin/qmake ++ qmake.files = $${qmake.files}.exe + } + INSTALLS += qmake + + #syncqt + syncqt.path = $$[QT_HOST_BINS] + syncqt.files = $$PWD/bin/syncqt.pl ++syncqt.files = $$PWD/bin/syncqt.pl ++!isEmpty($$[QT_EXTERNAL_HOST_BINS]) { ++ syncqt.files = $$[QT_EXTERNAL_HOST_BINS]/bin/syncqt.pl ++} + INSTALLS += syncqt + + # If we are doing a prefix build, create a "module" pri which enables +diff --git a/src/corelib/Qt5CoreConfigExtras.cmake.in b/src/corelib/Qt5CoreConfigExtras.cmake.in +index 9bda70e..6e3605a 100644 +--- a/src/corelib/Qt5CoreConfigExtras.cmake.in ++++ b/src/corelib/Qt5CoreConfigExtras.cmake.in +@@ -5,7 +5,7 @@ if (NOT TARGET Qt5::qmake) + !!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE) + set(imported_location \"${_qt5Core_install_prefix}/$${CMAKE_BIN_DIR}qmake$$CMAKE_BIN_SUFFIX\") + !!ELSE +- set(imported_location \"$${CMAKE_BIN_DIR}qmake$$CMAKE_BIN_SUFFIX\") ++ set(imported_location \"${OE_QMAKE_PATH_EXTERNAL_HOST_BINS}/qmake$$CMAKE_BIN_SUFFIX\") + !!ENDIF + _qt5_Core_check_file_exists(${imported_location}) + +@@ -20,7 +20,7 @@ if (NOT TARGET Qt5::moc) + !!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE) + set(imported_location \"${_qt5Core_install_prefix}/$${CMAKE_BIN_DIR}moc$$CMAKE_BIN_SUFFIX\") + !!ELSE +- set(imported_location \"$${CMAKE_BIN_DIR}moc$$CMAKE_BIN_SUFFIX\") ++ set(imported_location \"${OE_QMAKE_PATH_EXTERNAL_HOST_BINS}/moc$$CMAKE_BIN_SUFFIX\") + !!ENDIF + _qt5_Core_check_file_exists(${imported_location}) + +@@ -37,7 +37,7 @@ if (NOT TARGET Qt5::rcc) + !!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE) + set(imported_location \"${_qt5Core_install_prefix}/$${CMAKE_BIN_DIR}rcc$$CMAKE_BIN_SUFFIX\") + !!ELSE +- set(imported_location \"$${CMAKE_BIN_DIR}rcc$$CMAKE_BIN_SUFFIX\") ++ set(imported_location \"${OE_QMAKE_PATH_EXTERNAL_HOST_BINS}/rcc$$CMAKE_BIN_SUFFIX\") + !!ENDIF + _qt5_Core_check_file_exists(${imported_location}) + +diff --git a/src/corelib/global/qlibraryinfo.cpp b/src/corelib/global/qlibraryinfo.cpp +index 80e0f30..89e13cf 100644 +--- a/src/corelib/global/qlibraryinfo.cpp ++++ b/src/corelib/global/qlibraryinfo.cpp +@@ -336,7 +336,7 @@ QLibraryInfo::isDebugBuild() + */ + + static const struct { +- char key[19], value[13]; ++ char key[21], value[13]; + } qtConfEntries[] = { + { "Prefix", "." }, + { "Documentation", "doc" }, // should be ${Data}/doc +@@ -362,6 +362,7 @@ static const struct { + { "HostBinaries", "bin" }, + { "HostLibraries", "lib" }, + { "HostData", "." }, ++ { "ExternalHostBinaries", "" }, + { "TargetSpec", "" }, + { "HostSpec", "" }, + #endif +diff --git a/src/corelib/global/qlibraryinfo.h b/src/corelib/global/qlibraryinfo.h +index 0b573c2..b5535ee 100644 +--- a/src/corelib/global/qlibraryinfo.h ++++ b/src/corelib/global/qlibraryinfo.h +@@ -88,6 +88,7 @@ public: + HostBinariesPath, + HostLibrariesPath, + HostDataPath, ++ ExternalHostBinariesPath, + TargetSpecPath, + HostSpecPath, + LastHostPath = HostSpecPath, +diff --git a/src/dbus/Qt5DBusConfigExtras.cmake.in b/src/dbus/Qt5DBusConfigExtras.cmake.in +index 1d94715..301af8f 100644 +--- a/src/dbus/Qt5DBusConfigExtras.cmake.in ++++ b/src/dbus/Qt5DBusConfigExtras.cmake.in +@@ -5,7 +5,7 @@ if (NOT TARGET Qt5::qdbuscpp2xml) + !!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE) + set(imported_location \"${_qt5DBus_install_prefix}/$${CMAKE_BIN_DIR}qdbuscpp2xml$$CMAKE_BIN_SUFFIX\") + !!ELSE +- set(imported_location \"$${CMAKE_BIN_DIR}qdbuscpp2xml$$CMAKE_BIN_SUFFIX\") ++ set(imported_location \"${OE_QMAKE_PATH_EXTERNAL_HOST_BINS}/qdbuscpp2xml$$CMAKE_BIN_SUFFIX\") + !!ENDIF + _qt5_DBus_check_file_exists(${imported_location}) + +@@ -20,7 +20,7 @@ if (NOT TARGET Qt5::qdbusxml2cpp) + !!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE) + set(imported_location \"${_qt5DBus_install_prefix}/$${CMAKE_BIN_DIR}qdbusxml2cpp$$CMAKE_BIN_SUFFIX\") + !!ELSE +- set(imported_location \"$${CMAKE_BIN_DIR}qdbusxml2cpp$$CMAKE_BIN_SUFFIX\") ++ set(imported_location \"${OE_QMAKE_PATH_EXTERNAL_HOST_BINS}/qdbusxml2cpp$$CMAKE_BIN_SUFFIX\") + !!ENDIF + _qt5_DBus_check_file_exists(${imported_location}) + +diff --git a/src/widgets/Qt5WidgetsConfigExtras.cmake.in b/src/widgets/Qt5WidgetsConfigExtras.cmake.in +index 99d87e2..5621dc0 100644 +--- a/src/widgets/Qt5WidgetsConfigExtras.cmake.in ++++ b/src/widgets/Qt5WidgetsConfigExtras.cmake.in +@@ -5,7 +5,7 @@ if (NOT TARGET Qt5::uic) + !!IF isEmpty(CMAKE_BIN_DIR_IS_ABSOLUTE) + set(imported_location \"${_qt5Widgets_install_prefix}/$${CMAKE_BIN_DIR}uic$$CMAKE_BIN_SUFFIX\") + !!ELSE +- set(imported_location \"$${CMAKE_BIN_DIR}uic$$CMAKE_BIN_SUFFIX\") ++ set(imported_location \"${OE_QMAKE_PATH_EXTERNAL_HOST_BINS}/uic$$CMAKE_BIN_SUFFIX\") + !!ENDIF + _qt5_Widgets_check_file_exists(${imported_location}) + +diff --git a/tools/configure/configureapp.cpp b/tools/configure/configureapp.cpp +index b756509..7e61845 100644 +--- a/tools/configure/configureapp.cpp ++++ b/tools/configure/configureapp.cpp +@@ -1213,6 +1213,13 @@ void Configure::parseCmdLine() + dictionary[ "QT_EXT_PREFIX" ] = configCmdLine.at(i); + } + ++ else if (configCmdLine.at(i) == "-external-hostbindir") { ++ ++i; ++ if (i == argCount) ++ break; ++ dictionary[ "QT_EXTERNAL_HOST_BINS" ] = configCmdLine.at(i); ++ } ++ + else if (configCmdLine.at(i) == "-make-tool") { + ++i; + if (i == argCount) +@@ -3983,6 +3990,7 @@ void Configure::generateQConfigCpp() + << " \"qt_hbinpath=" << formatPath(dictionary["QT_HOST_BINS"]) << "\"," << endl + << " \"qt_hlibpath=" << formatPath(dictionary["QT_HOST_LIBS"]) << "\"," << endl + << " \"qt_hdatpath=" << formatPath(dictionary["QT_HOST_DATA"]) << "\"," << endl ++ << " \"qt_ebinpath=" << formatPath(dictionary["QT_EXTERNAL_HOST_BINS"]) << "\"," << endl + << " \"qt_targspec=" << targSpec << "\"," << endl + << " \"qt_hostspec=" << hostSpec << "\"," << endl + << "#endif" << endl +-- +2.0.0 + diff --git a/recipes-qt/qt5/qtbase-git/0003-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch b/recipes-qt/qt5/qtbase-git/0003-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch deleted file mode 100644 index 4b4e47ce..00000000 --- a/recipes-qt/qt5/qtbase-git/0003-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch +++ /dev/null @@ -1,39 +0,0 @@ -From b76b34a03c3051cda5330c8ae9f5e2a26c5c4da6 Mon Sep 17 00:00:00 2001 -From: Holger Freyther -Date: Wed, 26 Sep 2012 17:22:30 +0200 -Subject: [PATCH 3/8] qlibraryinfo: allow to set qt.conf from the outside using - the environment - -Allow to set a qt.conf from the outside using the environment. This allows -to inject new prefixes and other paths into qmake. This is needed when using -the same qmake binary to build qt/x11 and qt/embedded - -Upstream-Status: Inappropriate [embedded specific] - again very OE specific to read everything from environment (reusing the same - qmake from sstate and replacing all configured paths in it with qt.conf from - environment). - -Signed-off-by: Martin Jansa ---- - src/corelib/global/qlibraryinfo.cpp | 5 ++++- - 1 file changed, 4 insertions(+), 1 deletion(-) - -diff --git a/src/corelib/global/qlibraryinfo.cpp b/src/corelib/global/qlibraryinfo.cpp -index 3686b17..89e13cf 100644 ---- a/src/corelib/global/qlibraryinfo.cpp -+++ b/src/corelib/global/qlibraryinfo.cpp -@@ -153,7 +153,10 @@ QLibrarySettings::QLibrarySettings() - - QSettings *QLibraryInfoPrivate::findConfiguration() - { -- QString qtconfig = QStringLiteral(":/qt/etc/qt.conf"); -+ QByteArray config = getenv("QT_CONF_PATH"); -+ QString qtconfig = QFile::decodeName(config); -+ if(!QFile::exists(qtconfig)) -+ qtconfig = QStringLiteral(":/qt/etc/qt.conf"); - #ifdef QT_BOOTSTRAPPED - if(!QFile::exists(qtconfig)) - qtconfig = qt_libraryInfoFile(); --- -2.0.0 - diff --git a/recipes-qt/qt5/qtbase-git/0004-configureapp-Prefix-default-LIBDIRS-and-INCDIRS-with.patch b/recipes-qt/qt5/qtbase-git/0004-configureapp-Prefix-default-LIBDIRS-and-INCDIRS-with.patch index 1e5ffacf..78fb3c66 100644 --- a/recipes-qt/qt5/qtbase-git/0004-configureapp-Prefix-default-LIBDIRS-and-INCDIRS-with.patch +++ b/recipes-qt/qt5/qtbase-git/0004-configureapp-Prefix-default-LIBDIRS-and-INCDIRS-with.patch @@ -1,7 +1,7 @@ -From 83205b1344e57e2cb0292cf1d276e40c7f45ca32 Mon Sep 17 00:00:00 2001 +From 8a14a69d5b0078554ed002e682c72e995b1e6320 Mon Sep 17 00:00:00 2001 From: Martin Jansa Date: Sat, 27 Apr 2013 22:33:33 +0200 -Subject: [PATCH 4/8] configureapp: Prefix default LIBDIRS and INCDIRS with +Subject: [PATCH 04/12] configureapp: Prefix default LIBDIRS and INCDIRS with SYSROOT Upstream-Status: Pending diff --git a/recipes-qt/qt5/qtbase-git/0005-Revert-eglfs-Print-the-chosen-config-in-debug-mode.patch b/recipes-qt/qt5/qtbase-git/0005-Revert-eglfs-Print-the-chosen-config-in-debug-mode.patch deleted file mode 100644 index 213a9c34..00000000 --- a/recipes-qt/qt5/qtbase-git/0005-Revert-eglfs-Print-the-chosen-config-in-debug-mode.patch +++ /dev/null @@ -1,56 +0,0 @@ -From 22775e5f0b1097964062fbcf1805a841f971de34 Mon Sep 17 00:00:00 2001 -From: Martin Jansa -Date: Mon, 21 Apr 2014 19:22:04 +0200 -Subject: [PATCH 5/8] Revert "eglfs: Print the chosen config in debug mode" - -This reverts commit dc685cf6331f5fb46285cf10d6464c2ecf41f73e. ---- - src/platformsupport/eglconvenience/qeglconvenience.cpp | 4 +++- - src/platformsupport/eglconvenience/qeglplatformcontext.cpp | 7 ------- - 2 files changed, 3 insertions(+), 8 deletions(-) - -diff --git a/src/platformsupport/eglconvenience/qeglconvenience.cpp b/src/platformsupport/eglconvenience/qeglconvenience.cpp -index 5eed470..39c7c1f 100644 ---- a/src/platformsupport/eglconvenience/qeglconvenience.cpp -+++ b/src/platformsupport/eglconvenience/qeglconvenience.cpp -@@ -451,9 +451,11 @@ void q_printEglConfig(EGLDisplay display, EGLConfig config) - for (index = 0; attrs[index].attr != -1; ++index) { - EGLint value; - if (eglGetConfigAttrib(display, config, attrs[index].attr, &value)) { -- qDebug("\t%s: %d", attrs[index].name, (int)value); -+ qWarning("\t%s: %d\n", attrs[index].name, (int)value); - } - } -+ -+ qWarning("\n"); - } - - #ifdef Q_OS_LINUX -diff --git a/src/platformsupport/eglconvenience/qeglplatformcontext.cpp b/src/platformsupport/eglconvenience/qeglplatformcontext.cpp -index eec6463..4a7c69b 100644 ---- a/src/platformsupport/eglconvenience/qeglplatformcontext.cpp -+++ b/src/platformsupport/eglconvenience/qeglplatformcontext.cpp -@@ -44,7 +44,6 @@ - #include "qeglpbuffer_p.h" - #include - #include --#include - - QT_BEGIN_NAMESPACE - -@@ -192,12 +191,6 @@ void QEGLPlatformContext::init(const QSurfaceFormat &format, QPlatformOpenGLCont - return; - } - -- static const bool printConfig = qgetenv("QT_QPA_EGLFS_DEBUG").toInt(); -- if (printConfig) { -- qDebug() << "Created context for format" << format << "with config:"; -- q_printEglConfig(m_eglDisplay, m_eglConfig); -- } -- - #ifndef QT_NO_OPENGL - // Make the context current to ensure the GL version query works. This needs a surface too. - const EGLint pbufferAttributes[] = { --- -2.0.0 - diff --git a/recipes-qt/qt5/qtbase-git/0005-qt_module-Fix-pkgconfig-and-libtool-replacements.patch b/recipes-qt/qt5/qtbase-git/0005-qt_module-Fix-pkgconfig-and-libtool-replacements.patch new file mode 100644 index 00000000..29108cde --- /dev/null +++ b/recipes-qt/qt5/qtbase-git/0005-qt_module-Fix-pkgconfig-and-libtool-replacements.patch @@ -0,0 +1,81 @@ +From 1e87c127c5d268870c51894c955bf24cde83ff69 Mon Sep 17 00:00:00 2001 +From: Martin Jansa +Date: Sat, 27 Apr 2013 23:15:37 +0200 +Subject: [PATCH 05/12] qt_module: Fix pkgconfig and libtool replacements +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +* in situation like this: + QT_SYSROOT:/OE/oe-core/tmp-eglibc/sysroots/qemuarm + QT_INSTALL_LIBS:/OE/oe-core/tmp-eglibc/sysroots/qemuarm/usr/lib + QT_INSTALL_LIBS/raw:/usr/lib + QT_INSTALL_LIBS/get:/OE/oe-core/tmp-eglibc/work/armv5te-oe-linux-gnueabi/qtbase/5.0.0-r0.0/build/lib + + I don't want the replacement like this: + sed + -e "s,/OE/oe-core/tmp-eglibc/work/armv5te-oe-linux-gnueabi/qtbase/5.0.0-r0.0/build/include,/usr/include/qt5,g" + -e "s,/OE/oe-core/tmp-eglibc/work/armv5te-oe-linux-gnueabi/qtbase/5.0.0-r0.0/build/lib,/usr/lib,g" + "../../lib/pkgconfig/Qt5Core.pc" + >"/OE/oe-core/tmp-eglibc/work/armv5te-oe-linux-gnueabi/qtbase/5.0.0-r0.0/image/OE/oe-core/tmp-eglibc/sysroots/qemuarm/usr/lib/pkgconfig/Qt5Core.pc" + because that way I'll end with -L/usr/lib in .pc file which is + cross-compile unfriendly, keeping ${libdir}/${includedir} works better + in my case + +* qt_module: Fix paths in .prl files +* qmake does not prefix them with QT_SYSROOT when using them + so e.g. when building qtdeclarative we get -L/usr/lib to LINKAGE + variable, which is unsafe for cross-compilation +* writting QT_SYSROOT in .prl files is dangerous for sstate when + builds are in different directories, so we need + SSTATE_SCAN_FILES += "*.pri *.prl" + to make them relocateble + +* fix paths in packageconfig files + This reverts parts of: + + enable path replacement in installed prl files on all platforms + + Task-number: QTBUG-33794 + Change-Id: Id0d38715673b8a1c0c034e9c15783eb255c4315b + Reviewed-by: Joerg Bornemann + +Change-Id: Ie1c94b15f2a4e736b65b4d0924d99eb2a7d92a6c +Signed-off-by: Martin Jansa +Signed-off-by: Andreas Müller +--- + mkspecs/features/qt_module.prf | 14 ++++++++++++++ + 1 file changed, 14 insertions(+) + +diff --git a/mkspecs/features/qt_module.prf b/mkspecs/features/qt_module.prf +index 8bf4c92..9737f8c 100644 +--- a/mkspecs/features/qt_module.prf ++++ b/mkspecs/features/qt_module.prf +@@ -188,10 +188,24 @@ unix|mingw { + QMAKE_PKGCONFIG_DESCRIPTION = $$replace(TARGET, ^Qt, "Qt ") module + QMAKE_PKGCONFIG_INSTALL_REPLACE += lib_replace + ++ pkgconfig_include_replace.match = $$rplbase/include ++ pkgconfig_include_replace.replace = "\$$\\{includedir}" ++ pkgconfig_include_replace.CONFIG = path ++ QMAKE_PKGCONFIG_INSTALL_REPLACE += pkgconfig_include_replace ++ ++ pkgconfig_lib_replace.match = $$rplbase/lib ++ pkgconfig_lib_replace.replace = "\$$\\{libdir}" ++ pkgconfig_lib_replace.CONFIG = path ++ QMAKE_PKGCONFIG_INSTALL_REPLACE += pkgconfig_lib_replace ++ + unix { + CONFIG += create_libtool explicitlib + QMAKE_LIBTOOL_LIBDIR = $$qt_libdir + QMAKE_LIBTOOL_INSTALL_REPLACE += lib_replace ++ lafile_replace.match = "-L$$[QT_INSTALL_LIBS/raw]" ++ lafile_replace.replace = "" ++ lafile_replace.CONFIG = path ++ QMAKE_LIBTOOL_INSTALL_REPLACE += lafile_replace + } + } + +-- +2.0.0 + diff --git a/recipes-qt/qt5/qtbase-git/0006-Always-build-uic.patch b/recipes-qt/qt5/qtbase-git/0006-Always-build-uic.patch deleted file mode 100644 index f425c3e7..00000000 --- a/recipes-qt/qt5/qtbase-git/0006-Always-build-uic.patch +++ /dev/null @@ -1,31 +0,0 @@ -From dd679f743291a924bed500a866eb05fab71c9978 Mon Sep 17 00:00:00 2001 -From: Martin Jansa -Date: Sat, 16 Nov 2013 00:32:30 +0100 -Subject: [PATCH 6/8] Always build uic - -Even if we are not building gui or widgets. This tool is needed later -as a native tool when compiling the target. - -Change-Id: I257668ac28c22b192e7ec7736e6c23fa3be6bab6 -Signed-off-by: Mikko Levonmaa -Signed-off-by: Martin Jansa ---- - src/src.pro | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/src.pro b/src/src.pro -index 6a805a6..90623a6 100644 ---- a/src/src.pro -+++ b/src/src.pro -@@ -158,7 +158,7 @@ contains(QT_CONFIG, concurrent):SUBDIRS += src_concurrent - } - } - } --SUBDIRS += src_plugins src_tools_qdoc -+SUBDIRS += src_plugins src_tools_qdoc src_tools_uic - - nacl: SUBDIRS -= src_network src_testlib - --- -2.0.0 - diff --git a/recipes-qt/qt5/qtbase-git/0006-Revert-eglfs-Print-the-chosen-config-in-debug-mode.patch b/recipes-qt/qt5/qtbase-git/0006-Revert-eglfs-Print-the-chosen-config-in-debug-mode.patch new file mode 100644 index 00000000..0e3bc99e --- /dev/null +++ b/recipes-qt/qt5/qtbase-git/0006-Revert-eglfs-Print-the-chosen-config-in-debug-mode.patch @@ -0,0 +1,56 @@ +From ca212fd10a95b2c694f3c89c3f22a2b0ae185198 Mon Sep 17 00:00:00 2001 +From: Martin Jansa +Date: Mon, 21 Apr 2014 19:22:04 +0200 +Subject: [PATCH 06/12] Revert "eglfs: Print the chosen config in debug mode" + +This reverts commit dc685cf6331f5fb46285cf10d6464c2ecf41f73e. +--- + src/platformsupport/eglconvenience/qeglconvenience.cpp | 4 +++- + src/platformsupport/eglconvenience/qeglplatformcontext.cpp | 7 ------- + 2 files changed, 3 insertions(+), 8 deletions(-) + +diff --git a/src/platformsupport/eglconvenience/qeglconvenience.cpp b/src/platformsupport/eglconvenience/qeglconvenience.cpp +index 5eed470..39c7c1f 100644 +--- a/src/platformsupport/eglconvenience/qeglconvenience.cpp ++++ b/src/platformsupport/eglconvenience/qeglconvenience.cpp +@@ -451,9 +451,11 @@ void q_printEglConfig(EGLDisplay display, EGLConfig config) + for (index = 0; attrs[index].attr != -1; ++index) { + EGLint value; + if (eglGetConfigAttrib(display, config, attrs[index].attr, &value)) { +- qDebug("\t%s: %d", attrs[index].name, (int)value); ++ qWarning("\t%s: %d\n", attrs[index].name, (int)value); + } + } ++ ++ qWarning("\n"); + } + + #ifdef Q_OS_LINUX +diff --git a/src/platformsupport/eglconvenience/qeglplatformcontext.cpp b/src/platformsupport/eglconvenience/qeglplatformcontext.cpp +index eec6463..4a7c69b 100644 +--- a/src/platformsupport/eglconvenience/qeglplatformcontext.cpp ++++ b/src/platformsupport/eglconvenience/qeglplatformcontext.cpp +@@ -44,7 +44,6 @@ + #include "qeglpbuffer_p.h" + #include + #include +-#include + + QT_BEGIN_NAMESPACE + +@@ -192,12 +191,6 @@ void QEGLPlatformContext::init(const QSurfaceFormat &format, QPlatformOpenGLCont + return; + } + +- static const bool printConfig = qgetenv("QT_QPA_EGLFS_DEBUG").toInt(); +- if (printConfig) { +- qDebug() << "Created context for format" << format << "with config:"; +- q_printEglConfig(m_eglDisplay, m_eglConfig); +- } +- + #ifndef QT_NO_OPENGL + // Make the context current to ensure the GL version query works. This needs a surface too. + const EGLint pbufferAttributes[] = { +-- +2.0.0 + diff --git a/recipes-qt/qt5/qtbase-git/0006-qmake-don-t-build-it-in-configure-but-allow-to-build.patch b/recipes-qt/qt5/qtbase-git/0006-qmake-don-t-build-it-in-configure-but-allow-to-build.patch deleted file mode 100644 index 6d79acb6..00000000 --- a/recipes-qt/qt5/qtbase-git/0006-qmake-don-t-build-it-in-configure-but-allow-to-build.patch +++ /dev/null @@ -1,50 +0,0 @@ -From d8e725cb2c25a443d888fe2652f9039e79ae75ac Mon Sep 17 00:00:00 2001 -From: Michael Krelin -Date: Mon, 29 Oct 2012 20:07:49 -0700 -Subject: [PATCH 6/8] qmake: don't build it in configure, but allow to build it - separately - -* it is already built in qtbase-native, so we don't need it in configure -* allow building a separate qmake for the target - -Upstream-Status: Inappropriate [configuration] - OE specific for native/target builds - -Signed-off-by: Yu Ke -Signed-off-by: Paul Eggleton -Signed-off-by: Mikko Levonmaa -Signed-off-by: Martin Jansa ---- - configure | 2 +- - qmake/qmake.pro | 2 ++ - 2 files changed, 3 insertions(+), 1 deletion(-) - -diff --git a/configure b/configure -index 48d5119..2a42c08 100755 ---- a/configure -+++ b/configure -@@ -3675,7 +3675,7 @@ setBootstrapEvalVariable() - - - # build qmake --if true; then ###[ '!' -f "$outpath/bin/qmake" ]; -+if false; then ###[ '!' -f "$outpath/bin/qmake" ]; - echo "Creating qmake..." - - mkdir -p "$outpath/qmake" || exit -diff --git a/qmake/qmake.pro b/qmake/qmake.pro -index 89d6ea5..7c605b9 100644 ---- a/qmake/qmake.pro -+++ b/qmake/qmake.pro -@@ -8,6 +8,8 @@ CONFIG -= qt - DEFINES += \ - QT_BUILD_QMAKE \ - PROEVALUATOR_FULL -+DESTDIR = ../bin/ -+TARGET = qmake - - VPATH += \ - ../src/corelib/global \ --- -2.0.0 - diff --git a/recipes-qt/qt5/qtbase-git/0007-configure-preserve-built-qmake-and-swap-with-native-.patch b/recipes-qt/qt5/qtbase-git/0007-configure-preserve-built-qmake-and-swap-with-native-.patch deleted file mode 100644 index 79ac5e89..00000000 --- a/recipes-qt/qt5/qtbase-git/0007-configure-preserve-built-qmake-and-swap-with-native-.patch +++ /dev/null @@ -1,29 +0,0 @@ -From 3db5991e607a82403272b0ea821fc84e3c8b6d2a Mon Sep 17 00:00:00 2001 -From: Denys Dmytriyenko -Date: Mon, 11 Nov 2013 20:22:34 -0500 -Subject: [PATCH 7/8] configure: preserve built qmake and swap with native one - -Let configure script build the real qmake, but right after it's built, swap -it with a native qmake for further internal use, preserving the real one. - -Signed-off-by: Denys Dmytriyenko ---- - configure | 2 ++ - 1 file changed, 2 insertions(+) - -diff --git a/configure b/configure -index 48d5119..b7aac15 100755 ---- a/configure -+++ b/configure -@@ -3825,6 +3825,8 @@ if true; then ###[ '!' -f "$outpath/bin/qmake" ]; - - (cd "$outpath/qmake"; "$MAKE") || exit 2 - fi # Build qmake -+mv "$outpath/bin/qmake" "$outpath/bin/qmake-real" -+mv "$outpath/bin/qmake-native" "$outpath/bin/qmake" - - echo "Running configuration tests..." - --- -2.0.0 - diff --git a/recipes-qt/qt5/qtbase-git/0007-eglfs-fix-egl-error-for-platforms-only-supporting-on.patch b/recipes-qt/qt5/qtbase-git/0007-eglfs-fix-egl-error-for-platforms-only-supporting-on.patch deleted file mode 100644 index f8a789cd..00000000 --- a/recipes-qt/qt5/qtbase-git/0007-eglfs-fix-egl-error-for-platforms-only-supporting-on.patch +++ /dev/null @@ -1,72 +0,0 @@ -From cc8bd33740ee16b29e0801dbc2228314ef3cef2f Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Andreas=20M=C3=BCller?= -Date: Wed, 5 Feb 2014 18:35:08 +0100 -Subject: [PATCH 7/8] eglfs: fix egl error for platforms only supporting one - window/surface -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -running qmlscene -platform eglfs .qml - -caused - -EGL Error : Could not create the egl surface: error = 0x3003 - -Rebased version of [1-2] - -Upstream-Status: unknown - -[1] http://repository.timesys.com/buildsources/q/qt-everywhere-opensource/qt-everywhere-opensource-5.1.1/qt-everywhere-opensource-5.1.1-qeglfswindow.cpp.patch -[2] https://github.com/prabindh/qt-configs/blob/master/qt5_1.0_Feb13/qeglfswindow.cpp.patch - -Signed-off-by: Andreas Müller -Signed-off-by: Martin Jansa ---- - src/plugins/platforms/eglfs/qeglfswindow.cpp | 16 +++++++++++++++- - 1 file changed, 15 insertions(+), 1 deletion(-) - -diff --git a/src/plugins/platforms/eglfs/qeglfswindow.cpp b/src/plugins/platforms/eglfs/qeglfswindow.cpp -index 2d36c0b..854531e 100644 ---- a/src/plugins/platforms/eglfs/qeglfswindow.cpp -+++ b/src/plugins/platforms/eglfs/qeglfswindow.cpp -@@ -74,6 +74,15 @@ void QEglFSWindow::create() - - m_flags = Created; - -+ static EGLSurface __singleWindowSurface; -+ if(QEglFSHooks::hooks() && ! QEglFSHooks::hooks()->hasCapability(QPlatformIntegration::MultipleWindows) && (__singleWindowSurface)) { -+ m_surface = __singleWindowSurface; -+#ifdef QEGL_EXTRA_DEBUG -+ qWarning("Surface recreate request, re-using %x\n", m_surface); -+#endif -+ return; -+ } -+ - if (window()->type() == Qt::Desktop) - return; - -@@ -85,7 +94,7 @@ void QEglFSWindow::create() - if (isRaster() && screen->compositingWindow()) - return; - --#if !defined(Q_OS_ANDROID) || defined(Q_OS_ANDROID_NO_SDK) -+#if !defined(Q_OS_ANDROID) || defined(Q_OS_ANDROID_NO_SDK) || defined(EGL_API_FB) - // We can have either a single OpenGL window or multiple raster windows. - // Other combinations cannot work. - qFatal("EGLFS: OpenGL windows cannot be mixed with others."); -@@ -105,6 +114,11 @@ void QEglFSWindow::create() - - resetSurface(); - -+ if(QEglFSHooks::hooks() && !QEglFSHooks::hooks()->hasCapability(QPlatformIntegration::MultipleWindows)) -+ { -+ __singleWindowSurface = m_surface; -+ } -+ - screen->setPrimarySurface(m_surface); - - if (isRaster()) { --- -2.0.0 - diff --git a/recipes-qt/qt5/qtbase-git/0007-qeglplatformintegration-Undefine-CursorShape-from-X..patch b/recipes-qt/qt5/qtbase-git/0007-qeglplatformintegration-Undefine-CursorShape-from-X..patch new file mode 100644 index 00000000..1f029a28 --- /dev/null +++ b/recipes-qt/qt5/qtbase-git/0007-qeglplatformintegration-Undefine-CursorShape-from-X..patch @@ -0,0 +1,30 @@ +From 3d61189d1706d3367eada4e7db6f2c6c167130ce Mon Sep 17 00:00:00 2001 +From: Martin Jansa +Date: Wed, 19 Mar 2014 18:32:28 +0100 +Subject: [PATCH 07/12] qeglplatformintegration: Undefine CursorShape from X.h + +Signed-off-by: Martin Jansa +--- + src/platformsupport/eglconvenience/qeglplatformintegration_p.h | 6 ++++++ + 1 file changed, 6 insertions(+) + +diff --git a/src/platformsupport/eglconvenience/qeglplatformintegration_p.h b/src/platformsupport/eglconvenience/qeglplatformintegration_p.h +index f665455..9eb783c 100644 +--- a/src/platformsupport/eglconvenience/qeglplatformintegration_p.h ++++ b/src/platformsupport/eglconvenience/qeglplatformintegration_p.h +@@ -46,6 +46,12 @@ + #include + #include + ++// Undefine CursorShape from X.h, which is causing breakage in Qt::CursorShape in platformsupport/eglconvenience/ ++// /usr/include/X11/X.h:#define CursorShape 0 /* largest size that can be displayed */ ++#ifdef CursorShape ++#undef CursorShape ++#endif ++ + QT_BEGIN_NAMESPACE + + class QEGLPlatformScreen; +-- +2.0.0 + diff --git a/recipes-qt/qt5/qtbase-git/0008-configure-bump-path-length-from-256-to-512-character.patch b/recipes-qt/qt5/qtbase-git/0008-configure-bump-path-length-from-256-to-512-character.patch index e5a3890a..b1c4690b 100644 --- a/recipes-qt/qt5/qtbase-git/0008-configure-bump-path-length-from-256-to-512-character.patch +++ b/recipes-qt/qt5/qtbase-git/0008-configure-bump-path-length-from-256-to-512-character.patch @@ -1,7 +1,7 @@ -From 3eabdee39cad37a4ce451486fce20680f169a0f1 Mon Sep 17 00:00:00 2001 +From 107fe67947ced65315550e6a7795be24efaab371 Mon Sep 17 00:00:00 2001 From: Denys Dmytriyenko Date: Mon, 11 Nov 2013 20:27:30 -0500 -Subject: [PATCH 8/8] configure: bump path length from 256 to 512 characters +Subject: [PATCH 08/12] configure: bump path length from 256 to 512 characters Increase the path length that gets hardcoded into generated config.cpp file from 256 to 512 characters, as nativesdk path can be quite long. @@ -12,7 +12,7 @@ Signed-off-by: Denys Dmytriyenko 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure b/configure -index b7aac15..c51f785 100755 +index 48d5119..3c0347a 100755 --- a/configure +++ b/configure @@ -3573,7 +3573,7 @@ static const char qt_configure_licensed_products_str [256 + 12] = "qt_lcnsprod=$ diff --git a/recipes-qt/qt5/qtbase-git/0008-qeglplatformintegration-Undefine-CursorShape-from-X..patch b/recipes-qt/qt5/qtbase-git/0008-qeglplatformintegration-Undefine-CursorShape-from-X..patch deleted file mode 100644 index 2f4d80cd..00000000 --- a/recipes-qt/qt5/qtbase-git/0008-qeglplatformintegration-Undefine-CursorShape-from-X..patch +++ /dev/null @@ -1,30 +0,0 @@ -From 959b2fb8d8eb5e755e3d9d3d3031b996f96fb23b Mon Sep 17 00:00:00 2001 -From: Martin Jansa -Date: Wed, 19 Mar 2014 18:32:28 +0100 -Subject: [PATCH 8/8] qeglplatformintegration: Undefine CursorShape from X.h - -Signed-off-by: Martin Jansa ---- - src/platformsupport/eglconvenience/qeglplatformintegration_p.h | 6 ++++++ - 1 file changed, 6 insertions(+) - -diff --git a/src/platformsupport/eglconvenience/qeglplatformintegration_p.h b/src/platformsupport/eglconvenience/qeglplatformintegration_p.h -index f665455..9eb783c 100644 ---- a/src/platformsupport/eglconvenience/qeglplatformintegration_p.h -+++ b/src/platformsupport/eglconvenience/qeglplatformintegration_p.h -@@ -46,6 +46,12 @@ - #include - #include - -+// Undefine CursorShape from X.h, which is causing breakage in Qt::CursorShape in platformsupport/eglconvenience/ -+// /usr/include/X11/X.h:#define CursorShape 0 /* largest size that can be displayed */ -+#ifdef CursorShape -+#undef CursorShape -+#endif -+ - QT_BEGIN_NAMESPACE - - class QEGLPlatformScreen; --- -2.0.0 - diff --git a/recipes-qt/qt5/qtbase-git/0009-eglfs-fix-egl-error-for-platforms-only-supporting-on.patch b/recipes-qt/qt5/qtbase-git/0009-eglfs-fix-egl-error-for-platforms-only-supporting-on.patch new file mode 100644 index 00000000..cbd0bcd8 --- /dev/null +++ b/recipes-qt/qt5/qtbase-git/0009-eglfs-fix-egl-error-for-platforms-only-supporting-on.patch @@ -0,0 +1,72 @@ +From b8f2fdcd7683058554b5d76b270c5f4bb3d0b91a Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Andreas=20M=C3=BCller?= +Date: Wed, 5 Feb 2014 18:35:08 +0100 +Subject: [PATCH 09/12] eglfs: fix egl error for platforms only supporting one + window/surface +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +running qmlscene -platform eglfs .qml + +caused + +EGL Error : Could not create the egl surface: error = 0x3003 + +Rebased version of [1-2] + +Upstream-Status: unknown + +[1] http://repository.timesys.com/buildsources/q/qt-everywhere-opensource/qt-everywhere-opensource-5.1.1/qt-everywhere-opensource-5.1.1-qeglfswindow.cpp.patch +[2] https://github.com/prabindh/qt-configs/blob/master/qt5_1.0_Feb13/qeglfswindow.cpp.patch + +Signed-off-by: Andreas Müller +Signed-off-by: Martin Jansa +--- + src/plugins/platforms/eglfs/qeglfswindow.cpp | 16 +++++++++++++++- + 1 file changed, 15 insertions(+), 1 deletion(-) + +diff --git a/src/plugins/platforms/eglfs/qeglfswindow.cpp b/src/plugins/platforms/eglfs/qeglfswindow.cpp +index 2d36c0b..854531e 100644 +--- a/src/plugins/platforms/eglfs/qeglfswindow.cpp ++++ b/src/plugins/platforms/eglfs/qeglfswindow.cpp +@@ -74,6 +74,15 @@ void QEglFSWindow::create() + + m_flags = Created; + ++ static EGLSurface __singleWindowSurface; ++ if(QEglFSHooks::hooks() && ! QEglFSHooks::hooks()->hasCapability(QPlatformIntegration::MultipleWindows) && (__singleWindowSurface)) { ++ m_surface = __singleWindowSurface; ++#ifdef QEGL_EXTRA_DEBUG ++ qWarning("Surface recreate request, re-using %x\n", m_surface); ++#endif ++ return; ++ } ++ + if (window()->type() == Qt::Desktop) + return; + +@@ -85,7 +94,7 @@ void QEglFSWindow::create() + if (isRaster() && screen->compositingWindow()) + return; + +-#if !defined(Q_OS_ANDROID) || defined(Q_OS_ANDROID_NO_SDK) ++#if !defined(Q_OS_ANDROID) || defined(Q_OS_ANDROID_NO_SDK) || defined(EGL_API_FB) + // We can have either a single OpenGL window or multiple raster windows. + // Other combinations cannot work. + qFatal("EGLFS: OpenGL windows cannot be mixed with others."); +@@ -105,6 +114,11 @@ void QEglFSWindow::create() + + resetSurface(); + ++ if(QEglFSHooks::hooks() && !QEglFSHooks::hooks()->hasCapability(QPlatformIntegration::MultipleWindows)) ++ { ++ __singleWindowSurface = m_surface; ++ } ++ + screen->setPrimarySurface(m_surface); + + if (isRaster()) { +-- +2.0.0 + diff --git a/recipes-qt/qt5/qtbase-git/0010-Revert-Use-the-gcc-feature-in-simd.prf.patch b/recipes-qt/qt5/qtbase-git/0010-Revert-Use-the-gcc-feature-in-simd.prf.patch new file mode 100644 index 00000000..da05f28f --- /dev/null +++ b/recipes-qt/qt5/qtbase-git/0010-Revert-Use-the-gcc-feature-in-simd.prf.patch @@ -0,0 +1,26 @@ +From 8d8db9db8518289f4c1856dd3062c2e324c5c9be Mon Sep 17 00:00:00 2001 +From: Martin Jansa +Date: Wed, 4 Jun 2014 15:26:11 +0200 +Subject: [PATCH 10/12] Revert "Use the "gcc" feature in simd.prf" + +This reverts commit 3b00cc480400d47c59c29d3507c7fcdc9be2a489. +--- + mkspecs/features/simd.prf | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/mkspecs/features/simd.prf b/mkspecs/features/simd.prf +index 62a63f9..4f86f60 100644 +--- a/mkspecs/features/simd.prf ++++ b/mkspecs/features/simd.prf +@@ -18,7 +18,7 @@ QT_CPU_FEATURES = $$eval(QT_CPU_FEATURES.$$QT_ARCH) + # + # Set up compilers for SIMD (SSE/AVX, NEON etc) + # +-gcc { # includes intel_icc and clang variants ++*-g++*|intel_icc|*-clang*|*-qcc* { + sse2 { + HEADERS += $$SSE2_HEADERS + +-- +2.0.0 + diff --git a/recipes-qt/qt5/qtbase-git/0011-Always-build-uic.patch b/recipes-qt/qt5/qtbase-git/0011-Always-build-uic.patch new file mode 100644 index 00000000..a1af18e1 --- /dev/null +++ b/recipes-qt/qt5/qtbase-git/0011-Always-build-uic.patch @@ -0,0 +1,31 @@ +From 271db04ebfbaf67e2e8c30ff050510c5a42acfa4 Mon Sep 17 00:00:00 2001 +From: Martin Jansa +Date: Sat, 16 Nov 2013 00:32:30 +0100 +Subject: [PATCH 11/12] Always build uic + +Even if we are not building gui or widgets. This tool is needed later +as a native tool when compiling the target. + +Change-Id: I257668ac28c22b192e7ec7736e6c23fa3be6bab6 +Signed-off-by: Mikko Levonmaa +Signed-off-by: Martin Jansa +--- + src/src.pro | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/src/src.pro b/src/src.pro +index 6a805a6..90623a6 100644 +--- a/src/src.pro ++++ b/src/src.pro +@@ -158,7 +158,7 @@ contains(QT_CONFIG, concurrent):SUBDIRS += src_concurrent + } + } + } +-SUBDIRS += src_plugins src_tools_qdoc ++SUBDIRS += src_plugins src_tools_qdoc src_tools_uic + + nacl: SUBDIRS -= src_network src_testlib + +-- +2.0.0 + diff --git a/recipes-qt/qt5/qtbase-git/0011-qmake-don-t-build-it-in-configure-but-allow-to-build.patch b/recipes-qt/qt5/qtbase-git/0011-qmake-don-t-build-it-in-configure-but-allow-to-build.patch new file mode 100644 index 00000000..820fb21a --- /dev/null +++ b/recipes-qt/qt5/qtbase-git/0011-qmake-don-t-build-it-in-configure-but-allow-to-build.patch @@ -0,0 +1,50 @@ +From ac507c953112630d7e929be35586e97396b76327 Mon Sep 17 00:00:00 2001 +From: Michael Krelin +Date: Mon, 29 Oct 2012 20:07:49 -0700 +Subject: [PATCH 11/11] qmake: don't build it in configure, but allow to build + it separately + +* it is already built in qtbase-native, so we don't need it in configure +* allow building a separate qmake for the target + +Upstream-Status: Inappropriate [configuration] + OE specific for native/target builds + +Signed-off-by: Yu Ke +Signed-off-by: Paul Eggleton +Signed-off-by: Mikko Levonmaa +Signed-off-by: Martin Jansa +--- + configure | 2 +- + qmake/qmake.pro | 2 ++ + 2 files changed, 3 insertions(+), 1 deletion(-) + +diff --git a/configure b/configure +index 3c0347a..a75ca11 100755 +--- a/configure ++++ b/configure +@@ -3675,7 +3675,7 @@ setBootstrapEvalVariable() + + + # build qmake +-if true; then ###[ '!' -f "$outpath/bin/qmake" ]; ++if false; then ###[ '!' -f "$outpath/bin/qmake" ]; + echo "Creating qmake..." + + mkdir -p "$outpath/qmake" || exit +diff --git a/qmake/qmake.pro b/qmake/qmake.pro +index 89d6ea5..7c605b9 100644 +--- a/qmake/qmake.pro ++++ b/qmake/qmake.pro +@@ -8,6 +8,8 @@ CONFIG -= qt + DEFINES += \ + QT_BUILD_QMAKE \ + PROEVALUATOR_FULL ++DESTDIR = ../bin/ ++TARGET = qmake + + VPATH += \ + ../src/corelib/global \ +-- +2.0.0 + diff --git a/recipes-qt/qt5/qtbase-git/0012-configure-preserve-built-qmake-and-swap-with-native-.patch b/recipes-qt/qt5/qtbase-git/0012-configure-preserve-built-qmake-and-swap-with-native-.patch new file mode 100644 index 00000000..81b05f3d --- /dev/null +++ b/recipes-qt/qt5/qtbase-git/0012-configure-preserve-built-qmake-and-swap-with-native-.patch @@ -0,0 +1,30 @@ +From 11bd34bfe629767ec32a36593386ef0655e86f24 Mon Sep 17 00:00:00 2001 +From: Denys Dmytriyenko +Date: Mon, 11 Nov 2013 20:22:34 -0500 +Subject: [PATCH 12/12] configure: preserve built qmake and swap with native + one + +Let configure script build the real qmake, but right after it's built, swap +it with a native qmake for further internal use, preserving the real one. + +Signed-off-by: Denys Dmytriyenko +--- + configure | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/configure b/configure +index 3c0347a..c51f785 100755 +--- a/configure ++++ b/configure +@@ -3825,6 +3825,8 @@ if true; then ###[ '!' -f "$outpath/bin/qmake" ]; + + (cd "$outpath/qmake"; "$MAKE") || exit 2 + fi # Build qmake ++mv "$outpath/bin/qmake" "$outpath/bin/qmake-real" ++mv "$outpath/bin/qmake-native" "$outpath/bin/qmake" + + echo "Running configuration tests..." + +-- +2.0.0 + diff --git a/recipes-qt/qt5/qtbase-native_git.bb b/recipes-qt/qt5/qtbase-native_git.bb index e10748f0..79652920 100644 --- a/recipes-qt/qt5/qtbase-native_git.bb +++ b/recipes-qt/qt5/qtbase-native_git.bb @@ -5,19 +5,23 @@ SRC_URI = "\ git://qt.gitorious.org/qt/${QT_MODULE}.git;branch=${QT_MODULE_BRANCH} \ " -# common with -native +# common with -native and -nativesdk SRC_URI += "\ file://0001-Add-linux-oe-g-platform.patch \ - file://0002-Add-external-hostbindir-option.patch \ - file://0003-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch \ + file://0002-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch \ + file://0003-Add-external-hostbindir-option.patch \ file://0004-configureapp-Prefix-default-LIBDIRS-and-INCDIRS-with.patch \ - file://0005-Revert-eglfs-Print-the-chosen-config-in-debug-mode.patch \ - file://0001-Revert-Use-the-gcc-feature-in-simd.prf.patch \ + file://0005-qt_module-Fix-pkgconfig-and-libtool-replacements.patch \ + file://0006-Revert-eglfs-Print-the-chosen-config-in-debug-mode.patch \ + file://0007-qeglplatformintegration-Undefine-CursorShape-from-X..patch \ + file://0008-configure-bump-path-length-from-256-to-512-character.patch \ + file://0009-eglfs-fix-egl-error-for-platforms-only-supporting-on.patch \ + file://0010-Revert-Use-the-gcc-feature-in-simd.prf.patch \ " -# specific for native version +# common with -nativesdk version SRC_URI += " \ - file://0006-Always-build-uic.patch \ + file://0011-Always-build-uic.patch \ " do_install_append() { @@ -26,4 +30,4 @@ do_install_append() { ln -sf syncqt.pl ${D}${OE_QMAKE_PATH_QT_BINS}/syncqt } -SRCREV = "267ba8b63e0fbf02cde4d2709397ed0e12f34ee2" +SRCREV = "80b6fbc2d9dfc753d6570e971aa4cf4f3420585c" diff --git a/recipes-qt/qt5/qtbase_git.bb b/recipes-qt/qt5/qtbase_git.bb index 4f019be9..037a4f66 100644 --- a/recipes-qt/qt5/qtbase_git.bb +++ b/recipes-qt/qt5/qtbase_git.bb @@ -5,21 +5,23 @@ SRC_URI = "\ git://qt.gitorious.org/qt/${QT_MODULE}.git;branch=${QT_MODULE_BRANCH} \ " -# common with -native -SRC_URI += "\ +# common with -native and -nativesdk +SRC_URI += "\ file://0001-Add-linux-oe-g-platform.patch \ - file://0002-Add-external-hostbindir-option.patch \ - file://0003-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch \ + file://0002-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch \ + file://0003-Add-external-hostbindir-option.patch \ file://0004-configureapp-Prefix-default-LIBDIRS-and-INCDIRS-with.patch \ - file://0005-Revert-eglfs-Print-the-chosen-config-in-debug-mode.patch \ - file://0001-Revert-Use-the-gcc-feature-in-simd.prf.patch \ + file://0005-qt_module-Fix-pkgconfig-and-libtool-replacements.patch \ + file://0006-Revert-eglfs-Print-the-chosen-config-in-debug-mode.patch \ + file://0007-qeglplatformintegration-Undefine-CursorShape-from-X..patch \ + file://0008-configure-bump-path-length-from-256-to-512-character.patch \ + file://0009-eglfs-fix-egl-error-for-platforms-only-supporting-on.patch \ + file://0010-Revert-Use-the-gcc-feature-in-simd.prf.patch \ " - + # target specific SRC_URI += "\ - file://0006-qmake-don-t-build-it-in-configure-but-allow-to-build.patch \ - file://0007-eglfs-fix-egl-error-for-platforms-only-supporting-on.patch \ - file://0008-qeglplatformintegration-Undefine-CursorShape-from-X..patch \ + file://0011-qmake-don-t-build-it-in-configure-but-allow-to-build.patch \ " -SRCREV = "267ba8b63e0fbf02cde4d2709397ed0e12f34ee2" +SRCREV = "80b6fbc2d9dfc753d6570e971aa4cf4f3420585c" -- cgit v1.2.3-54-g00ecf