From e339372ada34a142627d91a973fee2519962cf8f Mon Sep 17 00:00:00 2001 From: Lars Bilke <lars.bilke@ufz.de> Date: Sat, 7 Jan 2023 15:52:36 +0100 Subject: [PATCH] [cmake] Patch VTK only once. --- scripts/cmake/DependenciesExternalProject.cmake | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/cmake/DependenciesExternalProject.cmake b/scripts/cmake/DependenciesExternalProject.cmake index 9d3f4de6d25..e404b39089d 100644 --- a/scripts/cmake/DependenciesExternalProject.cmake +++ b/scripts/cmake/DependenciesExternalProject.cmake @@ -312,7 +312,8 @@ elseif(NOT OGS_BUILD_VTK AND NOT OGS_USE_MKL) endif() if(NOT VTK_FOUND) - if("${OGS_EXTERNAL_DEPENDENCIES_CACHE}" STREQUAL "") + if("${OGS_EXTERNAL_DEPENDENCIES_CACHE}" STREQUAL "" AND + NOT EXISTS "${PROJECT_BINARY_DIR}/_ext/VTK/src/VTK") # Fixes https://stackoverflow.com/questions/9894961 on vismac05: set(_loguru_patch PATCH_COMMAND git apply "${PROJECT_SOURCE_DIR}/scripts/cmake/loguru.patch" -- GitLab