-----Original Message-----
From: CMake [mailto:[email protected]] On Behalf Of Bill Hoffman
Sent: Wednesday, September 16, 2015 2:00 PM
To: [email protected]
Subject: Re: [CMake] Parallel builds

        On 9/16/2015 1:47 PM, J Decker wrote:
        > I see yer right.
        > Details get foggy after years.
        > well that's something to add:)
        >
        All covered my blog.  :)

This part here is inaccurate, at least with the current CMake and Visual Studio:
    "To set the flag you will have to edit the CMake cache with the cmake-gui 
and add it to the CMAKE_CXX_FLAGS and the CMAKE_C_FLAGS."

This is all we do in the CMake file that we include in all our projects:
        add_compile_options(/MP$ENV{NUMBER_OF_PROCESSORS})

If you don't have a NUMBER_OF_PROCESSORS environment variable, you just get /MP.

The oversubscription part is still true, but I've never seen randomly bad 
object files.

-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake

Reply via email to