title: cmake: setting how a specific file is compiled
body: <p>In my <a href="https://github.com/jll63/yomm2" rel="nofollow noreferrer">YOMM2 library</a>, I have a file called lab.cpp <a href="https://github.com/jll63/yomm2/blob/master/tests/CMakeLists.txt#L14" rel="nofollow noreferrer">(declared in the <code>CMakeLists.txt</code> here)</a>, to experiment with new features. Since the library uses complex macro techniques, I would like that specific file to be compiled in two steps:</p>
  <ol>
  <li>preprocess with -E, sending the output, filtered though clang-format, to an intermediate file</li>
  <li>compile the intermediate file, producing lab.cpp.o</li>
  </ol>
  <p>After quite a bit of googling, I cannot find how to do that. Even worse, while playing with <a href="https://cmake.org/cmake/help/v3.16/command/add_custom_command.html" rel="nofollow noreferrer">add_custom_command</a>, my cmake (v 3.16.3) does not recognize the <code>OUTPUT</code> parameter.</p>
  <p>Help please?</p>