diff options
author | Brad King <brad.king@kitware.com> | 2014-09-05 18:02:58 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2014-09-05 18:02:58 (GMT) |
commit | 68d4280ac4cb692b908620884b0842b7a01debeb (patch) | |
tree | 151dcefe8a2c123a1b26962e3f3369e092a7ee03 /Source/cmGlobalVisualStudio7Generator.cxx | |
parent | ad2a4776aa34c84a069a9e4d83ea32174ac6e6ac (diff) | |
download | CMake-68d4280ac4cb692b908620884b0842b7a01debeb.zip CMake-68d4280ac4cb692b908620884b0842b7a01debeb.tar.gz CMake-68d4280ac4cb692b908620884b0842b7a01debeb.tar.bz2 |
VS: Refactor internal default platform name selection
Rename the 'PlatformName' member to 'DefaultPlatformName' and make
sure it is only read through a 'GetPlatformName()' call. This will
allow non-default names to be chosen later.
Diffstat (limited to 'Source/cmGlobalVisualStudio7Generator.cxx')
-rw-r--r-- | Source/cmGlobalVisualStudio7Generator.cxx | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/Source/cmGlobalVisualStudio7Generator.cxx b/Source/cmGlobalVisualStudio7Generator.cxx index e312ff1..cb82e54 100644 --- a/Source/cmGlobalVisualStudio7Generator.cxx +++ b/Source/cmGlobalVisualStudio7Generator.cxx @@ -27,11 +27,11 @@ cmGlobalVisualStudio7Generator::cmGlobalVisualStudio7Generator( if (platformName.empty()) { - this->PlatformName = "Win32"; + this->DefaultPlatformName = "Win32"; } else { - this->PlatformName = platformName; + this->DefaultPlatformName = platformName; } } @@ -260,14 +260,20 @@ cmLocalGenerator *cmGlobalVisualStudio7Generator::CreateLocalGenerator() } //---------------------------------------------------------------------------- +std::string const& cmGlobalVisualStudio7Generator::GetPlatformName() const +{ + return this->DefaultPlatformName; +} + +//---------------------------------------------------------------------------- bool cmGlobalVisualStudio7Generator::SetSystemName(std::string const& s, cmMakefile* mf) { - if(this->PlatformName == "x64") + if(this->GetPlatformName() == "x64") { mf->AddDefinition("CMAKE_FORCE_WIN64", "TRUE"); } - else if(this->PlatformName == "Itanium") + else if(this->GetPlatformName() == "Itanium") { mf->AddDefinition("CMAKE_FORCE_IA64", "TRUE"); } |