diff options
author | Wouter Klouwen <wouter.klouwen@youview.com> | 2018-10-26 11:44:14 (GMT) |
---|---|---|
committer | Wouter Klouwen <wouter.klouwen@youview.com> | 2018-10-26 15:50:23 (GMT) |
commit | a4e9391953b9906b085cbc1c6d6909d049e540dd (patch) | |
tree | c17503918db6650fa2987901a8866d67b6ac552d /Modules/ExternalProject.cmake | |
parent | 2a8c05ddc792c4a0fea82764cdc32204c6d50885 (diff) | |
download | CMake-a4e9391953b9906b085cbc1c6d6909d049e540dd.zip CMake-a4e9391953b9906b085cbc1c6d6909d049e540dd.tar.gz CMake-a4e9391953b9906b085cbc1c6d6909d049e540dd.tar.bz2 |
ExternalProject: add LOG_PATCH option to log the patch command
Most steps support the logging into a file but the patch command is a
notable exception. This commit adds the LOG_PATCH options that acts as
the other LOG_* options.
Diffstat (limited to 'Modules/ExternalProject.cmake')
-rw-r--r-- | Modules/ExternalProject.cmake | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/Modules/ExternalProject.cmake b/Modules/ExternalProject.cmake index a8c31ed..93cd74a 100644 --- a/Modules/ExternalProject.cmake +++ b/Modules/ExternalProject.cmake @@ -532,6 +532,9 @@ External Project Definition ``LOG_UPDATE <bool>`` When enabled, the output of the update step is logged to files. + ``LOG_PATCH <bool>`` + When enabled, the output of the patch step is logged to files. + ``LOG_CONFIGURE <bool>`` When enabled, the output of the configure step is logged to files. @@ -2760,10 +2763,18 @@ function(_ep_add_patch_command name) set(work_dir ${source_dir}) endif() + get_property(log TARGET ${name} PROPERTY _EP_LOG_PATCH) + if(log) + set(log LOG 1) + else() + set(log "") + endif() + ExternalProject_Add_Step(${name} patch COMMAND ${cmd} WORKING_DIRECTORY ${work_dir} DEPENDEES download + ${log} ) endfunction() |