Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-23490

vcxproj setting /MP for VisualStudio 2010 doesn't work

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P2: Important
    • 4.8.1
    • 4.8.0
    • Build tools: qmake
    • None
    • Windows 7, Qt 4.8.0, Visual Studio 2010 prof.

    Description

      setting QMAKE_CFLAGS+=/MP in a project file didn't work for visual studio 2010

      order of Version-checking has to be changed in msvc_objectmodel.cpp

      here is a patch for this:

      patch msvc_objectmodel.cpp
      --- d:\qt\4.8.0.org\qmake\generators\win32\msvc_objectmodel.cpp	2011-12-08 07:06:02.000000000 +0100
      +++ d:\qt\4.8.0\qmake\generators\win32\msvc_objectmodel.cpp	2012-01-05 18:55:18.000000000 +0100
      @@ -646,17 +646,17 @@
               } else if(second == 'T') {
                   RuntimeLibrary = rtMultiThreaded;
                   if(third == 'd')
                       RuntimeLibrary = rtMultiThreadedDebug;
                   break;
               } else if (second == 'P') {
      -            if (config->CompilerVersion >= NET2005) {
      -                AdditionalOptions += option;
      -            } else if (config->CompilerVersion >= NET2010) {
      +            if (config->CompilerVersion >= NET2010) {
                       MultiProcessorCompilation = _True;
                       MultiProcessorCompilationProcessorCount = option+3;
      +            } else if (config->CompilerVersion >= NET2005) {
      +                AdditionalOptions += option;
                   } else {
                       warn_msg(WarnLogic, "/MP option is not supported in Visual C++ < 2005, ignoring.");
                   }
                   break;
               }
               found = false; break;
      

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            jbornema Joerg Bornemann
            gerd Gerhard Kokerbeck
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes