| Summary: | Qt5: no fonts are installed | ||
|---|---|---|---|
| Product: | buildroot | Reporter: | syntheticpp |
| Component: | Other | Assignee: | unassigned |
| Status: | VERIFIED INVALID | ||
| Severity: | normal | CC: | abrodkin, buildroot |
| Priority: | P5 | ||
| Version: | 2014.02 | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Linux | ||
| Host: | Target: | ||
| Build: | |||
|
Description
syntheticpp
2014-02-01 00:46:31 UTC
Interesting. We do have some code that should install fonts to the target directory, when Qt has installed them to the staging directory. From qt5base.mk:
define QT5BASE_INSTALL_TARGET_FONTS
if [ -d $(STAGING_DIR)/usr/lib/fonts/ ] ; then \
mkdir -p $(TARGET_DIR)/usr/lib/fonts ; \
cp -dpfr $(STAGING_DIR)/usr/lib/fonts/* $(TARGET_DIR)/usr/lib/fonts ; \
fi
endef
So maybe the specific configuration you're using does not install fonts to the staging directory.
Can you post your Buildroot .config file?
Seems -fontconfig disables font installation:
$cat qtbase/mkspecs/features/qpa/genericunixfontdatabase.prf
CONFIG += qpa/basicunixfontdatabase
contains(QT_CONFIG, fontconfig) {
DEFINES += Q_FONTCONFIGDATABASE
LIBS += -lfontconfig
} else:!android {
fonts.path = $$[QT_INSTALL_LIBS]/fonts
fonts.files = $$QT_SOURCE_TREE/lib/fonts/*
INSTALLS += fonts
}
I also don't build freetype now, but have not tested if it's a requirement. Overall, it's more a question of documentation. Indeed with BR2_PACKAGE_QT5BASE_FONTCONFIG selected no fonts are installed in staging and essentially they won't get on target. Moreover even if one puts fonts in /usr/lib/fonts on target they won't appear in Qt5 apps. So I had to rebuild entire Qt5 after I disabled BR2_PACKAGE_QT5BASE_FONTCONFIG and fonts appeared in Qt apps. |