[Bf-blender-cvs] [d860d23e1a9] master: make.bat: cache the vcredist directory.

Ray Molenkamp noreply at git.blender.org
Tue Jun 5 15:25:46 CEST 2018


Commit: d860d23e1a9c41ded126e54cae3c05ed9b869805
Author: Ray Molenkamp
Date:   Tue Jun 5 07:25:37 2018 -0600
Branches: master
https://developer.blender.org/rBd860d23e1a9c41ded126e54cae3c05ed9b869805

make.bat: cache the vcredist directory.

When run from make.bat the environment is setup correctly and the VCToolsRedistDir environment variable exists, on later invocations of cmake this may no longer be the case and a warning was emitted about the missing runtime. we can't rely on InstallRequiredSystemLibraries.cmake here since it uses the compiler version to figure out the correct location and it doesn't know how to deal with clang.

===================================================================

M	build_files/cmake/platform/platform_win32.cmake

===================================================================

diff --git a/build_files/cmake/platform/platform_win32.cmake b/build_files/cmake/platform/platform_win32.cmake
index 6e049c0048f..ec70f11ea22 100644
--- a/build_files/cmake/platform/platform_win32.cmake
+++ b/build_files/cmake/platform/platform_win32.cmake
@@ -31,7 +31,8 @@ endif()
 
 if(CMAKE_C_COMPILER_ID MATCHES "Clang")
 	set(MSVC_CLANG On)
-	set(MSVC_REDIST_DIR $ENV{VCToolsRedistDir})
+	set(VC_TOOLS_DIR $ENV{VCToolsRedistDir} CACHE STRING "Location of the msvc redistributables")
+	set(MSVC_REDIST_DIR ${VC_TOOLS_DIR})
 	if (DEFINED MSVC_REDIST_DIR)
 		file(TO_CMAKE_PATH ${MSVC_REDIST_DIR} MSVC_REDIST_DIR)
 	else()



More information about the Bf-blender-cvs mailing list