From 712b4d935dad7cab52a482994b9e999cc3675d40 Mon Sep 17 00:00:00 2001 From: Erik Kundiman Date: Tue, 13 Aug 2024 22:51:01 +0800 Subject: Only download when there aren't the files yet --- indra/cmake/Meshoptimizer.cmake | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'indra/cmake/Meshoptimizer.cmake') diff --git a/indra/cmake/Meshoptimizer.cmake b/indra/cmake/Meshoptimizer.cmake index 62d5c558ac..a47c59c96b 100644 --- a/indra/cmake/Meshoptimizer.cmake +++ b/indra/cmake/Meshoptimizer.cmake @@ -18,10 +18,12 @@ endif (NOT USESYSTEMLIBS) if (${LINUX_DISTRO} MATCHES fedora OR DARWIN OR NOT USESYSTEMLIBS) if (USESYSTEMLIBS) if (${PREBUILD_TRACKING_DIR}/sentinel_installed IS_NEWER_THAN ${PREBUILD_TRACKING_DIR}/meshoptimizer_installed OR NOT ${meshoptimizer_installed} EQUAL 0) - file(DOWNLOAD - https://github.com/zeux/meshoptimizer/archive/refs/tags/v0.21.tar.gz - ${CMAKE_BINARY_DIR}/meshoptimizer-0.21.tar.gz - ) + if (NOT EXISTS ${CMAKE_BINARY_DIR}/meshoptimizer-0.21.tar.gz) + file(DOWNLOAD + https://github.com/zeux/meshoptimizer/archive/refs/tags/v0.21.tar.gz + ${CMAKE_BINARY_DIR}/meshoptimizer-0.21.tar.gz + ) + endif (NOT EXISTS ${CMAKE_BINARY_DIR}/meshoptimizer-0.21.tar.gz) file(ARCHIVE_EXTRACT INPUT ${CMAKE_BINARY_DIR}/meshoptimizer-0.21.tar.gz DESTINATION ${CMAKE_BINARY_DIR} -- cgit v1.2.3