diff options
author | Samuli Piippo <samuli.piippo@qt.io> | 2016-06-03 10:11:46 +0300 |
---|---|---|
committer | Samuli Piippo <samuli.piippo@qt.io> | 2016-06-03 10:11:46 +0300 |
commit | 2746cdba75f411541d80ddfd5cadad2753fe29d3 (patch) | |
tree | 71b5e49cd3dbe1179a2ff866ee6b7cc0e7fbbd92 /recipes-qt/qt5/qtbase | |
parent | 6bd7ab491793d92f0942d9d8726873a514302849 (diff) | |
parent | 27617dde3560e2fe97989670725eb19747a0f48d (diff) | |
download | meta-qt5-2746cdba75f411541d80ddfd5cadad2753fe29d3.tar.gz |
Merge remote-tracking branch 'meta-qt5/master' into 5.7
* meta-qt5/master:
qtchooser: add new recipe
qtvirtualkeyboard: add recipe
qtdeclarative-render2d: add recipe
qtdatavis3d: add recipe
qtcharts: add recipe
licenses: update technology preview license to match upstream
cmake_qt5: prepend the Qt5 specific CMake variables to EXTRA_OECMAKE
qtbase: add patch to make Qt5Config modules behave better with cmake builds
qt5: Allow disabling SHA validation for branch
qtbase: Reorder EGL libraries from pkgconfig and defaults:
Change-Id: If0804ddb8c506e6f0d1ec32251cca6620dd97abe
Diffstat (limited to 'recipes-qt/qt5/qtbase')
-rw-r--r-- | recipes-qt/qt5/qtbase/0011-Pretend-Qt5-wasn-t-found-if-OE_QMAKE_PATH_EXTERNAL_H.patch | 67 | ||||
-rw-r--r-- | recipes-qt/qt5/qtbase/0011-Reorder-EGL-libraries-from-pkgconfig-and-defaults.patch | 98 |
2 files changed, 165 insertions, 0 deletions
diff --git a/recipes-qt/qt5/qtbase/0011-Pretend-Qt5-wasn-t-found-if-OE_QMAKE_PATH_EXTERNAL_H.patch b/recipes-qt/qt5/qtbase/0011-Pretend-Qt5-wasn-t-found-if-OE_QMAKE_PATH_EXTERNAL_H.patch new file mode 100644 index 00000000..7a24459c --- /dev/null +++ b/recipes-qt/qt5/qtbase/0011-Pretend-Qt5-wasn-t-found-if-OE_QMAKE_PATH_EXTERNAL_H.patch | |||
@@ -0,0 +1,67 @@ | |||
1 | From f5a949e17aa8b37491fbc414c38557c9920fa1e5 Mon Sep 17 00:00:00 2001 | ||
2 | From: Pascal Bach <pascal.bach@siemens.com> | ||
3 | Date: Wed, 11 May 2016 15:20:41 +0200 | ||
4 | Subject: [PATCH] Pretend Qt5 wasn't found if OE_QMAKE_PATH_EXTERNAL_HOST_BINS | ||
5 | isn't set | ||
6 | |||
7 | This prevents errors like: | ||
8 | |||
9 | | The imported target "Qt5::Core" references the file | ||
10 | | | ||
11 | | "/qmake" | ||
12 | | | ||
13 | | but this file does not exist. Possible reasons include: | ||
14 | |||
15 | Which happen if CMake is used without setting OE_QMAKE_PATH_EXTERNAL_HOST_BINS. | ||
16 | To achieve this a check for OE_QMAKE_PATH_EXTERNAL_HOST_BINS is added to each Qt5*Config.cmake | ||
17 | file. And in the case where the variable is not set we just return which is basically | ||
18 | equal to telling CMake that Qt5 wasn't found. | ||
19 | |||
20 | Upstream-Status: Pending | ||
21 | The patch only makes sense in connection with other patches included here. | ||
22 | Specifically this are: | ||
23 | - 0003-Add-external-hostbindir-option.patch | ||
24 | - 0010-Add-external-hostbindir-option-for-native-sdk.patch | ||
25 | |||
26 | Signed-off-by: Pascal Bach <pascal.bach@siemens.com> | ||
27 | |||
28 | --- | ||
29 | mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in | 5 +++++ | ||
30 | src/corelib/Qt5Config.cmake.in | 5 +++++ | ||
31 | 2 files changed, 10 insertions(+) | ||
32 | |||
33 | diff --git a/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in b/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in | ||
34 | index d2358ca..feb73c0 100644 | ||
35 | --- a/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in | ||
36 | +++ b/mkspecs/features/data/cmake/Qt5BasicConfig.cmake.in | ||
37 | @@ -9,6 +9,11 @@ if (CMAKE_VERSION VERSION_LESS 3.0.0) | ||
38 | endif() | ||
39 | !!ENDIF | ||
40 | |||
41 | +if(NOT DEFINED OE_QMAKE_PATH_EXTERNAL_HOST_BINS) | ||
42 | + message(WARNING "Skipping because OE_QMAKE_PATH_EXTERNAL_HOST_BINS is not defined") | ||
43 | + return() | ||
44 | +endif() | ||
45 | + | ||
46 | !!IF !isEmpty(CMAKE_USR_MOVE_WORKAROUND) | ||
47 | !!IF !isEmpty(CMAKE_LIB_DIR_IS_ABSOLUTE) | ||
48 | set(_qt5$${CMAKE_MODULE_NAME}_install_prefix \"$$[QT_INSTALL_PREFIX]\") | ||
49 | diff --git a/src/corelib/Qt5Config.cmake.in b/src/corelib/Qt5Config.cmake.in | ||
50 | index a872d0e..233d663 100644 | ||
51 | --- a/src/corelib/Qt5Config.cmake.in | ||
52 | +++ b/src/corelib/Qt5Config.cmake.in | ||
53 | @@ -3,6 +3,11 @@ if (CMAKE_VERSION VERSION_LESS 2.8.9) | ||
54 | message(FATAL_ERROR \"Qt5 requires at least CMake version 2.8.9\") | ||
55 | endif() | ||
56 | |||
57 | +if(NOT DEFINED OE_QMAKE_PATH_EXTERNAL_HOST_BINS) | ||
58 | + message(WARNING "Skipping because OE_QMAKE_PATH_EXTERNAL_HOST_BINS is not defined") | ||
59 | + return() | ||
60 | +endif() | ||
61 | + | ||
62 | if (NOT Qt5_FIND_COMPONENTS) | ||
63 | set(Qt5_NOT_FOUND_MESSAGE \"The Qt5 package requires at least one component\") | ||
64 | set(Qt5_FOUND False) | ||
65 | -- | ||
66 | 2.1.4 | ||
67 | |||
diff --git a/recipes-qt/qt5/qtbase/0011-Reorder-EGL-libraries-from-pkgconfig-and-defaults.patch b/recipes-qt/qt5/qtbase/0011-Reorder-EGL-libraries-from-pkgconfig-and-defaults.patch new file mode 100644 index 00000000..3c0b9e61 --- /dev/null +++ b/recipes-qt/qt5/qtbase/0011-Reorder-EGL-libraries-from-pkgconfig-and-defaults.patch | |||
@@ -0,0 +1,98 @@ | |||
1 | From d623d2c2ed49c4dc57fb0dde1faab20976dfc3dc Mon Sep 17 00:00:00 2001 | ||
2 | From: Julien Gueytat <contact@jgueytat.fr> | ||
3 | Date: Wed, 27 Apr 2016 19:24:39 +0200 | ||
4 | Subject: [PATCH] Reorder EGL libraries from pkgconfig and defaults: | ||
5 | |||
6 | https://bugreports.qt.io/browse/QTBUG-50838 | ||
7 | https://bugreports.qt.io/browse/QTBUG-52739 | ||
8 | |||
9 | The modification is the less intrusive possible. It only swaps LIBS and QMAKE_LIBS_EGL. | ||
10 | The reason behind that was that for the RaspberryPi: | ||
11 | * -lEGL -GLESv2 can link | ||
12 | * -lGLESv2 -lEGL can't | ||
13 | |||
14 | Adding -lEGL -lGLESv2 and then -lEGL gives -lGLESv2 -lEGL ... the libraries swaped. | ||
15 | |||
16 | Signed-off-by: Julien Gueytat <contact@jgueytat.fr> | ||
17 | --- | ||
18 | config.tests/qpa/egl/egl.pro | 5 ++++- | ||
19 | config.tests/qpa/eglfs-brcm/eglfs-brcm.pro | 12 +++++++----- | ||
20 | configure | 16 ++++++++++++++-- | ||
21 | 3 files changed, 25 insertions(+), 8 deletions(-) | ||
22 | |||
23 | diff --git a/config.tests/qpa/egl/egl.pro b/config.tests/qpa/egl/egl.pro | ||
24 | index b5396da..828b674 100644 | ||
25 | --- a/config.tests/qpa/egl/egl.pro | ||
26 | +++ b/config.tests/qpa/egl/egl.pro | ||
27 | @@ -5,6 +5,9 @@ for(p, QMAKE_LIBDIR_EGL) { | ||
28 | } | ||
29 | |||
30 | !isEmpty(QMAKE_INCDIR_EGL): INCLUDEPATH += $$QMAKE_INCDIR_EGL | ||
31 | -!isEmpty(QMAKE_LIBS_EGL): LIBS += $$QMAKE_LIBS_EGL | ||
32 | + | ||
33 | +BACKUP_LIBS = $$LIBS | ||
34 | +!isEmpty(QMAKE_LIBS_EGL): LIBS = $$QMAKE_LIBS_EGL | ||
35 | +LIBS += $$BACKUP_LIBS | ||
36 | |||
37 | CONFIG -= qt | ||
38 | diff --git a/config.tests/qpa/eglfs-brcm/eglfs-brcm.pro b/config.tests/qpa/eglfs-brcm/eglfs-brcm.pro | ||
39 | index d8b1c3e..06f7241 100644 | ||
40 | --- a/config.tests/qpa/eglfs-brcm/eglfs-brcm.pro | ||
41 | +++ b/config.tests/qpa/eglfs-brcm/eglfs-brcm.pro | ||
42 | @@ -1,11 +1,13 @@ | ||
43 | SOURCES = eglfs-brcm.cpp | ||
44 | |||
45 | -CONFIG -= qt | ||
46 | - | ||
47 | -INCLUDEPATH += $$QMAKE_INCDIR_EGL | ||
48 | - | ||
49 | for(p, QMAKE_LIBDIR_EGL) { | ||
50 | LIBS += -L$$p | ||
51 | } | ||
52 | |||
53 | -LIBS += -lEGL -lGLESv2 -lbcm_host | ||
54 | +INCLUDEPATH += $$QMAKE_INCDIR_EGL | ||
55 | + | ||
56 | +BACKUP_LIBS = $$LIBS | ||
57 | +LIBS = -lEGL -lGLESv2 -lbcm_host | ||
58 | +LIBS += $$BACKUP_LIBS | ||
59 | + | ||
60 | +CONFIG -= qt | ||
61 | diff --git a/configure b/configure | ||
62 | index 2e99d39..072838b 100755 | ||
63 | --- a/configure | ||
64 | +++ b/configure | ||
65 | @@ -5803,7 +5803,9 @@ if [ "$CFG_EGL" != "no" ]; then | ||
66 | QMakeVar set QMAKE_INCDIR_EGL "$QMAKE_INCDIR_EGL" | ||
67 | QMakeVar set QMAKE_LIBS_EGL "$QMAKE_LIBS_EGL" | ||
68 | QMakeVar set QMAKE_CFLAGS_EGL "`echo " $QMAKE_CFLAGS_EGL " | sed -e 's, -I[^ ]* , ,g;s,^ ,,;s, $,,'`" | ||
69 | - fi # detect EGL support | ||
70 | + fi | ||
71 | + | ||
72 | + # detect EGL support | ||
73 | if compileTest qpa/egl "EGL" $QMAKE_CFLAGS_EGL $QMAKE_LIBS_EGL; then | ||
74 | CFG_EGL=yes | ||
75 | if compileTest qpa/egl-x11 "EGL-X11" $QMAKE_CFLAGS_EGL $QMAKE_LIBS_EGL; then | ||
76 | @@ -5826,8 +5828,18 @@ fi | ||
77 | if [ "$CFG_EGLFS" != "no" ]; then | ||
78 | if [ "$XPLATFORM_QNX" = "no" ] && [ "$CFG_OPENGL" != "no" ]; then | ||
79 | CFG_EGLFS="$CFG_EGL" | ||
80 | + | ||
81 | + if [ -n "$PKG_CONFIG" ] && $PKG_CONFIG --exists egl 2>/dev/null; then | ||
82 | + QMAKE_INCDIR_EGL=`$PKG_CONFIG --cflags-only-I egl 2>/dev/null | sed -e 's,^-I,,g' -e 's, -I, ,g'` | ||
83 | + QMAKE_LIBS_EGL=`$PKG_CONFIG --libs egl 2>/dev/null` | ||
84 | + QMAKE_CFLAGS_EGL=`$PKG_CONFIG --cflags egl 2>/dev/null` | ||
85 | + QMakeVar set QMAKE_INCDIR_EGL "$QMAKE_INCDIR_EGL" | ||
86 | + QMakeVar set QMAKE_LIBS_EGL "$QMAKE_LIBS_EGL" | ||
87 | + QMakeVar set QMAKE_CFLAGS_EGL "`echo " $QMAKE_CFLAGS_EGL " | sed -e 's, -I[^ ]* , ,g;s,^ ,,;s, $,,'`" | ||
88 | + fi | ||
89 | + | ||
90 | # Detect eglfs backends. | ||
91 | - if compileTest qpa/eglfs-brcm "eglfs-brcm"; then | ||
92 | + if compileTest qpa/eglfs-brcm "eglfs-brcm" $QMAKE_CFLAGS_EGL $QMAKE_LIBS_EGL; then | ||
93 | CFG_EGLFS_BRCM=yes | ||
94 | else | ||
95 | CFG_EGLFS_BRCM=no | ||
96 | -- | ||
97 | 1.9.1 | ||
98 | |||