summaryrefslogtreecommitdiffstats
path: root/Source/cmTarget.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2006-04-18 14:56:28 (GMT)
committerBrad King <brad.king@kitware.com>2006-04-18 14:56:28 (GMT)
commit392137b6d7e53ee6e7187b530522f772137bcd6c (patch)
tree050b5d259be2b90fb79d4a493b885c9aa324b404 /Source/cmTarget.cxx
parent0ec43f7abdae1631926ed8139222d61cb9eb036c (diff)
downloadCMake-392137b6d7e53ee6e7187b530522f772137bcd6c.zip
CMake-392137b6d7e53ee6e7187b530522f772137bcd6c.tar.gz
CMake-392137b6d7e53ee6e7187b530522f772137bcd6c.tar.bz2
ENH: Added <config>_OUTPUT_NAME target property to allow the output name to be set on a per-configuration basis.
Diffstat (limited to 'Source/cmTarget.cxx')
-rw-r--r--Source/cmTarget.cxx15
1 files changed, 13 insertions, 2 deletions
diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx
index 8290075..efa20f8 100644
--- a/Source/cmTarget.cxx
+++ b/Source/cmTarget.cxx
@@ -1199,9 +1199,20 @@ void cmTarget::GetFullNameInternal(TargetType type,
outPrefix = targetPrefix?targetPrefix:"";
// Append the target name or property-specified name.
- if(const char* outname = this->GetProperty("OUTPUT_NAME"))
+ const char* outName = 0;
+ if(config && *config)
+ {
+ std::string configProp = cmSystemTools::UpperCase(config);
+ configProp += "_OUTPUT_NAME";
+ outName = this->GetProperty(configProp.c_str());
+ }
+ if(!outName)
+ {
+ outName = this->GetProperty("OUTPUT_NAME");
+ }
+ if(outName)
{
- outBase = outname;
+ outBase = outName;
}
else
{