summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2014-03-15 08:18:39 (GMT)
committerBrad King <brad.king@kitware.com>2014-03-17 13:30:39 (GMT)
commitc903b5319bfcf383964c625bb84d7bc958aba2e9 (patch)
tree64f66ec7b80ef6ad831a0a5260ddf55ec7c7776b /Source
parent59d3898bc74c950a08b58b885867b7f0d18be8d5 (diff)
downloadCMake-c903b5319bfcf383964c625bb84d7bc958aba2e9.zip
CMake-c903b5319bfcf383964c625bb84d7bc958aba2e9.tar.gz
CMake-c903b5319bfcf383964c625bb84d7bc958aba2e9.tar.bz2
cmTarget: Restore <CONFIG>_LOCATION to CMP0026 OLD behavior (#14808)
Restore support for the undocumented <CONFIG>_LOCATION target property removed by commit v3.0.0-rc1~175^2 (cmTarget: Remove support for <CONFIG>_LOCATION property, 2013-12-30) as part of the CMP0026 OLD behavior.
Diffstat (limited to 'Source')
-rw-r--r--Source/cmTarget.cxx15
1 files changed, 15 insertions, 0 deletions
diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx
index 3fb79d8..0c89656 100644
--- a/Source/cmTarget.cxx
+++ b/Source/cmTarget.cxx
@@ -2730,6 +2730,21 @@ const char *cmTarget::GetProperty(const char* prop,
this->GetLocation(configName.c_str()),
cmProperty::TARGET);
}
+ // Support "<CONFIG>_LOCATION".
+ if(cmHasLiteralSuffix(prop, "_LOCATION"))
+ {
+ std::string configName(prop, strlen(prop) - 9);
+ if(configName != "IMPORTED")
+ {
+ if (!this->HandleLocationPropertyPolicy())
+ {
+ return 0;
+ }
+ this->Properties.SetProperty(prop,
+ this->GetLocation(configName.c_str()),
+ cmProperty::TARGET);
+ }
+ }
}
if(strcmp(prop,"INCLUDE_DIRECTORIES") == 0)
{