diff options
author | Brad King <brad.king@kitware.com> | 2014-07-28 20:15:43 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2014-07-31 18:08:46 (GMT) |
commit | d7938bff37bfa05f34b9ad5a46ae3aff54955eea (patch) | |
tree | 51259231e7382d59da58a9598d19ae705c1fc388 /Source/cmGlobalVisualStudio10Generator.cxx | |
parent | 3abd150ce9df03e24a903dedc952339b58ba79cb (diff) | |
download | CMake-d7938bff37bfa05f34b9ad5a46ae3aff54955eea.zip CMake-d7938bff37bfa05f34b9ad5a46ae3aff54955eea.tar.gz CMake-d7938bff37bfa05f34b9ad5a46ae3aff54955eea.tar.bz2 |
VS: Select WindowsPhone and WindowsStore default toolsets
Teach the VS >= 10 generators to recognize these system names and select
the appropriate default toolset for the system version. Report an error
when the version is not known to be supported by VS.
Inspired-by: Gilles Khouzam <gillesk@microsoft.com>
Diffstat (limited to 'Source/cmGlobalVisualStudio10Generator.cxx')
-rw-r--r-- | Source/cmGlobalVisualStudio10Generator.cxx | 28 |
1 files changed, 27 insertions, 1 deletions
diff --git a/Source/cmGlobalVisualStudio10Generator.cxx b/Source/cmGlobalVisualStudio10Generator.cxx index 5189569..c708a08 100644 --- a/Source/cmGlobalVisualStudio10Generator.cxx +++ b/Source/cmGlobalVisualStudio10Generator.cxx @@ -148,20 +148,46 @@ bool cmGlobalVisualStudio10Generator::SetSystemName(std::string const& s, } //---------------------------------------------------------------------------- -bool cmGlobalVisualStudio10Generator::InitializeSystem(cmMakefile*) +bool cmGlobalVisualStudio10Generator::InitializeSystem(cmMakefile* mf) { if(this->SystemName == "WindowsPhone") { this->SystemIsWindowsPhone = true; + if(!this->InitializeWindowsPhone(mf)) + { + return false; + } } else if(this->SystemName == "WindowsStore") { this->SystemIsWindowsStore = true; + if(!this->InitializeWindowsStore(mf)) + { + return false; + } } return true; } //---------------------------------------------------------------------------- +bool cmGlobalVisualStudio10Generator::InitializeWindowsPhone(cmMakefile* mf) +{ + cmOStringStream e; + e << this->GetName() << " does not support Windows Phone."; + mf->IssueMessage(cmake::FATAL_ERROR, e.str()); + return false; +} + +//---------------------------------------------------------------------------- +bool cmGlobalVisualStudio10Generator::InitializeWindowsStore(cmMakefile* mf) +{ + cmOStringStream e; + e << this->GetName() << " does not support Windows Store."; + mf->IssueMessage(cmake::FATAL_ERROR, e.str()); + return false; +} + +//---------------------------------------------------------------------------- void cmGlobalVisualStudio10Generator ::AddVSPlatformToolsetDefinition(cmMakefile* mf) const { |