summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2013-01-13 08:42:07 (GMT)
committerBrad King <brad.king@kitware.com>2013-01-15 19:36:21 (GMT)
commitf623d37a9558336af208a4fb5db232b28b56cb82 (patch)
tree536e24da24bfc6c412b3c254bf10dcfa99ca5904
parentb279f2b43180b6c55dd3361c2380f7ed3c998109 (diff)
downloadCMake-f623d37a9558336af208a4fb5db232b28b56cb82.zip
CMake-f623d37a9558336af208a4fb5db232b28b56cb82.tar.gz
CMake-f623d37a9558336af208a4fb5db232b28b56cb82.tar.bz2
Don't write a comment in the export file without the code.
-rw-r--r--Source/cmExportFileGenerator.cxx4
1 files changed, 4 insertions, 0 deletions
diff --git a/Source/cmExportFileGenerator.cxx b/Source/cmExportFileGenerator.cxx
index 94e24c7..91de200 100644
--- a/Source/cmExportFileGenerator.cxx
+++ b/Source/cmExportFileGenerator.cxx
@@ -665,6 +665,10 @@ cmExportFileGenerator
void cmExportFileGenerator::GenerateMissingTargetsCheckCode(std::ostream& os,
const std::vector<std::string>& missingTargets)
{
+ if (missingTargets.empty())
+ {
+ return;
+ }
os << "# Make sure the targets which have been exported in some other \n"
"# export set exist.\n";
for(unsigned int i=0; i<missingTargets.size(); ++i)