CMake just generates the Makefiles. It does _not_ actually call make. That is up to you to do or some build script. If you are using a build script to actually fire off the build process then inside that script would be the appropriate place to add the -j flags.

HTH
_________________________________________________________
Mike Jackson                  [email protected]
BlueQuartz Software                    www.bluequartz.net
Principal Software Engineer                  Dayton, Ohio



On Dec 17, 2008, at 1:09 PM, Tyler Roscoe wrote:

Is there a way to set flags for make from my CMakeLists.txt?

Specifically, I have a cluster of build machines and I would like each
of them to use a specific -j flag. (I would set the -j flag in a
"global" cmake file where I set up things like project-wide -D flags and
third-party library locations.)

-j is a make option, not a compiler option, so I can't use
ADD_DEFINITIONS or CMAKE_CXX_FLAGS.

I couldn't find anything with google. This old thread talks about
$(MAKEFLAGS) but setting that variable doesn't seem to help me:

http://www.cmake.org/pipermail/cmake/2003-October/004398.html

Is this possible? Or do I need to make a wrapper script to set up extra
options for make?

Thanks,
tyler
_______________________________________________
CMake mailing list
[email protected]
http://www.cmake.org/mailman/listinfo/cmake

_______________________________________________
CMake mailing list
[email protected]
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to