On 05/12/2013 07:32 PM, Robert Dailey wrote: > I'm currently working on adding a CONFIG keyword to the > add_custom_command() command.
The need for a CONFIG keyword was largely removed by support for generator expressions in custom commands. There is discussion and and old patch here: http://www.cmake.org/Bug/view.php?id=9974 There is also discussion of adding support in OUTPUT and DEPENDS for generator expressions: http://www.cmake.org/Bug/view.php?id=13840 With that one would almost never need the CONFIG keyword. > I'm not familiar with the code at all. > Right now I'm trying to figure out how CMake handles configurations > for Visual Studio. Are they handled only in the Generate() function? > Or does the configuration step also have knowledge of them? There are two kinds of generators: * Single configuration, determined by CMAKE_BUILD_TYPE at config time. All Makefile generators and Ninja work this way. * Multiple configuration, listed by CMAKE_CONFIGURATION_TYPES at config time but the final configuration is selected at build time by the native tool. The Xcode and VS generators work this way. Therefore CMake commands cannot know the build configuration, but generators do. The multi-config generators write out all the supported configs and typically loop over them. -Brad -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers
