summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2013-09-17 13:42:13 (GMT)
committerBrad King <brad.king@kitware.com>2013-10-16 13:22:35 (GMT)
commitb336a1ebe48a964431734568d78256a4ebd5cdad (patch)
tree71a614aa07f11e53cde2f086003f4d69317aee3d /Source
parentec6df3675e78d370dbb924bbddf21d01f3ecb071 (diff)
downloadCMake-b336a1ebe48a964431734568d78256a4ebd5cdad.zip
CMake-b336a1ebe48a964431734568d78256a4ebd5cdad.tar.gz
CMake-b336a1ebe48a964431734568d78256a4ebd5cdad.tar.bz2
Teach COMPATIBLE_INTERFACE_* checks to use Help .rst documents
These checks want to know if named target properties are builtin, which is now known by checking the Help/prop_tgt directory. (Previously the check could be confused by a define_property call in the project.)
Diffstat (limited to 'Source')
-rw-r--r--Source/cmTarget.cxx9
1 files changed, 6 insertions, 3 deletions
diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx
index d03ed49..cf0cad5 100644
--- a/Source/cmTarget.cxx
+++ b/Source/cmTarget.cxx
@@ -6964,13 +6964,16 @@ void checkPropertyConsistency(cmTarget *depender, cmTarget *dependee,
std::vector<std::string> props;
cmSystemTools::ExpandListArgument(prop, props);
+ std::string pdir =
+ dependee->GetMakefile()->GetRequiredDefinition("CMAKE_ROOT");
+ pdir += "/Help/prop_tgt/";
for(std::vector<std::string>::iterator pi = props.begin();
pi != props.end(); ++pi)
{
- if (depender->GetMakefile()->GetCMakeInstance()
- ->IsPropertyDefined(pi->c_str(),
- cmProperty::TARGET))
+ std::string pname = cmSystemTools::HelpFileName(*pi);
+ std::string pfile = pdir + pname + ".rst";
+ if(cmSystemTools::FileExists(pfile.c_str(), true))
{
cmOStringStream e;
e << "Target \"" << dependee->GetName() << "\" has property \""