diff options
Diffstat (limited to 'Source/cmGlobalNMakeMakefileGenerator.cxx')
-rw-r--r-- | Source/cmGlobalNMakeMakefileGenerator.cxx | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/Source/cmGlobalNMakeMakefileGenerator.cxx b/Source/cmGlobalNMakeMakefileGenerator.cxx index 114876f..318b428 100644 --- a/Source/cmGlobalNMakeMakefileGenerator.cxx +++ b/Source/cmGlobalNMakeMakefileGenerator.cxx @@ -24,9 +24,14 @@ void cmGlobalNMakeMakefileGenerator::EnableLanguage(const char* l, // pick a default mf->AddDefinition("CMAKE_GENERATOR_CC", "cl"); mf->AddDefinition("CMAKE_GENERATOR_CXX", "cl"); - std::string setMakeProgram = mf->GetDefinition("CMAKE_ROOT"); - setMakeProgram += "/Modules/CMakeNMakeFindMake.cmake"; - mf->ReadListFile(0, setMakeProgram.c_str()); + if(!mf->GetDefinition("CMAKE_MAKE_PROGRAM") + || cmSystemTools::IsOff(mf->GetDefinition("CMAKE_MAKE_PROGRAM"))) + { + std::string setMakeProgram = mf->GetDefinition("CMAKE_ROOT"); + setMakeProgram += "/Modules/CMakeNMakeFindMake.cmake"; + mf->ReadListFile(0, setMakeProgram.c_str()); + } + this->cmGlobalUnixMakefileGenerator::EnableLanguage(l, mf); } |