summaryrefslogtreecommitdiffstats
path: root/Source/cmVisualStudio10TargetGenerator.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2018-08-31 18:50:20 (GMT)
committerKitware Robot <kwrobot@kitware.com>2018-08-31 18:50:27 (GMT)
commit5a02afd92012ed936b9637217f5106d1a6a570c5 (patch)
treee6742c8914378dbe48b5528cecba633e447fee0b /Source/cmVisualStudio10TargetGenerator.cxx
parent28979843d16e39ad28d9d62300071c011283f9bd (diff)
parente78a0c8e8a0b002a1e0e71672efcf96418c3a26d (diff)
downloadCMake-5a02afd92012ed936b9637217f5106d1a6a570c5.zip
CMake-5a02afd92012ed936b9637217f5106d1a6a570c5.tar.gz
CMake-5a02afd92012ed936b9637217f5106d1a6a570c5.tar.bz2
Merge topic 'vs-winrt-default'
e78a0c8e8a VS: Add option to tell generator that platfrom is WinRT by default Acked-by: Kitware Robot <kwrobot@kitware.com> Merge-request: !2315
Diffstat (limited to 'Source/cmVisualStudio10TargetGenerator.cxx')
-rw-r--r--Source/cmVisualStudio10TargetGenerator.cxx6
1 files changed, 4 insertions, 2 deletions
diff --git a/Source/cmVisualStudio10TargetGenerator.cxx b/Source/cmVisualStudio10TargetGenerator.cxx
index d9f1942..ea65e21 100644
--- a/Source/cmVisualStudio10TargetGenerator.cxx
+++ b/Source/cmVisualStudio10TargetGenerator.cxx
@@ -2571,8 +2571,10 @@ bool cmVisualStudio10TargetGenerator::ComputeClOptions(
}
if (this->MSTools) {
- // If we have the VS_WINRT_COMPONENT set then force Compile as WinRT.
- if (this->GeneratorTarget->GetPropertyAsBool("VS_WINRT_COMPONENT")) {
+ // If we have the VS_WINRT_COMPONENT or CMAKE_VS_WINRT_BY_DEFAULT
+ // set then force Compile as WinRT.
+ if (this->GeneratorTarget->GetPropertyAsBool("VS_WINRT_COMPONENT") ||
+ this->Makefile->IsOn("CMAKE_VS_WINRT_BY_DEFAULT")) {
clOptions.AddFlag("CompileAsWinRT", "true");
// For WinRT components, add the _WINRT_DLL define to produce a lib
if (this->GeneratorTarget->GetType() == cmStateEnums::SHARED_LIBRARY ||