I'm using qmake
and Visual Studio. In release build qmake adds /GL and /O2 flags to all projects, and I need to remove those two flags for certain libraries within my whole Qt project. Is there a way?
The only way this could work is
QMAKE_CFLAGS -= /GL /O2
but I doubt this works for QMAKE_CFLAGS
.
Alternatively, you could redefine QMAKE_CFLAGS
, forgetting its previous value:
QMAKE_CFLAGS = $$CFLAGS_WITHOUT_GL_O2