INTERFACE_LIBRARY: Avoid codepaths which set unneeded properties.

As an INTERFACE_LIBRARY has no direct link dependencies, we can
short-circuit in cmGeneratorExpressionEvaluator and
in cmGlobalGenerator::CheckLocalGenerators.

As they do not generate any output directly, any generate- or install-
related code acn also be short-circuited. Many of the local generators
already do this.

Because only INTERFACE related properties make sense on INTERFACE_LIBRARY
targets, avoid setting other properties, for example via defaults.
This commit is contained in:
Stephen Kelly
2013-11-20 12:44:04 +01:00
parent 9f095b7416
commit 0bfcb450e6
14 changed files with 154 additions and 82 deletions
+2 -1
View File
@@ -151,7 +151,8 @@ void cmLocalUnixMakefileGenerator3::Generate()
for(cmGeneratorTargetsType::iterator t = targets.begin();
t != targets.end(); ++t)
{
if (t->second->Target->IsImported())
if (t->second->Target->GetType() == cmTarget::INTERFACE_LIBRARY
|| t->second->Target->IsImported())
{
continue;
}