diff options
author | Patrick Gansterer <paroga@paroga.com> | 2012-11-19 17:11:17 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2012-11-19 19:10:30 (GMT) |
commit | 8b62080c9db6a15649bd1673179076c096e26bec (patch) | |
tree | 29571bce3028f3a9ffb532ae69227bee57786858 | |
parent | 5bdf01184baa0301bd71f486b87d225f07cd80d0 (diff) | |
download | CMake-8b62080c9db6a15649bd1673179076c096e26bec.zip CMake-8b62080c9db6a15649bd1673179076c096e26bec.tar.gz CMake-8b62080c9db6a15649bd1673179076c096e26bec.tar.bz2 |
VS: Remove EnableLanguage from platform-specific generators
Move the logic into the base class to remove duplicated code.
-rw-r--r-- | Source/cmGlobalVisualStudio10Generator.cxx | 8 | ||||
-rw-r--r-- | Source/cmGlobalVisualStudio10IA64Generator.cxx | 13 | ||||
-rw-r--r-- | Source/cmGlobalVisualStudio10IA64Generator.h | 3 | ||||
-rw-r--r-- | Source/cmGlobalVisualStudio10Win64Generator.cxx | 13 | ||||
-rw-r--r-- | Source/cmGlobalVisualStudio10Win64Generator.h | 3 |
5 files changed, 8 insertions, 32 deletions
diff --git a/Source/cmGlobalVisualStudio10Generator.cxx b/Source/cmGlobalVisualStudio10Generator.cxx index b885223..db363bf 100644 --- a/Source/cmGlobalVisualStudio10Generator.cxx +++ b/Source/cmGlobalVisualStudio10Generator.cxx @@ -100,6 +100,14 @@ void cmGlobalVisualStudio10Generator ::EnableLanguage(std::vector<std::string>const & lang, cmMakefile *mf, bool optional) { + if(!strcmp(this->ArchitectureId, "Itanium") || + !strcmp(this->ArchitectureId, "x64")) + { + if(this->IsExpressEdition() && !this->Find64BitTools(mf)) + { + return; + } + } cmGlobalVisualStudio8Generator::EnableLanguage(lang, mf, optional); } diff --git a/Source/cmGlobalVisualStudio10IA64Generator.cxx b/Source/cmGlobalVisualStudio10IA64Generator.cxx index 9a03d1b..08a2e7a 100644 --- a/Source/cmGlobalVisualStudio10IA64Generator.cxx +++ b/Source/cmGlobalVisualStudio10IA64Generator.cxx @@ -28,16 +28,3 @@ void cmGlobalVisualStudio10IA64Generator entry.Brief = "Generates Visual Studio 10 Itanium project files."; entry.Full = ""; } - -//---------------------------------------------------------------------------- -void cmGlobalVisualStudio10IA64Generator -::EnableLanguage(std::vector<std::string> const& languages, - cmMakefile* mf, bool optional) -{ - if(this->IsExpressEdition() && !this->Find64BitTools(mf)) - { - return; - } - this->cmGlobalVisualStudio10Generator - ::EnableLanguage(languages, mf, optional); -} diff --git a/Source/cmGlobalVisualStudio10IA64Generator.h b/Source/cmGlobalVisualStudio10IA64Generator.h index 3c3325e..2bf7659 100644 --- a/Source/cmGlobalVisualStudio10IA64Generator.h +++ b/Source/cmGlobalVisualStudio10IA64Generator.h @@ -30,8 +30,5 @@ public: /** Get the documentation entry for this generator. */ static void GetDocumentation(cmDocumentationEntry& entry); - - virtual void EnableLanguage(std::vector<std::string>const& languages, - cmMakefile *, bool optional); }; #endif diff --git a/Source/cmGlobalVisualStudio10Win64Generator.cxx b/Source/cmGlobalVisualStudio10Win64Generator.cxx index 0352a46..93b5a64 100644 --- a/Source/cmGlobalVisualStudio10Win64Generator.cxx +++ b/Source/cmGlobalVisualStudio10Win64Generator.cxx @@ -28,16 +28,3 @@ void cmGlobalVisualStudio10Win64Generator entry.Brief = "Generates Visual Studio 10 Win64 project files."; entry.Full = ""; } - -//---------------------------------------------------------------------------- -void cmGlobalVisualStudio10Win64Generator -::EnableLanguage(std::vector<std::string> const& languages, - cmMakefile* mf, bool optional) -{ - if(this->IsExpressEdition() && !this->Find64BitTools(mf)) - { - return; - } - this->cmGlobalVisualStudio10Generator - ::EnableLanguage(languages, mf, optional); -} diff --git a/Source/cmGlobalVisualStudio10Win64Generator.h b/Source/cmGlobalVisualStudio10Win64Generator.h index 30b2164..59a34f4 100644 --- a/Source/cmGlobalVisualStudio10Win64Generator.h +++ b/Source/cmGlobalVisualStudio10Win64Generator.h @@ -30,8 +30,5 @@ public: /** Get the documentation entry for this generator. */ static void GetDocumentation(cmDocumentationEntry& entry); - - virtual void EnableLanguage(std::vector<std::string>const& languages, - cmMakefile *, bool optional); }; #endif |