[CMake] ADD_CUSTOM_TARGET [ANY] ?

Peter Visser pervulgo at gmail.com
Wed Jan 10 15:10:48 EST 2007


Hi,

I would like to execute a command exactly one time during each build for
any, some or all targets, it this possible in an easy way?

I fiddled with the ADD_CUSTOM_TARGET and ADD_CUSTOM_COMMAND commands but was
unable to do so.
For instance when I used ADD_CUSTOM_TARGET(dummy ALL echo FOO), the 'dummy'
command is executed only when running "make all" and not when "make
target1". Setting dependencies for all targets results in multiple
invocations of the 'dummy' command (as intended).

Any help appreciated,

Peter.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://public.kitware.com/pipermail/cmake/attachments/20070110/d445208f/attachment.html


More information about the CMake mailing list