mirror of
https://github.com/reactos/CMake.git
synced 2024-11-24 20:19:53 +00:00
Merge topic 'INTERFACE-no-sources'
9db9c1fc
cmTarget: Don't try to get sources of an INTERFACE_LIBRARY.
This commit is contained in:
commit
10623032c7
@ -498,11 +498,14 @@ cmTargetTraceDependencies
|
||||
|
||||
// Queue all the source files already specified for the target.
|
||||
std::vector<cmSourceFile*> sources;
|
||||
this->Target->GetSourceFiles(sources);
|
||||
for(std::vector<cmSourceFile*>::const_iterator si = sources.begin();
|
||||
si != sources.end(); ++si)
|
||||
if (this->Target->GetType() != cmTarget::INTERFACE_LIBRARY)
|
||||
{
|
||||
this->QueueSource(*si);
|
||||
this->Target->GetSourceFiles(sources);
|
||||
for(std::vector<cmSourceFile*>::const_iterator si = sources.begin();
|
||||
si != sources.end(); ++si)
|
||||
{
|
||||
this->QueueSource(*si);
|
||||
}
|
||||
}
|
||||
|
||||
// Queue pre-build, pre-link, and post-build rule dependencies.
|
||||
|
@ -1468,7 +1468,8 @@ void cmGlobalGenerator::ComputeGeneratorTargetObjects()
|
||||
for(cmGeneratorTargetsType::iterator ti = targets.begin();
|
||||
ti != targets.end(); ++ti)
|
||||
{
|
||||
if (ti->second->Target->IsImported())
|
||||
if (ti->second->Target->IsImported()
|
||||
|| ti->second->Target->GetType() == cmTarget::INTERFACE_LIBRARY)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
@ -551,6 +551,7 @@ bool cmTarget::FindSourceFiles()
|
||||
//----------------------------------------------------------------------------
|
||||
void cmTarget::GetSourceFiles(std::vector<cmSourceFile*> &files) const
|
||||
{
|
||||
assert(this->GetType() != INTERFACE_LIBRARY);
|
||||
files = this->SourceFiles;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user