I have a qt project containing parts in C++14
.
Recently, I changed my ubuntu distro. Now I have 16.04 LTS and I installed Qt creator 4.02 (built on jun 13).
In order to enable C++14
compilation, I put in the project file:
QMAKE_CXXFLAGS += -std=c++14
However, when building project, the IDE generates the following command:
g++ -c -pipe -std=c++14 -g -O0 -g -std=gnu++11 -Wall -W -D_REENTRANT ...
As seen, the generated makefile
puts the flag -std=gnu++11
which overrides the flag for C++14
. This did not happen with my previous distro (LTS 12.04, same qt creator version).
I tried with
CONFIG += -std=c++14
But the behavior is the same.
Could someone give any clue?