file — CMake 3.23.0-rc3 Documentation
cmake.org › cmake › helpAn important difference is that configure_file () creates a dependency on the source file, so CMake will be re-run if it changes. The file (COPY_FILE) sub-command does not create such a dependency. See also the file (COPY) sub-command just below which provides further file-copying capabilities.
file — CMake 3.10.3 Documentation
https://cmake.org/cmake/help/v3.10/command/file.htmlWrite <content> into a file called <filename>.If the file does not exist, it will be created. If the file already exists, WRITE mode will overwrite it and APPEND mode will append to the end. Any directories in the path specified by <filename> that do not exist will be created.. If the file is a build input, use the configure_file() command to update the file only when its content changes.