[SOLVED]Qt Apps crash because of QFontDatabase: Cannot find font directory



  • After finishing static build of 5.0.2 all the built applications crashes and gives me this error message:
    @QFontDatabase: Cannot find font directory /usr/local/Qt-5.0.2/lib/fonts - is Qt installed correctly?
    Aborted (core dumped)@

    Static build parameters is:
    @./configure -static -v -qt-sql-psql -qt-sql-sqlite -plugin-sql-psql -plugin-sql-sqlite -qt-zlib -qt-libpng -qt-libjpeg -qt-pcre -qt-xcb@

    PS
    I'm using Mint KDE x64


  • Lifetime Qt Champion

    Do you have something in /usr/local/Qt-5.0.2/lib/fonts ?



  • [quote author="SGaist" date="1366110161"]Do you have something in /usr/local/Qt-5.0.2/lib/fonts ?[/quote]

    No. I installed Qt in my home directory at: /home/mbnoimi/Qt-5.0.2/


  • Lifetime Qt Champion

    Did you install Qt doing a make install ?

    I doubt so since you don't have a --prefix option. IIRC you have to use the -developer-build option to use Qt from where you compiled it



  • [quote author="SGaist" date="1366125881"]Did you install Qt doing a make install ?[/quote]

    I create static build from installed source code which shipped by Qt5.0.2 Linux installer. The steps I have done are:

    1. configure (with above parameters)
    2. make

    That's it

    [quote]I doubt so since you don't have a --prefix option. IIRC you have to use the -developer-build option to use Qt from where you compiled it[/quote]
    you mean that if I add -developer-build option the ./configure it will fix the issue?


  • Lifetime Qt Champion

    The source directory and the installation directory are two different things.

    You have the choice, either step 3:
    @make install@

    Which will install your Qt 5.0.2 in /usr/local/5.0.2

    Or rebuild with -developer-build which will give you a usable Qt in the build directory



  • It works.. thx


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.