summaryrefslogtreecommitdiff
path: root/indra/cmake/Meshoptimizer.cmake
diff options
context:
space:
mode:
authorErik Kundiman <erik@megapahit.org>2024-08-13 22:51:01 +0800
committerErik Kundiman <erik@megapahit.org>2024-08-13 22:51:01 +0800
commit712b4d935dad7cab52a482994b9e999cc3675d40 (patch)
tree51c8706c85c15172be4b3474ef4f02d6c7bae17c /indra/cmake/Meshoptimizer.cmake
parent6ab3711d9bde07d40e8f3bf5a139ff54262d73d3 (diff)
Only download when there aren't the files yet
Diffstat (limited to 'indra/cmake/Meshoptimizer.cmake')
-rw-r--r--indra/cmake/Meshoptimizer.cmake10
1 files changed, 6 insertions, 4 deletions
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}