From 808d31ea3288ce42d9150a92fba3c4baa98b24df Mon Sep 17 00:00:00 2001 From: pappeste Date: Thu, 17 Jun 2021 12:44:49 -0700 Subject: [PATCH] change the lock to avoid the "IS_NEWER_THAN" check from failing in race conditions --- cmake/Platform/Common/runtime_dependencies_common.cmake.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmake/Platform/Common/runtime_dependencies_common.cmake.in b/cmake/Platform/Common/runtime_dependencies_common.cmake.in index 032a6726bd..c245d185d7 100644 --- a/cmake/Platform/Common/runtime_dependencies_common.cmake.in +++ b/cmake/Platform/Common/runtime_dependencies_common.cmake.in @@ -19,10 +19,10 @@ function(ly_copy source_file target_directory) file(MAKE_DIRECTORY "${target_directory}") endif() if("${source_file}" IS_NEWER_THAN "${target_directory}/${target_filename}") - file(LOCK "${CMAKE_BINARY_DIR}/runtimedependencies.lock" GUARD FUNCTION TIMEOUT 30) file(COPY "${source_file}" DESTINATION "${target_directory}" FILE_PERMISSIONS @LY_COPY_PERMISSIONS@ FOLLOW_SYMLINK_CHAIN) endif() endif() endfunction() +file(LOCK "${CMAKE_BINARY_DIR}/runtimedependencies.lock" TIMEOUT 300) @LY_COPY_COMMANDS@