Ninja: Honor $<TARGET_OBJECTS:...> source expressions

Add objects from object libraries referenced using this syntax to the
set of objects linked in a target.
This commit is contained in:
Brad King 2012-03-15 08:56:40 -04:00
parent 23ec258fce
commit 51997cb6dc
1 changed files with 11 additions and 0 deletions

View File

@ -406,6 +406,17 @@ cmNinjaTargetGenerator
this->WriteObjectBuildStatement(*si);
}
{
// Add object library contents as external objects.
std::vector<std::string> objs;
this->GeneratorTarget->UseObjectLibraries(objs);
for(std::vector<std::string>::iterator oi = objs.begin();
oi != objs.end(); ++oi)
{
this->Objects.push_back(ConvertToNinjaPath(oi->c_str()));
}
}
this->GetBuildFileStream() << "\n";
}