Hi<br><br>I have the following situation:<br><br>files: test.cpp test.h<br><br>I want to process the file test.cpp with a custom pre-processor which will generate, say, test.ii.cpp which will get compiled into libtest.a. test.cpp just includes test.h.<br>
<br>This is my CMakeLists.txt file:<br><br>cmake_minimum_required(VERSION 2.6)<br><br>add_custom_command (OUTPUT test.ii.cpp<br>  COMMAND preprocess test.cpp test.ii.cpp<br>  DEPENDS test.cpp<br>  COMMENT &quot;Creating test.ii.cpp&quot;<br>
  VERBATIM)<br><br>add_library (test test.ii.cpp)<br><br>All dandy, but when I modify test.h the preprocessing step is not run, but just the compile step for test.ii.cpp. How can I make it so, that when the header is modified the preprocessing and the compilation steps are both run?<br>
<br>Regards,<br>Nikolay<br><br><br><br>