summaryrefslogtreecommitdiffstats
path: root/Source/cmTarget.cxx
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2013-04-29 09:54:19 (GMT)
committerBrad King <brad.king@kitware.com>2013-05-06 13:54:11 (GMT)
commitb8259c3d69258b884383559b74d37486b6a06ca2 (patch)
tree3a1a46fe6910927ad5a139ccabc11798a54b07d9 /Source/cmTarget.cxx
parent78185f598c152b1dbce632e953874ce8132c5fe9 (diff)
downloadCMake-b8259c3d69258b884383559b74d37486b6a06ca2.zip
CMake-b8259c3d69258b884383559b74d37486b6a06ca2.tar.gz
CMake-b8259c3d69258b884383559b74d37486b6a06ca2.tar.bz2
Centralize maintenance of usage requirement include directories
Maintain a target's internal list of usage requirement include directories whenever the LINK_LIBRARIES property is set by either target_link_libraries or set_property.
Diffstat (limited to 'Source/cmTarget.cxx')
-rw-r--r--Source/cmTarget.cxx23
1 files changed, 17 insertions, 6 deletions
diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx
index 66c22b1..186e203 100644
--- a/Source/cmTarget.cxx
+++ b/Source/cmTarget.cxx
@@ -2706,6 +2706,15 @@ void cmTarget::SetProperty(const char* prop, const char* value)
new cmTargetInternals::IncludeDirectoriesEntry(cge));
return;
}
+ if (strcmp(prop, "LINK_LIBRARIES") == 0)
+ {
+ this->Internal->LinkInterfaceIncludeDirectoriesEntries.clear();
+ cmListFileBacktrace lfbt;
+ this->Makefile->GetBacktrace(lfbt);
+ cmValueWithOrigin entry(value, lfbt);
+ this->Internal->LinkInterfaceIncludeDirectoriesEntries.push_back(entry);
+ // Fall through
+ }
this->Properties.SetProperty(prop, value, cmProperty::TARGET);
this->MaybeInvalidatePropertyCache(prop);
}
@@ -2727,6 +2736,14 @@ void cmTarget::AppendProperty(const char* prop, const char* value,
new cmTargetInternals::IncludeDirectoriesEntry(ge.Parse(value)));
return;
}
+ if (strcmp(prop, "LINK_LIBRARIES") == 0)
+ {
+ cmListFileBacktrace lfbt;
+ this->Makefile->GetBacktrace(lfbt);
+ cmValueWithOrigin entry(value, lfbt);
+ this->Internal->LinkInterfaceIncludeDirectoriesEntries.push_back(entry);
+ // Fall through
+ }
this->Properties.AppendProperty(prop, value, cmProperty::TARGET, asString);
this->MaybeInvalidatePropertyCache(prop);
}
@@ -2763,12 +2780,6 @@ void cmTarget::AppendBuildInterfaceIncludes()
}
//----------------------------------------------------------------------------
-void cmTarget::AppendTllInclude(const cmValueWithOrigin &entry)
-{
- this->Internal->LinkInterfaceIncludeDirectoriesEntries.push_back(entry);
-}
-
-//----------------------------------------------------------------------------
void cmTarget::InsertInclude(const cmValueWithOrigin &entry,
bool before)
{