[CMake] ADDITIONAL_MAKE_CLEAN_FILES for Visual Studio

James Bigler jamesbigler at gmail.com
Fri Oct 24 13:34:24 EDT 2008


Is there an analogous construct to ADDITIONAL_MAKE_CLEAN_FILES for Visual
Studio projects?  I poked around the CMake source tree and it seems to only
be referenced in the makefile generator.

As part of a custom target I create some intermediate files that need to
stick around, but I would like them removed when I clean the target.  If I
add the intermediate files as OUTPUT the files are cleaned by VS.  However
sometimes during the course of executing my command I may not generate one
of the intermediate files.  Because of this, VS thinks the build is not up
to date and reruns the rule.

In the extreme I can add a custom target to delete the files, but I was
wondering if there was a more elegant way.

BTW, can one add a custom_target to the "clean" target for both makefiles
and VS?

Thanks,
James
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20081024/48af5f8f/attachment.htm>


More information about the CMake mailing list