diff options
Diffstat (limited to 'recipes-qt/qt5/qtbase_git.bb')
-rw-r--r-- | recipes-qt/qt5/qtbase_git.bb | 90 |
1 files changed, 19 insertions, 71 deletions
diff --git a/recipes-qt/qt5/qtbase_git.bb b/recipes-qt/qt5/qtbase_git.bb index 6541973e..354a01ce 100644 --- a/recipes-qt/qt5/qtbase_git.bb +++ b/recipes-qt/qt5/qtbase_git.bb | |||
@@ -17,16 +17,12 @@ LIC_FILES_CHKSUM = " \ | |||
17 | # common for qtbase-native, qtbase-nativesdk and qtbase | 17 | # common for qtbase-native, qtbase-nativesdk and qtbase |
18 | SRC_URI += "\ | 18 | SRC_URI += "\ |
19 | file://0001-Add-linux-oe-g-platform.patch \ | 19 | file://0001-Add-linux-oe-g-platform.patch \ |
20 | file://0002-qlibraryinfo-allow-to-set-qt.conf-from-the-outside-u.patch \ | ||
21 | file://0003-Add-external-hostbindir-option.patch \ | 20 | file://0003-Add-external-hostbindir-option.patch \ |
22 | file://0004-qt_module-Fix-pkgconfig-and-libtool-replacements.patch \ | 21 | file://0004-qt_module-Fix-pkgconfig-and-libtool-replacements.patch \ |
23 | file://0005-configure-bump-path-length-from-256-to-512-character.patch \ | 22 | file://0005-configure-bump-path-length-from-256-to-512-character.patch \ |
24 | file://0006-QOpenGLPaintDevice-sub-area-support.patch \ | ||
25 | file://0007-linux-oe-g-Invert-conditional-for-defining-QT_SOCKLE.patch \ | ||
26 | file://0008-configure-paths-for-target-qmake-properly.patch \ | 23 | file://0008-configure-paths-for-target-qmake-properly.patch \ |
27 | file://0009-Reorder-EGL-libraries-from-pkgconfig-and-defaults.patch \ | 24 | file://0009-Disable-all-unknown-features-instead-of-erroring-out.patch \ |
28 | file://0010-Pretend-Qt5-wasn-t-found-if-OE_QMAKE_PATH_EXTERNAL_H.patch \ | 25 | file://0010-Pretend-Qt5-wasn-t-found-if-OE_QMAKE_PATH_EXTERNAL_H.patch \ |
29 | file://0013-Fix-build-with-QT_NO_OPENGL.patch \ | ||
30 | " | 26 | " |
31 | 27 | ||
32 | DEPENDS += "qtbase-native" | 28 | DEPENDS += "qtbase-native" |
@@ -39,16 +35,15 @@ RDEPENDS_${PN}-tools += "perl" | |||
39 | # separate some parts of PACKAGECONFIG which are often changed | 35 | # separate some parts of PACKAGECONFIG which are often changed |
40 | PACKAGECONFIG_GL ?= "${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'gl', '', d)}" | 36 | PACKAGECONFIG_GL ?= "${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'gl', '', d)}" |
41 | PACKAGECONFIG_FB ?= "${@bb.utils.contains('DISTRO_FEATURES', 'directfb', 'directfb', '', d)}" | 37 | PACKAGECONFIG_FB ?= "${@bb.utils.contains('DISTRO_FEATURES', 'directfb', 'directfb', '', d)}" |
42 | PACKAGECONFIG_X11 ?= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'xcb xsync xshape xrender xrandr xfixes xinput2 xcursor glib xkb', '', d)}" | 38 | PACKAGECONFIG_X11 ?= "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'xcb xrender xinput2 glib xkb xkbcommon-evdev', '', d)}" |
43 | PACKAGECONFIG_FONTS ?= "" | 39 | PACKAGECONFIG_FONTS ?= "" |
44 | PACKAGECONFIG_SYSTEM ?= "jpeg libpng zlib" | 40 | PACKAGECONFIG_SYSTEM ?= "jpeg libpng zlib" |
45 | PACKAGECONFIG_MULTIMEDIA ?= "${@bb.utils.contains('DISTRO_FEATURES', 'pulseaudio', 'pulseaudio', '', d)}" | ||
46 | PACKAGECONFIG_DISTRO ?= "" | 41 | PACKAGECONFIG_DISTRO ?= "" |
47 | # Either release or debug, can be overridden in bbappends | 42 | # Either release or debug, can be overridden in bbappends |
48 | PACKAGECONFIG_RELEASE ?= "release" | 43 | PACKAGECONFIG_RELEASE ?= "release" |
49 | # This is in qt5.inc, because qtwebkit-examples are using it to enable ca-certificates dependency | 44 | # This is in qt5.inc, because qtwebkit-examples are using it to enable ca-certificates dependency |
50 | # PACKAGECONFIG_OPENSSL ?= "openssl" | 45 | # PACKAGECONFIG_OPENSSL ?= "openssl" |
51 | PACKAGECONFIG_DEFAULT ?= "dbus udev evdev widgets tools libs" | 46 | PACKAGECONFIG_DEFAULT ?= "dbus udev evdev widgets tools libs freetype" |
52 | 47 | ||
53 | PACKAGECONFIG ?= " \ | 48 | PACKAGECONFIG ?= " \ |
54 | ${PACKAGECONFIG_RELEASE} \ | 49 | ${PACKAGECONFIG_RELEASE} \ |
@@ -59,34 +54,37 @@ PACKAGECONFIG ?= " \ | |||
59 | ${PACKAGECONFIG_X11} \ | 54 | ${PACKAGECONFIG_X11} \ |
60 | ${PACKAGECONFIG_FONTS} \ | 55 | ${PACKAGECONFIG_FONTS} \ |
61 | ${PACKAGECONFIG_SYSTEM} \ | 56 | ${PACKAGECONFIG_SYSTEM} \ |
62 | ${PACKAGECONFIG_MULTIMEDIA} \ | ||
63 | ${PACKAGECONFIG_DISTRO} \ | 57 | ${PACKAGECONFIG_DISTRO} \ |
64 | " | 58 | " |
65 | 59 | ||
66 | PACKAGECONFIG[release] = "-release,-debug" | 60 | PACKAGECONFIG[release] = "-release,-debug" |
67 | PACKAGECONFIG[debug] = "" | 61 | PACKAGECONFIG[debug] = "" |
68 | PACKAGECONFIG[developer] = "-developer-build" | 62 | PACKAGECONFIG[developer] = "-developer-build" |
63 | PACKAGECONFIG[qml-debug] = "-qml-debug,-no-qml-debug" | ||
69 | PACKAGECONFIG[sm] = "-sm,-no-sm" | 64 | PACKAGECONFIG[sm] = "-sm,-no-sm" |
70 | PACKAGECONFIG[tests] = "-make tests,-nomake tests" | 65 | PACKAGECONFIG[tests] = "-make tests,-nomake tests" |
71 | PACKAGECONFIG[examples] = "-make examples -compile-examples,-nomake examples" | 66 | PACKAGECONFIG[examples] = "-make examples -compile-examples,-nomake examples" |
72 | PACKAGECONFIG[tools] = "-make tools,-nomake tools" | 67 | PACKAGECONFIG[tools] = "-make tools,-nomake tools" |
73 | # only for completeness, configure will add libs even if you try to explicitly remove it | 68 | # only for completeness, configure will add libs even if you try to explicitly remove it |
74 | PACKAGECONFIG[libs] = "-make libs,-nomake libs" | 69 | PACKAGECONFIG[libs] = "-make libs" |
75 | # accessibility is required to compile qtquickcontrols | 70 | # accessibility is required to compile qtquickcontrols |
76 | PACKAGECONFIG[accessibility] = "-accessibility,-no-accessibility" | 71 | PACKAGECONFIG[accessibility] = "-accessibility,-no-accessibility" |
77 | PACKAGECONFIG[glib] = "-glib,-no-glib,glib-2.0" | 72 | PACKAGECONFIG[glib] = "-glib,-no-glib,glib-2.0" |
78 | # use either system freetype or bundled freetype, if you disable freetype completely | 73 | # use either system freetype or bundled freetype, if you disable freetype completely |
79 | # fontdatabases/basic/qbasicfontdatabase.cpp will fail to build and system freetype | 74 | # fontdatabases/basic/qbasicfontdatabase.cpp will fail to build and system freetype |
80 | # works only together with fontconfig | 75 | # works only together with fontconfig |
81 | PACKAGECONFIG[freetype] = "-system-freetype,-freetype,freetype" | 76 | PACKAGECONFIG[freetype] = "-system-freetype,-qt-freetype,freetype" |
82 | PACKAGECONFIG[harfbuzz] = "-system-harfbuzz,-no-harfbuzz,harfbuzz" | 77 | PACKAGECONFIG[harfbuzz] = "-system-harfbuzz,-no-harfbuzz,harfbuzz" |
83 | PACKAGECONFIG[jpeg] = "-system-libjpeg,-no-libjpeg,jpeg" | 78 | PACKAGECONFIG[jpeg] = "-system-libjpeg,-no-libjpeg,jpeg" |
84 | PACKAGECONFIG[libpng] = "-system-libpng,-no-libpng,libpng" | 79 | PACKAGECONFIG[libpng] = "-system-libpng,-no-libpng,libpng" |
80 | PACKAGECONFIG[gif] = "-gif,-no-gif" | ||
81 | PACKAGECONFIG[ico] = "-ico,-no-ico" | ||
85 | PACKAGECONFIG[zlib] = "-system-zlib,-qt-zlib,zlib" | 82 | PACKAGECONFIG[zlib] = "-system-zlib,-qt-zlib,zlib" |
86 | PACKAGECONFIG[pcre] = "-system-pcre,-qt-pcre,pcre" | 83 | PACKAGECONFIG[pcre] = "-system-pcre,-qt-pcre,pcre" |
87 | PACKAGECONFIG[eglfs] = "-eglfs,-no-eglfs,drm" | 84 | PACKAGECONFIG[eglfs] = "-eglfs,-no-eglfs,drm" |
88 | PACKAGECONFIG[gl] = "-opengl desktop,,virtual/libgl" | 85 | PACKAGECONFIG[gl] = "-opengl desktop,,virtual/libgl" |
89 | PACKAGECONFIG[gles2] = "-opengl es2,,virtual/libgles2 virtual/egl" | 86 | PACKAGECONFIG[gles2] = "-opengl es2,,virtual/libgles2 virtual/egl" |
87 | PACKAGECONFIG[no-opengl] = "-no-opengl" | ||
90 | PACKAGECONFIG[tslib] = "-tslib,-no-tslib,tslib" | 88 | PACKAGECONFIG[tslib] = "-tslib,-no-tslib,tslib" |
91 | PACKAGECONFIG[cups] = "-cups,-no-cups,cups" | 89 | PACKAGECONFIG[cups] = "-cups,-no-cups,cups" |
92 | PACKAGECONFIG[dbus] = "-dbus,-no-dbus,dbus" | 90 | PACKAGECONFIG[dbus] = "-dbus,-no-dbus,dbus" |
@@ -100,14 +98,8 @@ PACKAGECONFIG[sql-tds] = "-sql-tds,-no-sql-tds" | |||
100 | PACKAGECONFIG[sql-db2] = "-sql-db2,-no-sql-db2" | 98 | PACKAGECONFIG[sql-db2] = "-sql-db2,-no-sql-db2" |
101 | PACKAGECONFIG[sql-sqlite2] = "-sql-sqlite2,-no-sql-sqlite2,sqlite" | 99 | PACKAGECONFIG[sql-sqlite2] = "-sql-sqlite2,-no-sql-sqlite2,sqlite" |
102 | PACKAGECONFIG[sql-sqlite] = "-sql-sqlite -system-sqlite,-no-sql-sqlite,sqlite3" | 100 | PACKAGECONFIG[sql-sqlite] = "-sql-sqlite -system-sqlite,-no-sql-sqlite,sqlite3" |
103 | PACKAGECONFIG[xcursor] = "-xcursor,-no-xcursor,libxcursor" | ||
104 | PACKAGECONFIG[xinput2] = "-xinput2,-no-xinput2,libxi" | 101 | PACKAGECONFIG[xinput2] = "-xinput2,-no-xinput2,libxi" |
105 | PACKAGECONFIG[xfixes] = "-xfixes,-no-xfixes,libxfixes" | ||
106 | PACKAGECONFIG[xrandr] = "-xrandr,-no-xrandr,libxrandr" | ||
107 | PACKAGECONFIG[xrender] = "-xrender,-no-xrender,libxrender" | 102 | PACKAGECONFIG[xrender] = "-xrender,-no-xrender,libxrender" |
108 | PACKAGECONFIG[xshape] = "-xshape,-no-xshape" | ||
109 | PACKAGECONFIG[xsync] = "-xsync,-no-xsync" | ||
110 | PACKAGECONFIG[openvg] = "-openvg,-no-openvg" | ||
111 | PACKAGECONFIG[iconv] = "-iconv,-no-iconv,virtual/libiconv" | 103 | PACKAGECONFIG[iconv] = "-iconv,-no-iconv,virtual/libiconv" |
112 | PACKAGECONFIG[xkb] = "-xkb,-no-xkb -no-xkbcommon,libxkbcommon" | 104 | PACKAGECONFIG[xkb] = "-xkb,-no-xkb -no-xkbcommon,libxkbcommon" |
113 | PACKAGECONFIG[xkbcommon-evdev] = "-xkbcommon-evdev,-no-xkbcommon-evdev,libxkbcommon,xkeyboard-config" | 105 | PACKAGECONFIG[xkbcommon-evdev] = "-xkbcommon-evdev,-no-xkbcommon-evdev,libxkbcommon,xkeyboard-config" |
@@ -118,13 +110,11 @@ PACKAGECONFIG[fontconfig] = "-fontconfig,-no-fontconfig,fontconfig" | |||
118 | PACKAGECONFIG[gtk] = "-gtk,-no-gtk,gtk+" | 110 | PACKAGECONFIG[gtk] = "-gtk,-no-gtk,gtk+" |
119 | PACKAGECONFIG[directfb] = "-directfb,-no-directfb,directfb" | 111 | PACKAGECONFIG[directfb] = "-directfb,-no-directfb,directfb" |
120 | PACKAGECONFIG[linuxfb] = "-linuxfb,-no-linuxfb" | 112 | PACKAGECONFIG[linuxfb] = "-linuxfb,-no-linuxfb" |
121 | PACKAGECONFIG[mitshm] = "-mitshm,-no-mitshm,mitshm" | 113 | PACKAGECONFIG[kms] = "-kms,-no-kms,drm virtual/egl" |
122 | PACKAGECONFIG[kms] = "-kms,-no-kms,virtual/mesa virtual/egl" | 114 | PACKAGECONFIG[gbm] = "-gbm,-no-gbm,virtual/mesa" |
123 | PACKAGECONFIG[icu] = "-icu,-no-icu,icu" | 115 | PACKAGECONFIG[icu] = "-icu,-no-icu,icu" |
124 | PACKAGECONFIG[udev] = "-libudev,-no-libudev,udev" | 116 | PACKAGECONFIG[udev] = "-libudev,-no-libudev,udev" |
125 | PACKAGECONFIG[openssl] = "-openssl,-no-openssl,openssl,libssl" | 117 | PACKAGECONFIG[openssl] = "-openssl,-no-openssl,openssl,libssl" |
126 | PACKAGECONFIG[alsa] = "-alsa,-no-alsa,alsa-lib" | ||
127 | PACKAGECONFIG[pulseaudio] = "-pulseaudio,-no-pulseaudio,pulseaudio" | ||
128 | PACKAGECONFIG[widgets] = "-widgets,-no-widgets" | 118 | PACKAGECONFIG[widgets] = "-widgets,-no-widgets" |
129 | PACKAGECONFIG[libproxy] = "-libproxy,-no-libproxy,libproxy" | 119 | PACKAGECONFIG[libproxy] = "-libproxy,-no-libproxy,libproxy" |
130 | PACKAGECONFIG[libinput] = "-libinput,-no-libinput,libinput" | 120 | PACKAGECONFIG[libinput] = "-libinput,-no-libinput,libinput" |
@@ -139,44 +129,10 @@ QT_CONFIG_FLAGS += " \ | |||
139 | ${PACKAGECONFIG_CONFARGS} \ | 129 | ${PACKAGECONFIG_CONFARGS} \ |
140 | " | 130 | " |
141 | 131 | ||
142 | do_generate_qt_config_file_append() { | ||
143 | cat >> ${QT_CONF_PATH} <<EOF | ||
144 | |||
145 | [EffectivePaths] | ||
146 | Prefix=.. | ||
147 | EOF | ||
148 | } | ||
149 | |||
150 | # qtbase is exception, we need to use mkspecs from ${S} | ||
151 | QMAKE_MKSPEC_PATH = "${B}" | ||
152 | |||
153 | # another exception is that we need to run bin/qmake, because EffectivePaths are relative to qmake location | ||
154 | OE_QMAKE_QMAKE_ORIG := "${OE_QMAKE_QMAKE}" | ||
155 | OE_QMAKE_QMAKE = "bin/qmake" | ||
156 | |||
157 | # qtbase is exception, configure script is using our get(X)QEvalMakeConf and setBootstrapEvalVariable functions to read it from shell | ||
158 | export OE_QMAKE_COMPILER | ||
159 | export OE_QMAKE_CC | ||
160 | export OE_QMAKE_CFLAGS | ||
161 | export OE_QMAKE_CXX | ||
162 | export OE_QMAKE_CXXFLAGS | ||
163 | export OE_QMAKE_LINK | ||
164 | export OE_QMAKE_LDFLAGS | ||
165 | export OE_QMAKE_AR | ||
166 | export OE_QMAKE_STRIP | ||
167 | |||
168 | do_configure() { | 132 | do_configure() { |
169 | # we need symlink in path relative to source, because | ||
170 | # EffectivePaths:Prefix is relative to qmake location | ||
171 | if [ ! -e ${B}/bin/qmake ]; then | ||
172 | mkdir -p ${B}/bin | ||
173 | ln -sf ${OE_QMAKE_QMAKE_ORIG} ${B}/bin/qmake | ||
174 | fi | ||
175 | |||
176 | ${S}/configure -v \ | 133 | ${S}/configure -v \ |
177 | -opensource -confirm-license \ | 134 | -opensource -confirm-license \ |
178 | -sysroot ${STAGING_DIR_TARGET} \ | 135 | -sysroot ${STAGING_DIR_TARGET} \ |
179 | -no-gcc-sysroot \ | ||
180 | -prefix ${OE_QMAKE_PATH_PREFIX} \ | 136 | -prefix ${OE_QMAKE_PATH_PREFIX} \ |
181 | -bindir ${OE_QMAKE_PATH_BINS} \ | 137 | -bindir ${OE_QMAKE_PATH_BINS} \ |
182 | -libdir ${OE_QMAKE_PATH_LIBS} \ | 138 | -libdir ${OE_QMAKE_PATH_LIBS} \ |
@@ -192,37 +148,29 @@ do_configure() { | |||
192 | -translationdir ${OE_QMAKE_PATH_TRANSLATIONS} \ | 148 | -translationdir ${OE_QMAKE_PATH_TRANSLATIONS} \ |
193 | -testsdir ${OE_QMAKE_PATH_TESTS} \ | 149 | -testsdir ${OE_QMAKE_PATH_TESTS} \ |
194 | -examplesdir ${OE_QMAKE_PATH_EXAMPLES} \ | 150 | -examplesdir ${OE_QMAKE_PATH_EXAMPLES} \ |
151 | -hostprefix ${OE_QMAKE_PATH_HOST_PREFIX} \ | ||
152 | -hostlibdir ${OE_QMAKE_PATH_HOST_LIBS} \ | ||
195 | -hostbindir ${OE_QMAKE_PATH_HOST_BINS} \ | 153 | -hostbindir ${OE_QMAKE_PATH_HOST_BINS} \ |
196 | -external-hostbindir ${OE_QMAKE_PATH_EXTERNAL_HOST_BINS} \ | 154 | -external-hostbindir ${OE_QMAKE_PATH_EXTERNAL_HOST_BINS} \ |
197 | -hostdatadir ${OE_QMAKE_PATH_HOST_DATA} \ | 155 | -hostdatadir ${OE_QMAKE_PATH_HOST_DATA} \ |
198 | -platform ${OE_QMAKESPEC} \ | 156 | -platform ${OE_QMAKE_PLATFORM_NATIVE} \ |
199 | -xplatform linux-oe-g++ \ | 157 | -xplatform linux-oe-g++ \ |
200 | ${QT_CONFIG_FLAGS} | 158 | ${QT_CONFIG_FLAGS} |
201 | |||
202 | qmake5_base_do_configure | ||
203 | } | 159 | } |
204 | 160 | ||
205 | do_install_append() { | 161 | do_install_append() { |
206 | # Avoid qmake error "Cannot read [...]/usr/lib/qt5/mkspecs/oe-device-extra.pri: No such file or directory" | 162 | # Avoid qmake error "Cannot read [...]/usr/lib/qt5/mkspecs/oe-device-extra.pri: No such file or directory" |
207 | touch ${D}/${OE_QMAKE_PATH_QT_ARCHDATA}/mkspecs/oe-device-extra.pri | 163 | touch ${D}/${OE_QMAKE_PATH_QT_ARCHDATA}/mkspecs/oe-device-extra.pri |
208 | 164 | ||
209 | install -m 0755 ${B}/bin/qmake-target ${D}${OE_QMAKE_PATH_QT_BINS}/qmake | ||
210 | |||
211 | # Remove example.pro file as it is useless | ||
212 | rm -f ${D}${OE_QMAKE_PATH_EXAMPLES}/examples.pro | ||
213 | |||
214 | # Remove macx-ios-clang directory because /usr/lib/qt5/mkspecs/macx-ios-clang/rename_main.sh:#!/bin/bash | ||
215 | # triggers QA Issue: qtbase-mkspecs requires /bin/bash, but no providers in its RDEPENDS [file-rdeps] | ||
216 | rm -rf ${D}/${OE_QMAKE_PATH_QT_ARCHDATA}/mkspecs/macx-ios-clang | ||
217 | # and this one has /bin/bash shebang, but checkbashisms doesn't show any reason for it | ||
218 | sed -i 's@^#!/bin/bash$@#!/bin/sh@g' ${D}/${OE_QMAKE_PATH_QT_ARCHDATA}/mkspecs/features/data/mac/objc_namespace.sh | ||
219 | |||
220 | # Replace host paths with qmake built-in properties | 165 | # Replace host paths with qmake built-in properties |
221 | sed -i -e 's|${STAGING_DIR_NATIVE}${prefix_native}|$$[QT_HOST_PREFIX]|g' \ | 166 | sed -i -e 's|${STAGING_DIR_NATIVE}${prefix_native}|$$[QT_HOST_PREFIX/get]|g' \ |
222 | -e 's|${STAGING_DIR_HOST}|$$[QT_SYSROOT]|g' \ | 167 | -e 's|${STAGING_DIR_HOST}|$$[QT_SYSROOT]|g' \ |
223 | ${D}/${OE_QMAKE_PATH_QT_ARCHDATA}/mkspecs/*.pri | 168 | ${D}/${OE_QMAKE_PATH_QT_ARCHDATA}/mkspecs/*.pri |
224 | } | 169 | } |
225 | 170 | ||
171 | # mkspecs have mac specific scripts that depend on perl and bash | ||
172 | INSANE_SKIP_${PN}-mkspecs += "file-rdeps" | ||
173 | |||
226 | RRECOMMENDS_${PN}-plugins += "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'libx11-locale', '', d)}" | 174 | RRECOMMENDS_${PN}-plugins += "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'libx11-locale', '', d)}" |
227 | 175 | ||
228 | SRCREV = "69b43e74d78e050cf5e40197acafa4bc9f90c0bd" | 176 | SRCREV = "49dc9aa409d727824f26b246054a22b5a7dd5980" |