file(COPY) copying unchanged files
According to the documentation for file(COPY)
:
Copying preserves input file timestamps, and optimizes out a file if it exists at the destination with the same timestamp
However this is not the case. My host OS is Windows 10 and I'm using CMake 3.9.0-rc5. Each time my CMakeLists.txt is run, the file(COPY) is copying over the file even if it didn't change. The "date modified" timestamp for the destination file is updated. I do not want the copy to occur if the source file has not changed (this appears to be the intended behavior based on the documentation).
Also file(INSTALL)
does the same thing; the "Installing:" message gets printed each time for the same file, and never says that it is "up to date".