2015-07-01 10:34 GMT+02:00 Honggyu Kim <hong.gyu....@lge.com>: > Hi all, > > I would like to see the exact command execution list when I build using > cmake. > Make has an option "--dry-run" as many of you already know: > > $ make --help > -n, --just-print, --dry-run, --recon > Don't actually run any commands; just print > them. > > Can anyone please let me know if there's a way to do dry-run in cmake. > I appreciate all your comments. >
There is one big noticeable difference between make and cmake. CMake does not "build" software it creates build system that will be used to build. So dry-running CMake will not give you "exact command execution for building". The other main difference is that CMake has control statements-(option, find_package, if-else, ...) so that action/command executed during CMake run may heavily depend on the **effective execution** (e.g. find_package) of a previous line of the CMake script. So I my idea is that "dry-run" is not as useful for CMake as it is for make (or ninja -n or other build tool dry run mode). What you already have with CMake is the --trace option which can be very useful to understand what happen at CMake time. Then it may also be useful to dry-run the resulting build files produced by CMake. i.e.: make --dry-run ninja -n -v ... -- Eric
-- 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-developers