summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2013-07-22 13:48:51 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2013-07-22 13:48:51 (GMT)
commitcb57ce249e9bfa43ef39eac482d5edb037f3ddc8 (patch)
tree2f327c81bba17668727238deb4ad988d1104957a
parent8521a909bad292ac8ccdf00b3b6cdd11ca8dc526 (diff)
parent4b1919f73e7663799285171b472d76053fb99166 (diff)
downloadCMake-cb57ce249e9bfa43ef39eac482d5edb037f3ddc8.zip
CMake-cb57ce249e9bfa43ef39eac482d5edb037f3ddc8.tar.gz
CMake-cb57ce249e9bfa43ef39eac482d5edb037f3ddc8.tar.bz2
Merge topic 'AddCommentsToExportsFile'
4b1919f ExportTargets: add one more comment to the generated file.
-rw-r--r--Source/cmExportFileGenerator.cxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/Source/cmExportFileGenerator.cxx b/Source/cmExportFileGenerator.cxx
index b4e6e81..90e6d51 100644
--- a/Source/cmExportFileGenerator.cxx
+++ b/Source/cmExportFileGenerator.cxx
@@ -792,7 +792,9 @@ void cmExportFileGenerator::GenerateImportVersionCode(std::ostream& os)
void cmExportFileGenerator::GenerateExpectedTargetsCode(std::ostream& os,
const std::string &expectedTargets)
{
- os << "set(_targetsDefined)\n"
+ os << "# Protect against multiple inclusion, which would fail when already "
+ "imported targets are added once more.\n"
+ "set(_targetsDefined)\n"
"set(_targetsNotDefined)\n"
"set(_expectedTargets)\n"
"foreach(_expectedTarget " << expectedTargets << ")\n"