summaryrefslogtreecommitdiffstats
path: root/Source/cmFindPackageCommand.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2009-08-05 13:56:02 (GMT)
committerBrad King <brad.king@kitware.com>2009-08-05 13:56:02 (GMT)
commitbe24db77d072ada494481718bdd76a6066c73743 (patch)
tree642b912e63e26bbec028a5f233f54a464aeea338 /Source/cmFindPackageCommand.cxx
parentb592154bfd32c81f9ae1bebb49be7fa49759bbce (diff)
downloadCMake-be24db77d072ada494481718bdd76a6066c73743.zip
CMake-be24db77d072ada494481718bdd76a6066c73743.tar.gz
CMake-be24db77d072ada494481718bdd76a6066c73743.tar.bz2
Fix find_package for cmake-gui registry entry
The find_package commands looks at the "WhereBuild" registry entries created by CMakeSetup and cmake-gui hoping that the project was recently built. CMakeSetup created WhereBuild1..WhereBuild10 but cmake-gui creates WhereBuild0-WhereBuild9. This fixes find_package to look at WhereBuild0 so that the most recently configured project can be found. It is important in the case that the package to be found was the last one configured in cmake-gui but the current project that is finding it is configured from the command line.
Diffstat (limited to 'Source/cmFindPackageCommand.cxx')
-rw-r--r--Source/cmFindPackageCommand.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/Source/cmFindPackageCommand.cxx b/Source/cmFindPackageCommand.cxx
index 10d96a1..9bc1df0 100644
--- a/Source/cmFindPackageCommand.cxx
+++ b/Source/cmFindPackageCommand.cxx
@@ -1137,7 +1137,7 @@ void cmFindPackageCommand::AddPrefixesBuilds()
if(!this->NoBuilds && !this->NoDefaultPath)
{
// It is likely that CMake will have recently built the project.
- for(int i=1; i <= 10; ++i)
+ for(int i=0; i <= 10; ++i)
{
cmOStringStream r;
r <<