Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Build Qt Creator 3.6 on newer distros



  • Hello.
    I'm having a long problem with Qt Creator 4+, that fails to autocomplete properly.
    https://forum.qt.io/topic/90166/qt-creator-autocomplete-fails-to-work-with-ui/7
    TL;DR:

    • With CLang code model enabled, Qt additions, like SIGNAL() and SLOT() macro don't work, as well as some other things like redefining function from parent class in child class.
    • With CLang code model disabled, all Qt additions work as required, but autocompletion fails to work with ui classes (something like ui->pushButton fails to autocomplete further).

    I'm using Arch Linux, so older version of Qt Creator is not available to me, I have to build it from the source.
    I was able to find Qt Creator source and build it on my system:

    $ uname -a
    Linux Terraniux 4.20.12-arch1-1-ARCH #1 SMP PREEMPT Sat Feb 23 15:11:34 UTC 2019 x86_64 GNU/Linux
    $ qmake --version
    QMake version 3.1
    Using Qt version 5.12.1 in /usr/lib
    

    ... usind guide from this link:
    https://wiki.qt.io/Building_Qt_Creator_from_Git

    I've also deleted all configuration files from newer version of Qt Creator, using this guide:
    https://doc.qt.io/qtcreator/creator-quick-tour.html#location-of-settings-files

    Still, Qt Creator 3.6 is able to start without installation, but if I try to open settings or a project, everything crashes. This is what I see in the console output:

    $ ./bin/qtcreator
    MimeDatabase: Error loading :/qt-project.org/qmime/freedesktop.org.xml
    Cannot open :/qt-project.org/qmime/freedesktop.org.xml: No such file or directory
    Ошибка сегментирования (стек памяти сброшен на диск)
    

    The first 2 messages appear at the start of the application.
    What should I do to run Qt Creator 3.6 on newer systems?
    How to find what this segmentation fault is caused by?


Log in to reply