[CMake] Copying cmake generated files to another machine

Bill Hoffman bill.hoffman at kitware.com
Mon Dec 7 16:05:17 EST 2009


One more thing to keep in mind, is that CMake executables are heavily 
used by the Makefiles during build time. CMake is used to compute depend 
information.  CMake is used to keep the files makefiles up to date with 
the sources.   Even if you did not want to auto-rerun CMake when a 
CMakeLists.txt file changed, it is used for other things as well.  It is 
used to output in color and for cmake -E commands such as copy.  So, the 
generated makefiles are not really independent and the relative paths 
would not remove any of the other dependencies I just mentioned.

Even with the IDE based files if you are using install rules, then the 
CMake executable must be available on the machine doing the install. 
CMake is also used as the program to do the install commands.   So, 
CMake is really required for a variety of reasons.  However, the only 
requirement for CMake is a C++ compiler.  CMake itself bootstraps on any 
unix platform.  It can run from any directory (no root needed to 
install).  Binaries are provided for all major platforms as well. It is 
in the grand scheme of things a very small dependency.

-Bill


More information about the CMake mailing list