Re: [CMake] configuration based add_custom_command

2011-08-24 Thread David Cole
On Wed, Aug 24, 2011 at 10:39 AM, Robert Bielik wrote: > Michael Hertling skrev 2011-08-24 14:49: >> >> Anyway, I didn't want to discuss this particular detail; my >> point is: Configuration-selective custom commands possibly have >> far-reaching consequences which should be carefully reasoned out

Re: [CMake] configuration based add_custom_command

2011-08-24 Thread Robert Bielik
Michael Hertling skrev 2011-08-24 14:49: Anyway, I didn't want to discuss this particular detail; my point is: Configuration-selective custom commands possibly have far-reaching consequences which should be carefully reasoned out. I see your point. This would be a good thing to do, however, as

Re: [CMake] configuration based add_custom_command

2011-08-24 Thread Michael Hertling
On 08/24/2011 01:47 PM, Robert Bielik wrote: > Robert Bielik skrev 2011-08-24 13:43: >> Michael Hertling skrev 2011-08-24 13:13: >>> Suppose >>> >>> ADD_CUSTOM_COMMAND(OUTPUT source.c CONFIGURATION Release COMMAND ...) >>> ADD_EXECUTABLE(main ... source.c) >>> >>> and then: >>> >>> cmake -DCMAKE_BU

Re: [CMake] configuration based add_custom_command

2011-08-24 Thread David Cole
On Wed, Aug 24, 2011 at 7:47 AM, Robert Bielik wrote: > Robert Bielik skrev 2011-08-24 13:43: >> >> Michael Hertling skrev 2011-08-24 13:13: >>> >>> Suppose >>> >>> ADD_CUSTOM_COMMAND(OUTPUT source.c CONFIGURATION Release COMMAND ...) >>> ADD_EXECUTABLE(main ... source.c) >>> >>> and then: >>> >>>

Re: [CMake] configuration based add_custom_command

2011-08-24 Thread Robert Bielik
Robert Bielik skrev 2011-08-24 13:43: Michael Hertling skrev 2011-08-24 13:13: Suppose ADD_CUSTOM_COMMAND(OUTPUT source.c CONFIGURATION Release COMMAND ...) ADD_EXECUTABLE(main ... source.c) and then: cmake -DCMAKE_BUILD_TYPE=Debug How would you like this case to be handled by CMake? Note th

Re: [CMake] configuration based add_custom_command

2011-08-24 Thread Robert Bielik
Michael Hertling skrev 2011-08-24 13:13: Suppose ADD_CUSTOM_COMMAND(OUTPUT source.c CONFIGURATION Release COMMAND ...) ADD_EXECUTABLE(main ... source.c) and then: cmake -DCMAKE_BUILD_TYPE=Debug How would you like this case to be handled by CMake? Note that with multi-config generators, the bu

Re: [CMake] configuration based add_custom_command

2011-08-24 Thread Michael Hertling
On 08/24/2011 11:04 AM, Robert Bielik wrote: > Michael Wild skrev 2011-08-23 11:29: >> The easiest way around this I can see is to wrap the command in a >> CMake-script like this: >> >> add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/someFile.txt >>COMMAND ${CMAKE_COMMAND} >> -DCONFI

Re: [CMake] configuration based add_custom_command

2011-08-24 Thread Robert Bielik
Michael Wild skrev 2011-08-23 11:29: The easiest way around this I can see is to wrap the command in a CMake-script like this: add_custom_command(OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/someFile.txt COMMAND ${CMAKE_COMMAND} -DCONFIG=$ -DOUTPUT=${CMAKE_CURRENT_BINARY_DIR}/someFile.txt

Re: [CMake] configuration based add_custom_command

2011-08-23 Thread Michael Wild
On Tue 23 Aug 2011 11:21:07 AM CEST, Robert Bielik wrote: > I'm trying to setup a custom command to be executed during Release build > only (Xcode) using CMake 2.8.4, but I cannot find > any configuration based options to ADD_CUSTOM_COMMAND ? Workarounds ? > > TIA > /Rob The easiest way around th

[CMake] configuration based add_custom_command

2011-08-23 Thread Robert Bielik
I'm trying to setup a custom command to be executed during Release build only (Xcode) using CMake 2.8.4, but I cannot find any configuration based options to ADD_CUSTOM_COMMAND ? Workarounds ? TIA /Rob ___ Powered by www.kitware.com Visit other Kitwar