summaryrefslogtreecommitdiffstats
path: root/Source/cmInstallProgramsCommand.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2006-08-31 14:47:00 (GMT)
committerBrad King <brad.king@kitware.com>2006-08-31 14:47:00 (GMT)
commit239fce5caa59daeaea830aa38e0cb576599221da (patch)
treeff4824f735b799f55f79da7ba394d54c77d32b88 /Source/cmInstallProgramsCommand.cxx
parent8ffb32369fedfbbd59631bbd9472c5fb1cd462f7 (diff)
downloadCMake-239fce5caa59daeaea830aa38e0cb576599221da.zip
CMake-239fce5caa59daeaea830aa38e0cb576599221da.tar.gz
CMake-239fce5caa59daeaea830aa38e0cb576599221da.tar.bz2
ENH: Do not generate install target unless some INSTALL or INSTALL_* commands have been used. This addresses bug#2827.
Diffstat (limited to 'Source/cmInstallProgramsCommand.cxx')
-rw-r--r--Source/cmInstallProgramsCommand.cxx4
1 files changed, 4 insertions, 0 deletions
diff --git a/Source/cmInstallProgramsCommand.cxx b/Source/cmInstallProgramsCommand.cxx
index 1830c5e..e38f0a6 100644
--- a/Source/cmInstallProgramsCommand.cxx
+++ b/Source/cmInstallProgramsCommand.cxx
@@ -26,6 +26,10 @@ bool cmInstallProgramsCommand
return false;
}
+ // Enable the install target.
+ this->Makefile->GetLocalGenerator()
+ ->GetGlobalGenerator()->EnableInstallTarget();
+
// Create an INSTALL_PROGRAMS target specifically for this path.
this->TargetName = "INSTALL_PROGRAMS_"+args[0];
cmTarget& target = this->Makefile->GetTargets()[this->TargetName];