diff options
-rw-r--r-- | qmake/generators/win32/msvc_objectmodel.cpp | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/qmake/generators/win32/msvc_objectmodel.cpp b/qmake/generators/win32/msvc_objectmodel.cpp index ae237e7..af475d0 100644 --- a/qmake/generators/win32/msvc_objectmodel.cpp +++ b/qmake/generators/win32/msvc_objectmodel.cpp @@ -1080,11 +1080,20 @@ bool VCCLCompilerTool::parseOption(const char* option) } found = false; break; case 'o': - if (second == 'p' && third == 'e' && fourth == 'n') { - OpenMP = _True; - break; + { + const char *str = option + 2; + const size_t len = strlen(str); + if (len >= 5 && len <= 6 && strncmp(str, "penmp", 5) == 0) { + if (len == 5) { + OpenMP = _True; + break; + } else if (str[5] == '-') { + OpenMP = _False; + break; + } } found = false; break; + } case 's': if(second == 'h' && third == 'o' && fourth == 'w') { ShowIncludes = _True; |