Include another MinGW compiler into Qt creator


  • Moderators

    I have just dowloaded and installed from https://sourceforge.net/projects/mingw-w64/?source=typ_redirect

    The installation has been performed plain without any other changes.

    c:\MinGW64\mingw-w64\i686-7.2.0-posix-dwarf-rt_v5-rev1\mingw32\bin>g++ --version
    g++ (i686-posix-dwarf-rev1, Built by MinGW-W64 project) 7.2.0
    

    Since I do not intend to compile Qt libs based on this compiler I have no qmake available yet.

    However, I like to use it for some tests through Qt creator for non-Qt projects.

    Does anybody know how to setup the compiler in Qt creator?


  • Qt Champions 2017

    @koahnig (Disclaimer: I have never done something like this).

    You will have to add the compiler to Tools -> Options -> Build&Run -> Compilers first.

    A blog post for CMake may help you: https://blog.afach.de/?p=659

    It should be possible to achive the same using Qbs and Makefile-based projects.

    If you want to use QMake, that you will have to build at least qmake (maybe qtbase) with this compiler. Afterwards you should be able to use this compiler in QMake-based (non-Qt) projects also.


  • Moderators

    @aha_1980

    Thanks for this link.

    I had started out already with adding the compiler, but struggled with the ABI choices. The blog does not give details about this too.

    All my experience in recent years is with using qmake for building projects in Qt creator. I am a bit hesitant to add another tool such as CMake if not absolutely required.


  • Qt Champions 2017

    @koahnig said in Include another MinGW compiler into Qt creator:

    All my experience in recent years is with using qmake for building projects in Qt creator. I am a bit hesitant to add another tool such as CMake if not absolutely required.

    Full ack from my side - even if qmake has disadvanteges, it most often does its job. So I think the way to go is to compile qtbase with this MinGW compiler or find a pre-compiled Qt version matching the compiler. As said, I cannot really help you here.


  • Moderators

    @aha_1980

    Thanks for your suggestions. I have decided to compile Qt with the new compiler just to include it to creator.
    Was quite easy and possibly less of struggle than trying to use CMake.


  • Qt Champions 2017

    @koahnig said in Include another MinGW compiler into Qt creator:

    @aha_1980

    Thanks for your suggestions. I have decided to compile Qt with the new compiler just to include it to creator.
    Was quite easy and possibly less of struggle than trying to use CMake.

    Cool!



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