[CMake] Allow overriding MSVC_DIA_SDK_DIR via CMake
authorMartin Storsjo <martin@martin.st>
Tue, 22 Oct 2019 06:36:21 +0000 (06:36 +0000)
committerMartin Storsjo <martin@martin.st>
Tue, 22 Oct 2019 06:36:21 +0000 (06:36 +0000)
This eases using it in cross-msvc setups.

Differential Revision: https://reviews.llvm.org/D69239

llvm-svn: 375485

llvm/cmake/config-ix.cmake

index 4c585b8..028a2cc 100644 (file)
@@ -474,7 +474,8 @@ if( MSVC )
   set(strdup "_strdup")
 
   # See if the DIA SDK is available and usable.
-  set(MSVC_DIA_SDK_DIR "$ENV{VSINSTALLDIR}DIA SDK")
+  set(MSVC_DIA_SDK_DIR "$ENV{VSINSTALLDIR}DIA SDK" CACHE PATH
+      "Path to the DIA SDK")
 
   # Due to a bug in MSVC 2013's installation software, it is possible
   # for MSVC 2013 to write the DIA SDK into the Visual Studio 2012