summaryrefslogtreecommitdiffstats
path: root/Source/cmExportFileGenerator.cxx
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2013-05-17 08:12:02 (GMT)
committerStephen Kelly <steveire@gmail.com>2013-05-18 08:00:48 (GMT)
commitb5d6f5dd5b894ea6dcd8f87e1925db5551f3ffc0 (patch)
tree59dd309a90bfd35c5117e6132ef6c7622fb7cdbf /Source/cmExportFileGenerator.cxx
parentedeabd18e6db5a52b2191ea9d3b09ee8bd090af6 (diff)
downloadCMake-b5d6f5dd5b894ea6dcd8f87e1925db5551f3ffc0.zip
CMake-b5d6f5dd5b894ea6dcd8f87e1925db5551f3ffc0.tar.gz
CMake-b5d6f5dd5b894ea6dcd8f87e1925db5551f3ffc0.tar.bz2
Add EXPORT_NAME property.
This allows for example, the buildsystem to use names like 'boost_any' instead of the overly generic 'any', and still be able to generate IMPORTED targets called 'boost::any'.
Diffstat (limited to 'Source/cmExportFileGenerator.cxx')
-rw-r--r--Source/cmExportFileGenerator.cxx12
1 files changed, 7 insertions, 5 deletions
diff --git a/Source/cmExportFileGenerator.cxx b/Source/cmExportFileGenerator.cxx
index 27ec56b..a6ccbd5 100644
--- a/Source/cmExportFileGenerator.cxx
+++ b/Source/cmExportFileGenerator.cxx
@@ -376,7 +376,7 @@ void cmExportFileGenerator::GenerateInterfaceProperties(cmTarget *target,
if (!properties.empty())
{
std::string targetName = this->Namespace;
- targetName += target->GetName();
+ targetName += target->GetExportName();
os << "set_target_properties(" << targetName << " PROPERTIES\n";
for(ImportPropertyMap::const_iterator pi = properties.begin();
pi != properties.end(); ++pi)
@@ -407,7 +407,7 @@ cmExportFileGenerator::AddTargetNamespace(std::string &input,
}
if(this->ExportedTargets.find(tgt) != this->ExportedTargets.end())
{
- input = this->Namespace + input;
+ input = this->Namespace + tgt->GetExportName();
}
else
{
@@ -772,7 +772,8 @@ cmExportFileGenerator
{
// Construct the imported target name.
std::string targetName = this->Namespace;
- targetName += target->GetName();
+
+ targetName += target->GetExportName();
// Create the imported target.
os << "# Create imported target " << targetName << "\n";
@@ -835,7 +836,8 @@ cmExportFileGenerator
{
// Construct the imported target name.
std::string targetName = this->Namespace;
- targetName += target->GetName();
+
+ targetName += target->GetExportName();
// Set the import properties.
os << "# Import target \"" << targetName << "\" for configuration \""
@@ -954,7 +956,7 @@ cmExportFileGenerator
{
// Construct the imported target name.
std::string targetName = this->Namespace;
- targetName += target->GetName();
+ targetName += target->GetExportName();
os << "list(APPEND _IMPORT_CHECK_TARGETS " << targetName << " )\n"
"list(APPEND _IMPORT_CHECK_FILES_FOR_" << targetName << " ";