2 # Copyright (C) 2015 OpenWrt.org
3 # Author: Mirko Vogt <mirko@openwrt.org>
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
9 # - plugins don't work when sstrip is used for stripping
10 # - only framebuffer (linuxfb) support for now, XBC/DirectFB to come - thus no GL thus no qtquick2 / QML2, as it has a hard dependency on GL
11 # - host_build functionality seems to be broken - qmake doesn't switch to the host toolchain (linux-g++) when host_build gets invoked
13 include $(TOPDIR
)/rules.mk
18 PKG_MD5SUM
:=67a95eec79ffc4a14f516ad6f3d24c96
20 PKG_SYS_NAME
:=qtbase-opensource-src-
$(PKG_VERSION
)
21 PKG_SOURCE
:=$(PKG_SYS_NAME
).
tar.xz
22 PKG_SOURCE_URL
:=http
://download.qt-project.org
/official_releases
/qt
/$(basename $(PKG_VERSION
))/$(PKG_VERSION
)/submodules
24 PKG_BUILD_DIR
=$(BUILD_DIR
)/$(PKG_SYS_NAME
)
26 PKG_BUILD_DEPENDS
:=librpc
29 include $(INCLUDE_DIR
)/package.mk
30 include $(INCLUDE_DIR
)/nls.mk
31 include .
/files
/qmake.mk
33 define Package
/qt5base
/Default
34 SECTION
:=video-frameworks
36 SUBMENU
:=Frameworks and Toolkits
40 MAINTAINER
:=Mirko Vogt
<mirko@openwrt.org
>
43 define Package
/qt5base
44 $(call Package
/qt5base
/Default
)
49 define Package
/qt5base-concurrent
50 $(call Package
/qt5base
/Default
)
52 DEPENDS
+=+qt5base-core
55 define Package
/qt5base-core
56 $(call Package
/qt5base
/Default
)
58 DEPENDS
+=+libpthread
+zlib
+libpcre16
+libstdcpp
+librt
61 define Package
/qt5base-gui
62 $(call Package
/qt5base
/Default
)
64 DEPENDS
+=+qt5base-core
+libpng
67 define Package
/qt5base-network
68 $(call Package
/qt5base
/Default
)
70 DEPENDS
+=+qt5base-core
+libopenssl
73 # seems to be only present as static lib
74 # define Package/qt5base-paltformSupport
75 # $(call Package/qt5base/Default)
79 define Package
/qt5base-printSupport
80 $(call Package
/qt5base
/Default
)
82 DEPENDS
+=+qt5base-core
+qt5base-gui
+qt5base-widgets
85 define Package
/qt5base-sql
86 $(call Package
/qt5base
/Default
)
88 DEPENDS
+=+qt5base-core
91 define Package
/qt5base-test
92 $(call Package
/qt5base
/Default
)
94 DEPENDS
+=+qt5base-core
97 define Package
/qt5base-widgets
98 $(call Package
/qt5base
/Default
)
100 DEPENDS
+=+qt5base-core
+qt5base-gui
103 define Package
/qt5base-xml
104 $(call Package
/qt5base
/Default
)
106 DEPENDS
+=+qt5base-core
113 define Package
/qt5base-plugin-bearer-generic
114 $(call Package
/qt5base
/Default
)
115 TITLE
+=bearer
(plugin
)
116 DEPENDS
+=+qt5base-core
+qt5base-network
119 ####### generic / input
121 define Package
/qt5base-plugin-input-evdevkeyboard
122 $(call Package
/qt5base
/Default
)
123 TITLE
+=evdev keyboard
(plugin
)
124 DEPENDS
+=+qt5base-core
+qt5base-gui
+libfreetype
+fontconfig
127 define Package
/qt5base-plugin-input-evdevmouse
128 $(call Package
/qt5base
/Default
)
129 TITLE
+=evdev mouse
(plugin
)
130 DEPENDS
+=+qt5base-core
+qt5base-gui
+libfreetype
+fontconfig
133 define Package
/qt5base-plugin-input-evdevtablet
134 $(call Package
/qt5base
/Default
)
135 TITLE
+=evdev tablet
(plugin
)
136 DEPENDS
+=+qt5base-core
+qt5base-gui
+libfreetype
+fontconfig
139 define Package
/qt5base-plugin-input-evdevtouch
140 $(call Package
/qt5base
/Default
)
141 TITLE
+=evdev touch
(plugin
)
142 DEPENDS
+=+qt5base-core
+qt5base-gui
+libfreetype
+fontconfig
147 define Package
/qt5base-plugin-imageformats-gif
148 $(call Package
/qt5base
/Default
)
149 TITLE
+=imageformat gif
(plugin
)
150 DEPENDS
+=+qt5base-core
+qt5base-gui
153 define Package
/qt5base-plugin-imageformats-ico
154 $(call Package
/qt5base
/Default
)
155 TITLE
+=imageformat ico
(plugin
)
156 DEPENDS
+=+qt5base-core
+qt5base-gui
159 define Package
/qt5base-plugin-imageformats-jpeg
160 $(call Package
/qt5base
/Default
)
161 TITLE
+=imageformat jpeg
(plugin
)
162 DEPENDS
+=+qt5base-core
+qt5base-gui
+libjpeg
167 define Package
/qt5base-plugin-platforms-linuxfb
168 $(call Package
/qt5base
/Default
)
169 TITLE
+=platform linuxfb
(plugin
)
170 DEPENDS
+=+qt5base-core
+qt5base-gui
+libfreetype
+fontconfig
173 define Package
/qt5base-plugin-platforms-minimal
174 $(call Package
/qt5base
/Default
)
175 TITLE
+=platform minimal
(plugin
)
176 DEPENDS
+=+qt5base-core
+qt5base-gui
+libfreetype
+fontconfig
179 define Package
/qt5base-plugin-platforms-offscreen
180 $(call Package
/qt5base
/Default
)
181 TITLE
+=platform offscreen
(plugin
)
182 DEPENDS
+=+qt5base-core
+qt5base-gui
+libfreetype
+fontconfig
187 define Package
/qt5base-plugin-sqldrivers-sqlite
188 $(call Package
/qt5base
/Default
)
189 TITLE
+=sqldriver sqlite
(plugin
)
190 DEPENDS
+=+qt5base-core
+qt5base-sql
+libsqlite3
193 define Package
/qt5base-examples
194 $(call Package
/qt5base
/Default
)
203 +qt5base-printSupport \
208 $(call Build
/Prepare
/Default
)
210 .
/files
/mkspecs
/linux-openwrt-g
++ \
211 $(PKG_BUILD_DIR
)/mkspecs
/
214 define Build
/Configure
215 # CROSS/TARGET_* need to be passed to configure, in order to use cross-compiling tools to check for requirements.
216 # Usually used variables such as CC/CXX/CFLAGS/CXXFLAGS/LDFLAGS would be used for compilation of host tools (qmake, moc, etc.),
217 # hence we use the TARGET_* nomenclature.
218 ( cd
$(PKG_BUILD_DIR
) ; \
219 TARGET_CROSS
="$(TARGET_CROSS)" \
220 TARGET_CFLAGS
="$(TARGET_CFLAGS)" \
221 TARGET_CXXFLAGS
="$(TARGET_CFLAGS) $(TARGET_CXXFLAGS)" \
222 TARGET_LDFLAGS
="$(TARGET_LDFLAGS)" \
224 -prefix $(QT_INSTALL_PREFIX
) \
225 -extprefix
$(QT_EXTPREFIX
) \
226 -hostprefix
$(QT_HOST_PREFIX
) \
227 -bindir $(QT_INSTALL_BINS
) \
228 -headerdir
$(QT_INSTALL_HEADERS
) \
229 -libdir $(QT_INSTALL_LIBS
) \
230 -archdatadir
$(QT_INSTALL_ARCHDATA
) \
231 -plugindir
$(QT_INSTALL_PLUGINS
) \
232 -libexecdir
$(QT_INSTALL_LIBEXECS
) \
233 -importdir
$(QT_INSTALL_IMPORTS
) \
234 -qmldir
$(QT_INSTALL_QML
) \
235 -datadir $(QT_INSTALL_DATA
) \
236 -docdir
$(QT_INSTALL_DOCS
) \
237 -translationdir
$(QT_INSTALL_TRANSLATIONS
) \
238 -sysconfdir
$(QT_INSTALL_CONFIGURATION
) \
239 -examplesdir
$(QT_INSTALL_EXAMPLES
) \
240 -testsdir
$(QT_INSTALL_TESTS
) \
241 -hostbindir
$(QT_HOST_BINS
) \
242 -hostlibdir
$(QT_HOST_LIBS
) \
243 -hostdatadir
$(QT_HOST_DATA
) \
285 -no-optimized-qmake \
294 -no-reduce-relocations \
295 -no-use-gold-linker \
302 -xplatform linux-openwrt-g
++ \
305 -no-warnings-are-errors \
309 define Build
/InstallDev
311 $(STAGING_DIR
)/host
/mk
315 $(STAGING_DIR
)/host
/mk
/
317 $(call Build
/Install
/HostFiles
,$(1))
318 $(call Build
/Install
/Headers
,$(1))
319 $(call Build
/Install
/Libs
,$(1),*)
322 define Package
/qt5base-concurrent
/install
323 $(call Build
/Install
/Libs
,$(1),libQt5Concurrent
)
326 define Package
/qt5base-core
/install
327 $(call Build
/Install
/Libs
,$(1),libQt5Core
)
330 define Package
/qt5base-gui
/install
331 $(call Build
/Install
/Libs
,$(1),libQt5Gui
)
334 define Package
/qt5base-network
/install
335 $(call Build
/Install
/Libs
,$(1),libQt5Network
)
338 define Package
/qt5base-printSupport
/install
339 $(call Build
/Install
/Libs
,$(1),libQt5PrintSupport
)
342 define Package
/qt5base-sql
/install
343 $(call Build
/Install
/Libs
,$(1),libQt5Sql
)
346 define Package
/qt5base-test
/install
347 $(call Build
/Install
/Libs
,$(1),libQt5Test
)
350 define Package
/qt5base-widgets
/install
351 $(call Build
/Install
/Libs
,$(1),libQt5Widgets
)
354 define Package
/qt5base-xml
/install
355 $(call Build
/Install
/Libs
,$(1),libQt5Xml
)
358 define Package
/qt5base-plugin-bearer-generic
/install
359 $(call Build
/Install
/Plugins
,$(1),bearer
,libqgenericbearer
)
362 define Package
/qt5base-plugin-input-evdevkeyboard
/install
363 $(call Build
/Install
/Plugins
,$(1),generic
,libqevdevkeyboardplugin
)
366 define Package
/qt5base-plugin-input-evdevmouse
/install
367 $(call Build
/Install
/Plugins
,$(1),generic
,libqevdevmouseplugin
)
370 define Package
/qt5base-plugin-input-evdevtablet
/install
371 $(call Build
/Install
/Plugins
,$(1),generic
,libqevdevtabletplugin
)
374 define Package
/qt5base-plugin-input-evdevtouch
/install
375 $(call Build
/Install
/Plugins
,$(1),generic
,libqevdevtouchplugin
)
378 define Package
/qt5base-plugin-imageformats-gif
/install
379 $(call Build
/Install
/Plugins
,$(1),imageformats
,libqgif
)
382 define Package
/qt5base-plugin-imageformats-ico
/install
383 $(call Build
/Install
/Plugins
,$(1),imageformats
,libqico
)
386 define Package
/qt5base-plugin-imageformats-jpeg
/install
387 $(call Build
/Install
/Plugins
,$(1),imageformats
,libqjpeg
)
390 define Package
/qt5base-plugin-platforms-linuxfb
/install
391 $(call Build
/Install
/Plugins
,$(1),platforms
,libqlinuxfb
)
394 define Package
/qt5base-plugin-platforms-minimal
/install
395 $(call Build
/Install
/Plugins
,$(1),platforms
,libqminimal
)
398 define Package
/qt5base-plugin-platforms-offscreen
/install
399 $(call Build
/Install
/Plugins
,$(1),platforms
,libqoffscreen
)
402 define Package
/qt5base-plugin-sqldrivers
/install
403 $(call Build
/Install
/Plugins
,$(1),sqldrivers
,libqsqlite
)
406 define Package
/qt5base-examples
/install
407 $(call Build
/Install
/Examples
,$(1))
410 $(eval
$(call BuildPackage
,qt5base
))
411 $(eval
$(call BuildPackage
,qt5base-concurrent
))
412 $(eval
$(call BuildPackage
,qt5base-core
))
413 $(eval
$(call BuildPackage
,qt5base-gui
))
414 $(eval
$(call BuildPackage
,qt5base-network
))
415 $(eval
$(call BuildPackage
,qt5base-printSupport
))
416 $(eval
$(call BuildPackage
,qt5base-sql
))
417 $(eval
$(call BuildPackage
,qt5base-test
))
418 $(eval
$(call BuildPackage
,qt5base-widgets
))
419 $(eval
$(call BuildPackage
,qt5base-xml
))
420 $(eval
$(call BuildPackage
,qt5base-plugin-bearer-generic
))
421 $(eval
$(call BuildPackage
,qt5base-plugin-input-evdevkeyboard
))
422 $(eval
$(call BuildPackage
,qt5base-plugin-input-evdevmouse
))
423 $(eval
$(call BuildPackage
,qt5base-plugin-input-evdevtablet
))
424 $(eval
$(call BuildPackage
,qt5base-plugin-input-evdevtouch
))
425 $(eval
$(call BuildPackage
,qt5base-plugin-imageformats-gif
))
426 $(eval
$(call BuildPackage
,qt5base-plugin-imageformats-ico
))
427 $(eval
$(call BuildPackage
,qt5base-plugin-imageformats-jpeg
))
428 $(eval
$(call BuildPackage
,qt5base-plugin-platforms-linuxfb
))
429 $(eval
$(call BuildPackage
,qt5base-plugin-platforms-minimal
))
430 $(eval
$(call BuildPackage
,qt5base-plugin-platforms-offscreen
))
431 $(eval
$(call BuildPackage
,qt5base-plugin-sqldrivers-sqlite
))
432 $(eval
$(call BuildPackage
,qt5base-examples
))