vendredi 26 janvier 2018

Disable C++11 in Qt Creator

How can I disable C++11/14 in Qt Creator?

I'd like compile my project as C++98/03 code. By default it run gcc like this:

g++ ... -std=gnu++11 -Wextra ... 

So I edited *.pro file so it contain:

...
CONFIG -= c++11
CONFIG += no-c++11 no-c++14
QMAKE_CXXFLAGS += -std=c++98 -pedantic
...

and compiler string has become:

g++ ... -std=c++98 -pedantic -g -std=gnu++11 ...

And it still compiling as C++11. How can I switch off C++11 support?

Compiler: mingw 5.3.0
Qt: 5.9.0 QtCreator: 4.4.1

Thanks for any help!

Aucun commentaire:

Enregistrer un commentaire