qt: add enable for truetype font installation
authorDanomi Manchego <danomimanchego123@gmail.com>
Fri, 24 Mar 2017 04:51:38 +0000 (00:51 -0400)
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Sat, 25 Mar 2017 14:17:44 +0000 (15:17 +0100)
Currently, qt.mk installs DejaVu/Vera TrueType fonts when Qt is configured for
freetype support. However, some users may prefer to limit the installed fonts
to only Qt's prerendered fonts (micro, fixed, helvetica, etc.). Or, there may
be a preference to use seperately installed TrueType fonts. This commit adds
a switch to explicitly control the installation of the TrueType fonts, similar
to the existing prerendered font enables.

Signed-off-by: Danomi Manchego <danomimanchego123@gmail.com>
Reviewed-by: Peter Seiderer <ps.report@gmx.net>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
package/qt/Config.in
package/qt/qt.mk

index fa5235d6f4f9070dc6e91c72a48d583824c79466..a7617592a63dab0b88698e03fc5b241e7cddb2de 100644 (file)
@@ -185,6 +185,14 @@ endmenu
 
 menu "Fonts"
 
+config BR2_PACKAGE_QT_FONT_TRUETYPE
+       bool "dejavu/vera"
+       depends on BR2_PACKAGE_QT_QTFREETYPE || BR2_PACKAGE_QT_SYSTEMFREETYPE
+       default y
+
+comment "dejavu/vera fonts need freetype support"
+       depends on !BR2_PACKAGE_QT_QTFREETYPE && !BR2_PACKAGE_QT_SYSTEMFREETYPE
+
 config BR2_PACKAGE_QT_FONT_MICRO
        bool "micro"
        default y
index e82bdfe801f4d195b9bdc10d53105d2365aa97ef..1faab74dbdf4e76d00ea8fde4700418b87ea26c5 100644 (file)
@@ -689,7 +689,7 @@ QT_LICENSE_FILES += src/3rdparty/fonts/COPYRIGHT.Unifont
 endif
 endif # QT_FONTS
 
-ifeq ($(BR2_PACKAGE_QT_QTFREETYPE)$(BR2_PACKAGE_QT_SYSTEMFREETYPE),y)
+ifeq ($(BR2_PACKAGE_QT_FONT_TRUETYPE),y)
 define QT_INSTALL_TARGET_FONTS_TTF
        mkdir -p $(TARGET_DIR)/usr/lib/fonts
        cp -dpf $(STAGING_DIR)/usr/lib/fonts/*.ttf $(TARGET_DIR)/usr/lib/fonts