Static lib build & run gui app error : QFontDatabase: Cannot find font directory

  • Hi,

    I built qt to use static lib.
    I solved several problems and succeeded, but I can not show the font from qui.
    Fonts DIR does not seem to exist in qt.

    If I change QTDIR to shared lib, the font looks good.

    The following error appears.

    What is the problem?

    < env >
    OS: CentOS 6.8
    Qt: 5.7.1

    < error >
    ./configure -prefix /opt/qt5.7.1.a -static -qt-xcb -no-compile-examples -skip qtquickcontrols -skip qtquickcontrols2 -skip qtvirtualkeyboard -skip qtgamepad -skip qtscxml -skip qtcharts -skip qtsvg

    [root@localhost opt]# designer
    QFontDatabase: Cannot find font directory /opt/qt5.7.1.a/lib/fonts.
    Note that Qt no longer ships fonts. Deploy some (from for example) or switch to fontconfig.

Log in to reply