BUG: MSVC* variables should be set in IDE generators instead of just NMake.
This commit is contained in:
parent
fad3e1dd77
commit
bc135b7fc2
|
@ -32,6 +32,7 @@ void cmGlobalVisualStudio6Generator::EnableLanguage(std::vector<std::string>cons
|
|||
mf->AddDefinition("CMAKE_GENERATOR_RC", "rc");
|
||||
mf->AddDefinition("CMAKE_GENERATOR_NO_COMPILER_ENV", "1");
|
||||
mf->AddDefinition("CMAKE_GENERATOR_Fortran", "ifort");
|
||||
mf->AddDefinition("MSVC60", "1");
|
||||
this->GenerateConfigurations(mf);
|
||||
this->cmGlobalGenerator::EnableLanguage(lang, mf);
|
||||
}
|
||||
|
|
|
@ -39,7 +39,10 @@ cmLocalGenerator *cmGlobalVisualStudio71Generator::CreateLocalGenerator()
|
|||
return lg;
|
||||
}
|
||||
|
||||
|
||||
void cmGlobalVisualStudio71Generator::AddPlatformDefinitions(cmMakefile* mf)
|
||||
{
|
||||
mf->AddDefinition("MSVC71", "1");
|
||||
}
|
||||
|
||||
// Write a SLN file to the stream
|
||||
void cmGlobalVisualStudio71Generator::WriteSLNFile(std::ostream& fout,
|
||||
|
|
|
@ -44,6 +44,7 @@ public:
|
|||
virtual cmLocalGenerator *CreateLocalGenerator();
|
||||
|
||||
protected:
|
||||
virtual void AddPlatformDefinitions(cmMakefile* mf);
|
||||
virtual void WriteSLNFile(std::ostream& fout,
|
||||
cmLocalGenerator* root,
|
||||
std::vector<cmLocalGenerator*>& generators);
|
||||
|
|
|
@ -36,6 +36,8 @@ void cmGlobalVisualStudio7Generator::EnableLanguage(std::vector<std::string>cons
|
|||
mf->AddDefinition("CMAKE_GENERATOR_RC", "rc");
|
||||
mf->AddDefinition("CMAKE_GENERATOR_NO_COMPILER_ENV", "1");
|
||||
mf->AddDefinition("CMAKE_GENERATOR_Fortran", "ifort");
|
||||
|
||||
this->AddPlatformDefinitions(mf);
|
||||
|
||||
// Create list of configurations requested by user's cache, if any.
|
||||
this->cmGlobalGenerator::EnableLanguage(lang, mf);
|
||||
|
@ -58,6 +60,11 @@ void cmGlobalVisualStudio7Generator::EnableLanguage(std::vector<std::string>cons
|
|||
|
||||
}
|
||||
|
||||
void cmGlobalVisualStudio7Generator::AddPlatformDefinitions(cmMakefile* mf)
|
||||
{
|
||||
mf->AddDefinition("MSVC70", "1");
|
||||
}
|
||||
|
||||
std::string cmGlobalVisualStudio7Generator::GenerateBuildCommand(const char* makeProgram,
|
||||
const char *projectName, const char* additionalOptions, const char *targetName,
|
||||
const char* config, bool ignoreErrors)
|
||||
|
|
|
@ -107,6 +107,7 @@ protected:
|
|||
bool in_all);
|
||||
virtual void WriteSLNFooter(std::ostream& fout);
|
||||
virtual void WriteSLNHeader(std::ostream& fout);
|
||||
virtual void AddPlatformDefinitions(cmMakefile* mf);
|
||||
|
||||
void GenerateConfigurations(cmMakefile* mf);
|
||||
|
||||
|
|
|
@ -56,6 +56,12 @@ void cmGlobalVisualStudio8Generator::GetDocumentation(cmDocumentationEntry& entr
|
|||
entry.full = "";
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
void cmGlobalVisualStudio8Generator::AddPlatformDefinitions(cmMakefile* mf)
|
||||
{
|
||||
mf->AddDefinition("MSVC80", "1");
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
void cmGlobalVisualStudio8Generator::Configure()
|
||||
{
|
||||
|
|
|
@ -49,6 +49,7 @@ public:
|
|||
virtual void Configure();
|
||||
virtual void Generate();
|
||||
protected:
|
||||
virtual void AddPlatformDefinitions(cmMakefile* mf);
|
||||
virtual void WriteSLNFile(std::ostream& fout, cmLocalGenerator* root,
|
||||
std::vector<cmLocalGenerator*>& generators);
|
||||
virtual void WriteSLNHeader(std::ostream& fout);
|
||||
|
|
Loading…
Reference in New Issue