diff options
author | Brad King <brad.king@kitware.com> | 2007-11-19 19:22:38 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2007-11-19 19:22:38 (GMT) |
commit | 678bccc64bf2104def5de610fb14447439fb4704 (patch) | |
tree | f5016c73c53f71f76083efe4f7571c060163d514 /Source/cmake.cxx | |
parent | 0fcf3651378b69f1f549b77ba647d26a515f359d (diff) | |
download | CMake-678bccc64bf2104def5de610fb14447439fb4704.zip CMake-678bccc64bf2104def5de610fb14447439fb4704.tar.gz CMake-678bccc64bf2104def5de610fb14447439fb4704.tar.bz2 |
COMP: Do not build VS-specific code when generators are not included.
Diffstat (limited to 'Source/cmake.cxx')
-rw-r--r-- | Source/cmake.cxx | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Source/cmake.cxx b/Source/cmake.cxx index e85b94a..f14bb56 100644 --- a/Source/cmake.cxx +++ b/Source/cmake.cxx @@ -68,6 +68,7 @@ # include "cmGlobalBorlandMakefileGenerator.h" # include "cmGlobalNMakeMakefileGenerator.h" # include "cmGlobalWatcomWMakeGenerator.h" +# define CMAKE_HAVE_VS_GENERATORS # endif # include "cmGlobalMSYSMakefileGenerator.h" # include "cmGlobalMinGWMakefileGenerator.h" @@ -530,10 +531,12 @@ void cmake::SetArgs(const std::vector<std::string>& args) { this->CheckStampFile = args[++i]; } +#if defined(CMAKE_HAVE_VS_GENERATORS) else if((i < args.size()-1) && (arg.find("--vs-solution-file",0) == 0)) { this->VSSolutionFile = args[++i]; } +#endif else if(arg.find("-V",0) == 0) { this->Verbose = true; @@ -2103,6 +2106,7 @@ int cmake::Run(const std::vector<std::string>& args, bool noconfigure) int ret = this->Configure(); if (ret || this->ScriptMode) { +#if defined(CMAKE_HAVE_VS_GENERATORS) if(!this->VSSolutionFile.empty() && this->GlobalGenerator) { // CMake is running to regenerate a Visual Studio build tree @@ -2117,6 +2121,7 @@ int cmake::Run(const std::vector<std::string>& args, bool noconfigure) gg->CallVisualStudioMacro(cmGlobalVisualStudioGenerator::MacroStop, this->VSSolutionFile.c_str()); } +#endif return ret; } ret = this->Generate(); |