Skip to content
Permalink
Browse files

compiler.pri: disable warnings-as-errors when MSVC static analysis is…

… enabled.
  • Loading branch information...
mkrautz committed Dec 28, 2015
1 parent bb5ea5c commit 9652f7fff1e8634ef7c603a723d15c180347bc3c
Showing with 12 additions and 6 deletions.
  1. +12 −6 compiler.pri
@@ -45,6 +45,18 @@ win32 {
error("The INCLUDE environment variable is not set. Are you not in a build environment?")
}

CONFIG(analyze) {
QMAKE_CFLAGS_DEBUG *= /analyze
QMAKE_CXXFLAGS_DEBUG *= /analyze
QMAKE_CFLAGS_RELEASE *= /analyze
QMAKE_CXXFLAGS_RELEASE *= /analyze

# Do not treat warnings as errors when
# running the static analyzer.
# Otherwise, we won't get very far!
CONFIG *= no-warnings-as-errors
}

!CONFIG(no-warnings-as-errors) {
QMAKE_CFLAGS *= -WX
QMAKE_CXXFLAGS *= -WX
@@ -104,12 +116,6 @@ win32 {
QMAKE_LFLAGS_WINDOWS += /SUBSYSTEM:WINDOWS,6.00
}

CONFIG(analyze) {
QMAKE_CFLAGS_DEBUG *= /analyze
QMAKE_CXXFLAGS_DEBUG *= /analyze
QMAKE_CFLAGS_RELEASE *= /analyze
QMAKE_CXXFLAGS_RELEASE *= /analyze
}
DEFINES *= RESTRICT=
CONFIG(sse2) {
QMAKE_CFLAGS_RELEASE -= -arch:SSE

0 comments on commit 9652f7f

Please sign in to comment.
You can’t perform that action at this time.