[CMake] Action to perform unconditionally

Michael Hertling mhertling at online.de
Wed Feb 2 10:28:43 EST 2011


On 02/02/2011 03:50 PM, Ilja Golshtein wrote:
> 02.02.2011, 17:37, "Michael Hertling" <mhertling at online.de>:
>>>  Obviously I can choose arbitrary executable and link my target to it.
>>
>> Preferably, choose the targets which need the version.h header.
> 
> All executables (well ... but some tests) require version.h
> 
> Looks like the cleanest approach is to have all executables dependent on version.h

Yes, and this exactly reflects the actual situation: Your executables
need version.h, so their corresponding targets should depend on the
target which generates that header. Nevertheless, dependencies of
built-in targets would be quite convenient sometimes.

Regards,

Michael


More information about the CMake mailing list