[CMake] question on file dependencies

Bráulio Oliveira brauliobo at gmail.com
Sat May 5 08:41:47 EDT 2007


Hello all,

I'm having some problems on write code to handle .ts due to file
dependencies. So, I've made a small example of what I need to work. Here It
comes:

The three text files: a, b and c, all int the source directory. I write the
following code:

ADD_CUSTOM_COMMAND(OUTPUT a
                   COMMAND cat a
                  )
ADD_CUSTOM_COMMAND(OUTPUT b
                   COMMAND cat b
                  )
SET_SOURCE_FILES_PROPERTIES(b
                            PROPERTIES
                            OBJECT_DEPENDS a
                           )
SET_SOURCE_FILES_PROPERTIES(c
                            PROPERTIES
                            OBJECT_DEPENDS b
                           )
ADD_CUSTOM_COMMAND(OUTPUT c
                   COMMAND cat c
                  )

The I add an executable that depends on c. What I want is that the three
cat's are executed, because c depends on b and b on a. But this doesn't
work.
Any suggestions?

bráulio
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://public.kitware.com/pipermail/cmake/attachments/20070505/89281550/attachment.htm


More information about the CMake mailing list