From 46d0001bffdf5d8bc7eecc02c06debe9196ede53 Mon Sep 17 00:00:00 2001 From: Rye Cogtail Date: Tue, 1 Oct 2024 21:37:44 -0400 Subject: Cache MSVC redist path in cmake to avoid incorrect redist copy when project is regenerated by build/ide --- indra/cmake/Copy3rdPartyLibs.cmake | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'indra/cmake') diff --git a/indra/cmake/Copy3rdPartyLibs.cmake b/indra/cmake/Copy3rdPartyLibs.cmake index ced012426f..1e6dabd6c0 100644 --- a/indra/cmake/Copy3rdPartyLibs.cmake +++ b/indra/cmake/Copy3rdPartyLibs.cmake @@ -106,7 +106,8 @@ if(WINDOWS) else(ADDRESS_SIZE EQUAL 32) set(redist_find_path "$ENV{VCTOOLSREDISTDIR}x64\\Microsoft.VC${MSVC_TOOLSET_VER}.CRT") endif(ADDRESS_SIZE EQUAL 32) - get_filename_component(redist_path "${redist_find_path}" ABSOLUTE) + get_filename_component(redist_path_component "${redist_find_path}" ABSOLUTE) + set(redist_path ${redist_path_component} CACHE INTERNAL "MSVC Redist Path" FORCE) MESSAGE(STATUS "VC Runtime redist path: ${redist_path}") endif (MSVC_TOOLSET_VER AND DEFINED ENV{VCTOOLSREDISTDIR}) @@ -132,12 +133,11 @@ if(WINDOWS) msvcp${MSVC_VER}_2.dll msvcp${MSVC_VER}_atomic_wait.dll msvcp${MSVC_VER}_codecvt_ids.dll - msvcr${MSVC_VER}.dll vcruntime${MSVC_VER}.dll vcruntime${MSVC_VER}_1.dll vcruntime${MSVC_VER}_threads.dll ) - if(redist_path AND EXISTS "${redist_path}/${release_msvc_file}") + if(DEFINED redist_path AND EXISTS "${redist_path}/${release_msvc_file}") MESSAGE(STATUS "Copying redist file from ${redist_path}/${release_msvc_file}") to_staging_dirs( ${redist_path} -- cgit v1.2.3