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

Enable c++1y in qt (mingw)



  • I'm trying ton enable @CONFIG += c++14@ in qmake (using mingw), but I always get -std=c++0x in the makefiles generated. the only workaround I found is to add in my .pro file QT_GCC_MAJOR_VERSION = 4 and QT_GCC_MINOR_VERSION = 9, then I get properly -std=c++1y.
    Those variables should be set automatically according to the compiler used, am I right ? What could make these variables not being set ?


  • Lifetime Qt Champion

    Hi and welcome to devnet,

    Which version of MinGW have you installed ? Which one is used by your Kit ?



  • Hi,
    I'm using the latest qtsdk, so this is mingw 4.9.1 with Qt 5.4.1
    I get the same behaviour in qt creator and in console


Log in to reply