summaryrefslogtreecommitdiffstats
path: root/Modules/ExternalProject.cmake
diff options
context:
space:
mode:
authorCraig Scott <craig.scott@crascit.com>2020-08-18 13:01:09 (GMT)
committerCraig Scott <craig.scott@crascit.com>2020-08-18 13:21:36 (GMT)
commitc0b7198ad9a4dea6473be0820ccbff27827e9f68 (patch)
tree90403bbda1616828c994d7bb271804b82ba0c7ef /Modules/ExternalProject.cmake
parentacd15bf146616517df7ac7f55f9c270657cad0d5 (diff)
downloadCMake-c0b7198ad9a4dea6473be0820ccbff27827e9f68.zip
CMake-c0b7198ad9a4dea6473be0820ccbff27827e9f68.tar.gz
CMake-c0b7198ad9a4dea6473be0820ccbff27827e9f68.tar.bz2
ExternalProject: Stop patch target from always appearing out-of-date
The skip-update target is always considered out-of-date. The change in 7249ba9677 (ExternalProject: Enforce that patch depends on update, 2020-04-03) made the patch target depend on skip-update, which in turn made it always out of date too. The patch command should only be re-run if the download needs to be performed again where updates are disconnected. Fixes: #21086
Diffstat (limited to 'Modules/ExternalProject.cmake')
-rw-r--r--Modules/ExternalProject.cmake6
1 files changed, 3 insertions, 3 deletions
diff --git a/Modules/ExternalProject.cmake b/Modules/ExternalProject.cmake
index aecc00b..85186ec 100644
--- a/Modules/ExternalProject.cmake
+++ b/Modules/ExternalProject.cmake
@@ -2801,9 +2801,9 @@ function(_ep_add_patch_command name)
_ep_get_update_disconnected(update_disconnected ${name})
if(update_disconnected)
- set(update_dep skip-update)
+ set(patch_dep download)
else()
- set(update_dep update)
+ set(patch_dep update)
endif()
set(__cmdQuoted)
@@ -2814,7 +2814,7 @@ function(_ep_add_patch_command name)
ExternalProject_Add_Step(${name} patch
COMMAND ${__cmdQuoted}
WORKING_DIRECTORY \${work_dir}
- DEPENDEES download \${update_dep}
+ DEPENDEES \${patch_dep}
${log}
)"
)