travis_cpp_tutorial icon indicating copy to clipboard operation
travis_cpp_tutorial copied to clipboard

Disable the compiler optimiser for qmake examples

Open pento opened this issue 8 years ago • 1 comments

qmake defaults to adding -O2 when compiling, which can cause gcov to miss that some lines were optimised out.

I fixed this by adding this setting to my .pro file:

QMAKE_CXXFLAGS_RELEASE -= -O2

pento avatar Aug 30 '17 01:08 pento

Thanks for sharing, this is great. I'll try to gradually ad this to my projects. Also your Pull Requests are welcomed :-)

richelbilderbeek avatar Oct 13 '17 07:10 richelbilderbeek