On Fri, Aug 5, 2016 at 11:59 AM, J Decker <[email protected]> wrote: > I'm using "MinGW Makefiles" as a generator... > > > When I change a cmakelists.txt file, a bunch of sources I specify to copy > from /.../.c to ${CMAKE_BINARY_DIR}/.../.cpp get deleted in binary by cmake. > > There are no rules in the makefiles for those files to depend on anything > other than the original .c file, so I was really confused why they kept > getting regenerated... I started to pay attention and found that cmake, > during configure, if a cmakeLists.txt changes goes through and deletes all > those files. > > > add_custom_command( OUTPUT ${CMAKE_BINARY_DIR}/${BASENAME}${FILEEXT} > DEPENDS ${SOURCE} > COMMAND ${CMAKE_COMMAND} -E > copy_if_different ${SOURCE} ${CMAKE_BINARY_DIR}/${BASENAME}${FILEEXT} > ) > > > all outputs get deleted? > The file is opened with CreateFile, then
SetDispositionInformationFile \Device\HarddiskVolume15\mingw64-x86\sack-r\release_solution\core\src\utils\deploy\CMakeFiles\sack_deploy.dir\DependInfo.cmake.tmp SUCCESS Delete: True so when the file is closed it's deleted... Seems to be set from __archive_mktemp(const char *tmpdir) passing FILE_FLAG_DELETE_ON_CLOSE; but my files aren't temporary.... that's the only thing that seems to set that flag.... --------- trying to make a simple case; but it's not doing it.
-- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/cmake
