summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/GeneratorToolset
diff options
context:
space:
mode:
authorAlexander Boczar <alexboc@microsoft.com>2019-09-16 21:14:20 (GMT)
committerBrad King <brad.king@kitware.com>2019-10-15 17:28:45 (GMT)
commit548e9051a4f20657d04341107924171ea9d1bcb5 (patch)
tree4b7aba7800a6a193396aabf4ab4259029db9ec35 /Tests/RunCMake/GeneratorToolset
parent99e83d423500e11a8e85c2032e8c536bce175ed1 (diff)
downloadCMake-548e9051a4f20657d04341107924171ea9d1bcb5.zip
CMake-548e9051a4f20657d04341107924171ea9d1bcb5.tar.gz
CMake-548e9051a4f20657d04341107924171ea9d1bcb5.tar.bz2
VS: Add support to override VCTargetsPath through toolset
Fixes: #19708
Diffstat (limited to 'Tests/RunCMake/GeneratorToolset')
-rw-r--r--Tests/RunCMake/GeneratorToolset/RunCMakeTest.cmake2
-rw-r--r--Tests/RunCMake/GeneratorToolset/TestToolsetVCTargetsPathOnly-stdout.txt2
-rw-r--r--Tests/RunCMake/GeneratorToolset/TestToolsetVCTargetsPathOnly.cmake2
3 files changed, 6 insertions, 0 deletions
diff --git a/Tests/RunCMake/GeneratorToolset/RunCMakeTest.cmake b/Tests/RunCMake/GeneratorToolset/RunCMakeTest.cmake
index ae75561..bb22841 100644
--- a/Tests/RunCMake/GeneratorToolset/RunCMakeTest.cmake
+++ b/Tests/RunCMake/GeneratorToolset/RunCMakeTest.cmake
@@ -30,6 +30,8 @@ if("${RunCMake_GENERATOR}" MATCHES "Visual Studio 1[012456]")
set(RunCMake_GENERATOR_TOOLSET "Test Toolset,host=x64,host=x86")
run_cmake(BadToolsetHostArchTwice)
if("${RunCMake_GENERATOR}" MATCHES "Visual Studio 1[56]")
+ set(RunCMake_GENERATOR_TOOLSET "VCTargetsPath=Test Path")
+ run_cmake(TestToolsetVCTargetsPathOnly)
set(RunCMake_GENERATOR_TOOLSET "Test Toolset,version=Test Toolset Version")
run_cmake(TestToolsetVersionBoth)
set(RunCMake_GENERATOR_TOOLSET ",version=Test Toolset Version")
diff --git a/Tests/RunCMake/GeneratorToolset/TestToolsetVCTargetsPathOnly-stdout.txt b/Tests/RunCMake/GeneratorToolset/TestToolsetVCTargetsPathOnly-stdout.txt
new file mode 100644
index 0000000..c46373f
--- /dev/null
+++ b/Tests/RunCMake/GeneratorToolset/TestToolsetVCTargetsPathOnly-stdout.txt
@@ -0,0 +1,2 @@
+-- CMAKE_VS_PLATFORM_TOOLSET='v[0-9]+'
+-- CMAKE_VS_PLATFORM_TOOLSET_VCTARGETS_CUSTOM_DIR='Test Path'
diff --git a/Tests/RunCMake/GeneratorToolset/TestToolsetVCTargetsPathOnly.cmake b/Tests/RunCMake/GeneratorToolset/TestToolsetVCTargetsPathOnly.cmake
new file mode 100644
index 0000000..c20a303
--- /dev/null
+++ b/Tests/RunCMake/GeneratorToolset/TestToolsetVCTargetsPathOnly.cmake
@@ -0,0 +1,2 @@
+message(STATUS "CMAKE_VS_PLATFORM_TOOLSET='${CMAKE_VS_PLATFORM_TOOLSET}'")
+message(STATUS "CMAKE_VS_PLATFORM_TOOLSET_VCTARGETS_CUSTOM_DIR='${CMAKE_VS_PLATFORM_TOOLSET_VCTARGETS_CUSTOM_DIR}'")