Merge branch 'backport-fix-CMP0047-IS_GNU-vars' into release

This commit is contained in:
Brad King 2014-08-11 10:00:05 -04:00
commit 4988b17492
1 changed files with 8 additions and 0 deletions

View File

@ -804,6 +804,14 @@ void cmGlobalGenerator::CheckCompilerIdCompatibility(cmMakefile* mf,
case cmPolicies::OLD: case cmPolicies::OLD:
// OLD behavior is to convert QCC to GNU. // OLD behavior is to convert QCC to GNU.
mf->AddDefinition(compilerIdVar.c_str(), "GNU"); mf->AddDefinition(compilerIdVar.c_str(), "GNU");
if(lang == "C")
{
mf->AddDefinition("CMAKE_COMPILER_IS_GNUCC", "1");
}
else if(lang == "CXX")
{
mf->AddDefinition("CMAKE_COMPILER_IS_GNUCXX", "1");
}
break; break;
case cmPolicies::REQUIRED_IF_USED: case cmPolicies::REQUIRED_IF_USED:
case cmPolicies::REQUIRED_ALWAYS: case cmPolicies::REQUIRED_ALWAYS: