[CMake] Custom-Targets with unknown outputs

Clinton Stimpson clinton at elemtech.com
Thu May 15 01:21:19 EDT 2008


Christoph Cullmann wrote:
> Am Mittwoch 14 Mai 2008 16:57:22 schrieben Sie:
>   
>> Would it work to use ctest in a custom comand to build the generated
>> source files?
>> I'm thinking something similar to how the VTK Examples directory is
>> built as a separate project.
>>     
> Hmm, is it then possible that other targets depend on the result objects or 
> libs build by ctest? And how are flags passed over and all that?
>
>   
See attached CMakeLists.txt file (modified from VTK examples) that shows 
how to do that (dependencies, passing flags, etc..)
It would give you the chance to do a glob (or whatever you had in mind) 
at build time to gather up the source files to compile into a library.
It doesn't include your custom command for generating the sources.

Clint

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: CMakeLists.txt
URL: <http://www.cmake.org/pipermail/cmake/attachments/20080514/f633d270/attachment.txt>


More information about the CMake mailing list