bump to release (5.8.0) and adjust/change to sha256 hashes
[feed/video.git] / frameworks / qt5base / Makefile
1 #
2 # Copyright (C) 2016 OpenWrt.org
3 # Author: Mirko Vogt <mirko-openwrt@nanl.de>
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 # TODO / known bugs:
9 # - plugins don't work when sstrip is used for stripping
10 # - no X11/wayland/xcb/kms support so far - primary target is linuxfb
11
12 include $(TOPDIR)/rules.mk
13
14 PKG_NAME:=qt5base
15 PKG_VERSION:=5.8.0
16 PKG_RELEASE:=1
17 PKG_HASH:=c17111ae02a44dc7be1ec2cf979a47ee9e58edf4904041a525c21f4fa53fc005
18
19 PKG_SYS_NAME:=qtbase-opensource-src-$(PKG_VERSION)
20 PKG_SOURCE:=$(PKG_SYS_NAME).tar.xz
21 PKG_SOURCE_URL:=http://download.qt-project.org/official_releases/qt/$(basename $(PKG_VERSION))/$(PKG_VERSION)/submodules
22
23 PKG_BUILD_DIR=$(BUILD_DIR)/$(PKG_SYS_NAME)
24 PKG_BUILD_PARALLEL:=1
25 PKG_BUILD_DEPENDS:=librpc
26 PKG_INSTALL:=1
27 PKG_USE_MIPS16:=0
28
29 include $(INCLUDE_DIR)/package.mk
30 include $(INCLUDE_DIR)/nls.mk
31 include ./files/qmake.mk
32
33 PKG_CONFIG_DEPENDS:= \
34 CONFIG_PACKAGE_qt5base-plugin-imageformats-jpeg \
35 CONFIG_PACKAGE_qt5base-plugin-imageformats-png \
36 CONFIG_PACKAGE_qt5base-network \
37 CONFIG_PACKAGE_qt5base-gui \
38 CONFIG_PACKAGE_qt5base-gl \
39 CONFIG_PACKAGE_qt5base-widgets \
40 CONFIG_PACKAGE_qt5base-examples \
41 CONFIG_PACKAGE_qt5base-plugin-platforms-minimal \
42 CONFIG_PACKAGE_qt5base-plugin-platforms-linuxfb \
43 # CONFIG_PACKAGE_qt5base-plugin-platforms-eglfs \
44 # CONFIG_PACKAGE_qt5base-plugin-platforms-minimalegl \
45
46 # Do not use sstrip for QT5. When sstrip is used the QT5 plugin loading does
47 # not work, because of QT''s internal elf parser, see
48 # https://bugreports.qt.io/browse/QTBUG-52567
49 # Use the code from the gcc package to use strip instaed.
50 ifneq ($(CONFIG_USE_SSTRIP),)
51 STRIP:=$(TARGET_CROSS)strip $(call qstrip,$(CONFIG_STRIP_ARGS))
52 RSTRIP:= \
53 export CROSS="$(TARGET_CROSS)" \
54 $(if $(CONFIG_KERNEL_KALLSYMS),NO_RENAME=1) \
55 $(if $(CONFIG_KERNEL_PROFILING),KEEP_SYMBOLS=1); \
56 NM="$(TARGET_CROSS)nm" \
57 STRIP="$(STRIP)" \
58 STRIP_KMOD="$(SCRIPT_DIR)/strip-kmod.sh" \
59 $(SCRIPT_DIR)/rstrip.sh
60 endif
61
62 define Package/qt5base/Default
63 SECTION:=video-frameworks
64 CATEGORY:=Video
65 SUBMENU:=Frameworks and Toolkits
66 TITLE:=Qt5base
67 URL:=http://qt.io
68 MAINTAINER:=Mirko Vogt <mirko@openwrt.org>
69 endef
70
71 # define Package/qt5base
72 # $(call Package/qt5base/Default)
73 # DEPENDS:=
74 # MENU:=1
75 # endef
76
77 define Package/qt5base-concurrent
78 $(call Package/qt5base/Default)
79 TITLE+=concurrent
80 DEPENDS+=+qt5base-core
81 endef
82
83 define Package/qt5base-gl
84 $(call Package/qt5base/Default)
85 TITLE+=gl
86 DEPENDS+=+qt5base-core +qt5base-gui +qt5base-widgets
87 endef
88
89 define Package/qt5base-core
90 $(call Package/qt5base/Default)
91 TITLE+=core
92 DEPENDS+=+libpthread +zlib +libpcre16 +libstdcpp +librt +libdouble-conversion $(ICONV_DEPENDS) #+icu
93 endef
94
95 define Package/qt5base-gui
96 $(call Package/qt5base/Default)
97 TITLE+=gui
98 DEPENDS+=+qt5base-core +qt5quick2-2d-sw-renderer-GLstubs +libpng +fontconfig +libfreetype +libudev
99 endef
100
101 define Package/qt5base-network
102 $(call Package/qt5base/Default)
103 TITLE+=network
104 DEPENDS+=+qt5base-core +libopenssl
105 endef
106
107 # seems to be only present as static lib
108 # define Package/qt5base-paltformSupport
109 # $(call Package/qt5base/Default)
110 # DEPENDS+=
111 # endef
112
113 define Package/qt5base-printSupport
114 $(call Package/qt5base/Default)
115 TITLE+=print support
116 DEPENDS+=+qt5base-core +qt5base-gui +qt5base-widgets
117 endef
118
119 define Package/qt5base-sql
120 $(call Package/qt5base/Default)
121 TITLE+=sql
122 DEPENDS+=+qt5base-core
123 endef
124
125 define Package/qt5base-test
126 $(call Package/qt5base/Default)
127 TITLE+=test
128 DEPENDS+=+qt5base-core
129 endef
130
131 define Package/qt5base-widgets
132 $(call Package/qt5base/Default)
133 TITLE+=widgets
134 DEPENDS+=+qt5base-core +qt5base-gui
135 endef
136
137 define Package/qt5base-xml
138 $(call Package/qt5base/Default)
139 TITLE+=xml
140 DEPENDS+=+qt5base-core
141 endef
142
143 #### plugins
144
145 ####### bearer
146
147 define Package/qt5base-plugin-bearer-generic
148 $(call Package/qt5base/Default)
149 TITLE+=bearer (plugin)
150 DEPENDS+=+qt5base-core +qt5base-network
151 endef
152
153 ####### generic / input
154
155 define Package/qt5base-plugin-input-evdevkeyboard
156 $(call Package/qt5base/Default)
157 TITLE+=evdev keyboard (plugin)
158 DEPENDS+=+qt5base-core +qt5base-gui +libfreetype +fontconfig
159 endef
160
161 define Package/qt5base-plugin-input-evdevmouse
162 $(call Package/qt5base/Default)
163 TITLE+=evdev mouse (plugin)
164 DEPENDS+=+qt5base-core +qt5base-gui +libfreetype +fontconfig
165 endef
166
167 define Package/qt5base-plugin-input-evdevtablet
168 $(call Package/qt5base/Default)
169 TITLE+=evdev tablet (plugin)
170 DEPENDS+=+qt5base-core +qt5base-gui +libfreetype +fontconfig
171 endef
172
173 define Package/qt5base-plugin-input-evdevtouch
174 $(call Package/qt5base/Default)
175 TITLE+=evdev touch (plugin)
176 DEPENDS+=+qt5base-core +qt5base-gui +libfreetype +fontconfig
177 endef
178
179 ####### imageformats
180
181 #define Package/qt5base-plugin-imageformats-gif
182 # $(call Package/qt5base/Default)
183 #TITLE+=imageformat gif (plugin)
184 # DEPENDS+=+qt5base-core +qt5base-gui
185 #endef
186
187 define Package/qt5base-plugin-imageformats-ico
188 $(call Package/qt5base/Default)
189 TITLE+=imageformat ico (plugin)
190 DEPENDS+=+qt5base-core +qt5base-gui
191 endef
192
193 define Package/qt5base-plugin-imageformats-jpeg
194 $(call Package/qt5base/Default)
195 TITLE+=imageformat jpeg (plugin)
196 DEPENDS+=+qt5base-core +qt5base-gui +libjpeg
197 endef
198
199 ####### platforms
200
201 #define Package/qt5base-plugin-platforms-eglfs
202 # $(call Package/qt5base/Default)
203 # TITLE+=platform eglfs (plugin)
204 # DEPENDS+=+qt5base-core +qt5base-gui +libfreetype +fontconfig
205 #endef
206
207 #define Package/qt5base-plugin-platforms-minimalegl
208 # $(call Package/qt5base/Default)
209 # TITLE+=platform minimalegl (plugin)
210 # DEPENDS+=+qt5base-core +qt5base-gui +libfreetype +fontconfig
211 #endef
212
213 define Package/qt5base-plugin-platforms-linuxfb
214 $(call Package/qt5base/Default)
215 TITLE+=platform linuxfb (plugin)
216 DEPENDS+=+qt5base-core +qt5base-gui +libfreetype +fontconfig
217 endef
218
219 define Package/qt5base-plugin-platforms-minimal
220 $(call Package/qt5base/Default)
221 TITLE+=platform minimal (plugin)
222 DEPENDS+=+qt5base-core +qt5base-gui +libfreetype +fontconfig
223 endef
224
225 define Package/qt5base-plugin-platforms-offscreen
226 $(call Package/qt5base/Default)
227 TITLE+=platform offscreen (plugin)
228 DEPENDS+=+qt5base-core +qt5base-gui +libfreetype +fontconfig
229 endef
230
231 define Package/qt5base-plugin-platforms-vnc
232 $(call Package/qt5base/Default)
233 TITLE+=platform vnc (plugin)
234 DEPENDS+=+qt5base-core +qt5base-gui +qt5base-network +libfreetype +fontconfig
235 endef
236
237
238
239 ###### sql
240
241 #define Package/qt5base-plugin-sqldrivers-sqlite
242 # $(call Package/qt5base/Default)
243 # TITLE+=sqldriver sqlite (plugin)
244 # DEPENDS+=+qt5base-core +qt5base-sql +libsqlite3
245 #endef
246
247 define Package/qt5base-examples
248 $(call Package/qt5base/Default)
249 TITLE+=examples
250 DEPENDS+=\
251 +qt5base-core \
252 +qt5base-gui \
253 +qt5base-widgets \
254 +qt5base-network \
255 +qt5base-sql \
256 +qt5base-xml \
257 +qt5base-printSupport \
258 +qt5base-concurrent \
259 +qt5base-gl
260 endef
261
262 define Build/Prepare
263 $(call Build/Prepare/Default)
264 $(CP) \
265 ./files/mkspecs/linux-openwrt-g++ \
266 $(PKG_BUILD_DIR)/mkspecs/
267 endef
268
269 # TARGET_CFLAGS += \
270 # -I$(STAGING_DIR)/usr/include/freetype2 \
271 # -I$(STAGING_DIR)/usr/include/libdrm
272
273 define Build/Configure
274 # CROSS/TARGET_* need to be passed to configure, in order to use cross-compiling tools to check for requirements.
275 # Usually used variables such as CC/CXX/CFLAGS/CXXFLAGS/LDFLAGS would be used for compilation of host tools (qmake, moc, etc.),
276 # hence we use the TARGET_* nomenclature.
277 ( cd $(PKG_BUILD_DIR) ; \
278 TARGET_CROSS="$(TARGET_CROSS)" \
279 TARGET_CFLAGS="$(TARGET_CFLAGS)" \
280 TARGET_CXXFLAGS="$(TARGET_CFLAGS) $(TARGET_CXXFLAGS)" \
281 TARGET_LDFLAGS="$(TARGET_LDFLAGS)" \
282 ./configure \
283 -prefix $(QT_INSTALL_PREFIX) \
284 -extprefix $(QT_EXTPREFIX) \
285 -hostprefix $(QT_HOST_PREFIX) \
286 -no-gcc-sysroot \
287 -bindir $(QT_INSTALL_BINS) \
288 -headerdir $(QT_INSTALL_HEADERS) \
289 -libdir $(QT_INSTALL_LIBS) \
290 -archdatadir $(QT_INSTALL_ARCHDATA) \
291 -plugindir $(QT_INSTALL_PLUGINS) \
292 -libexecdir $(QT_INSTALL_LIBEXECS) \
293 -importdir $(QT_INSTALL_IMPORTS) \
294 -qmldir $(QT_INSTALL_QML) \
295 -datadir $(QT_INSTALL_DATA) \
296 -docdir $(QT_INSTALL_DOCS) \
297 -translationdir $(QT_INSTALL_TRANSLATIONS) \
298 -sysconfdir $(QT_INSTALL_CONFIGURATION) \
299 -examplesdir $(QT_INSTALL_EXAMPLES) \
300 -testsdir $(QT_INSTALL_TESTS) \
301 -hostbindir $(QT_HOST_BINS) \
302 -hostlibdir $(QT_HOST_LIBS) \
303 -hostdatadir $(QT_HOST_DATA) \
304 -verbose \
305 -opensource \
306 -confirm-license \
307 -release \
308 -no-optimized-tools \
309 -no-strip \
310 -shared \
311 -no-framework \
312 -xplatform linux-openwrt-g++ \
313 -no-sse3 \
314 -no-ssse3 \
315 -no-sse4.1 \
316 -no-sse4.2 \
317 -no-avx \
318 -no-avx2 \
319 -no-avx512 \
320 $(if $(findstring -mdsp,$(TARGET_CFLAGS)),,-no-mips_dsp) \
321 $(if $(findstring -mdspr2,$(TARGET_CFLAGS)),,-no-mips_dspr2) \
322 -no-reduce-exports \
323 -no-reduce-relocations \
324 -no-pch \
325 -no-use-gold-linker \
326 -no-warnings-are-errors \
327 -pkg-config \
328 -no-optimized-qmake \
329 -nomake tools \
330 -make examples \
331 $(if $(CONFIG_PACKAGE_qt5base-examples),-compile-examples,-no-compile-examples) \
332 $(if $(CONFIG_PACKAGE_qt5base-examples),-make examples,-nomake examples) \
333 $(if $(CONFIG_PACKAGE_qt5base-gui),-gui,-no-gui) \
334 $(if $(CONFIG_PACKAGE_qt5base-widgets),-widgets,-no-widgets) \
335 -no-dbus \
336 -accessibility \
337 -no-qml-debug \
338 -system-doubleconversion \
339 -no-glib \
340 -eventfd \
341 -no-inotify \
342 $(if $(CONFIG_BUILD_NLS),-no-iconv,-no-iconv) \
343 -no-icu \
344 -system-pcre \
345 -system-zlib \
346 -no-journald \
347 -no-syslog \
348 -ssl \
349 $(if $(CONFIG_PACKAGE_qt5base-network),-openssl-linked,-no-openssl) \
350 -system-proxies \
351 -no-cups \
352 -fontconfig \
353 -system-freetype \
354 -no-harfbuzz \
355 -no-gtk \
356 -opengl \
357 -no-xcb-xlib \
358 $(if $(CONFIG_PACKAGE_qt5base-plugin-platforms-minimal),,-qpa minimal) \
359 $(if $(CONFIG_PACKAGE_qt5base-plugin-platforms-linuxfb),,-qpa linuxfb) \
360 -system-xcb \
361 -no-directfb \
362 -no-eglfs \
363 -no-gbm \
364 -no-kms \
365 $(if $(CONFIG_PACKAGE_qt5base-plugin-platforms-linuxfb),-linuxfb,-no-linuxfb) \
366 -no-mirclient \
367 -no-xcb \
368 -evdev \
369 -no-libinput \
370 -no-mtdev \
371 -no-tslib \
372 -no-xinput2 \
373 -no-xkbcommon-x11 \
374 -no-xkbcommon-evdev \
375 -no-gif \
376 $(if $(CONFIG_PACKAGE_qt5base-plugin-imageformats-ico),-ico,-no-ico) \
377 $(if $(CONFIG_PACKAGE_qt5base-gui),-system-libpng,-no-libpng) \
378 $(if $(CONFIG_PACKAGE_qt5base-plugin-imageformats-jpeg),-system-libjpeg,-no-libjpeg) \
379 -no-sql-db2 \
380 -no-sql-ibase \
381 -no-sql-mysql \
382 -no-sql-oci \
383 -no-sql-odbc \
384 -no-sql-psql \
385 -no-sql-sqlite \
386 -no-sql-sqlite2 \
387 -no-sql-tds \
388 -no-libproxy \
389 -system-xkbcommon \
390 )
391 endef
392
393 define Build/InstallDev
394 $(INSTALL_DIR) \
395 $(STAGING_DIR)/host/mk
396
397 $(CP) \
398 ./files/qmake.mk \
399 $(STAGING_DIR)/host/mk/
400
401 $(call Build/Install/HostFiles,$(1))
402 $(call Build/Install/Headers,$(1))
403 $(call Build/Install/Libs,$(1),*)
404 endef
405
406 define Package/qt5base-concurrent/install
407 $(call Build/Install/Libs,$(1),libQt5Concurrent)
408 endef
409
410 define Package/qt5base-core/install
411 $(call Build/Install/Libs,$(1),libQt5Core)
412 endef
413
414 define Package/qt5base-gl/install
415 $(call Build/Install/Libs,$(1),libQt5OpenGL)
416 endef
417
418 define Package/qt5base-gui/install
419 $(call Build/Install/Libs,$(1),libQt5Gui)
420 endef
421
422 define Package/qt5base-network/install
423 $(call Build/Install/Libs,$(1),libQt5Network)
424 endef
425
426 define Package/qt5base-printSupport/install
427 $(call Build/Install/Libs,$(1),libQt5PrintSupport)
428 endef
429
430 define Package/qt5base-sql/install
431 $(call Build/Install/Libs,$(1),libQt5Sql)
432 endef
433
434 define Package/qt5base-test/install
435 $(call Build/Install/Libs,$(1),libQt5Test)
436 endef
437
438 define Package/qt5base-widgets/install
439 $(call Build/Install/Libs,$(1),libQt5Widgets)
440 endef
441
442 define Package/qt5base-xml/install
443 $(call Build/Install/Libs,$(1),libQt5Xml)
444 endef
445
446 define Package/qt5base-plugin-bearer-generic/install
447 $(call Build/Install/Plugins,$(1),bearer,libqgenericbearer)
448 endef
449
450 define Package/qt5base-plugin-input-evdevkeyboard/install
451 $(call Build/Install/Plugins,$(1),generic,libqevdevkeyboardplugin)
452 endef
453
454 define Package/qt5base-plugin-input-evdevmouse/install
455 $(call Build/Install/Plugins,$(1),generic,libqevdevmouseplugin)
456 endef
457
458 define Package/qt5base-plugin-input-evdevtablet/install
459 $(call Build/Install/Plugins,$(1),generic,libqevdevtabletplugin)
460 endef
461
462 define Package/qt5base-plugin-input-evdevtouch/install
463 $(call Build/Install/Plugins,$(1),generic,libqevdevtouchplugin)
464 endef
465
466 #define Package/qt5base-plugin-imageformats-gif/install
467 # $(call Build/Install/Plugins,$(1),imageformats,libqgif)
468 #endef
469
470 define Package/qt5base-plugin-imageformats-ico/install
471 $(call Build/Install/Plugins,$(1),imageformats,libqico)
472 endef
473
474 define Package/qt5base-plugin-imageformats-jpeg/install
475 $(call Build/Install/Plugins,$(1),imageformats,libqjpeg)
476 endef
477
478 define Package/qt5base-plugin-platforms-linuxfb/install
479 $(call Build/Install/Plugins,$(1),platforms,libqlinuxfb)
480 endef
481
482 define Package/qt5base-plugin-platforms-vnc/install
483 $(call Build/Install/Plugins,$(1),platforms,libqvnc)
484 endef
485
486 #define Package/qt5base-plugin-platforms-eglfs/install
487 # $(call Build/Install/Plugins,$(1),platforms,libqeglfs)
488 #endef
489
490 #define Package/qt5base-plugin-platforms-minimalegl/install
491 # $(call Build/Install/Plugins,$(1),platforms,libqminimalegl)
492 #endef
493
494 define Package/qt5base-plugin-platforms-minimal/install
495 $(call Build/Install/Plugins,$(1),platforms,libqminimal)
496 endef
497
498 define Package/qt5base-plugin-platforms-offscreen/install
499 $(call Build/Install/Plugins,$(1),platforms,libqoffscreen)
500 endef
501
502 #define Package/qt5base-plugin-sqldrivers-sqlite/install
503 # $(call Build/Install/Plugins,$(1),sqldrivers,libqsqlite)
504 #endef
505
506 define Package/qt5base-examples/install
507 $(call Build/Install/Examples,$(1))
508 endef
509
510 # $(eval $(call BuildPackage,qt5base))
511 $(eval $(call BuildPackage,qt5base-concurrent))
512 $(eval $(call BuildPackage,qt5base-core))
513 $(eval $(call BuildPackage,qt5base-gui))
514 $(eval $(call BuildPackage,qt5base-gl))
515 $(eval $(call BuildPackage,qt5base-network))
516 $(eval $(call BuildPackage,qt5base-printSupport))
517 $(eval $(call BuildPackage,qt5base-sql))
518 $(eval $(call BuildPackage,qt5base-test))
519 $(eval $(call BuildPackage,qt5base-widgets))
520 $(eval $(call BuildPackage,qt5base-xml))
521 $(eval $(call BuildPackage,qt5base-plugin-bearer-generic))
522 $(eval $(call BuildPackage,qt5base-plugin-input-evdevkeyboard))
523 $(eval $(call BuildPackage,qt5base-plugin-input-evdevmouse))
524 $(eval $(call BuildPackage,qt5base-plugin-input-evdevtablet))
525 $(eval $(call BuildPackage,qt5base-plugin-input-evdevtouch))
526 #$(eval $(call BuildPackage,qt5base-plugin-imageformats-gif))
527 $(eval $(call BuildPackage,qt5base-plugin-imageformats-ico))
528 $(eval $(call BuildPackage,qt5base-plugin-imageformats-jpeg))
529 $(eval $(call BuildPackage,qt5base-plugin-platforms-linuxfb))
530 #$(eval $(call BuildPackage,qt5base-plugin-platforms-eglfs))
531 #$(eval $(call BuildPackage,qt5base-plugin-platforms-minimalegl))
532 $(eval $(call BuildPackage,qt5base-plugin-platforms-minimal))
533 $(eval $(call BuildPackage,qt5base-plugin-platforms-offscreen))
534 $(eval $(call BuildPackage,qt5base-plugin-platforms-vnc))
535 #$(eval $(call BuildPackage,qt5base-plugin-sqldrivers-sqlite))
536 $(eval $(call BuildPackage,qt5base-examples))