From be24db77d072ada494481718bdd76a6066c73743 Mon Sep 17 00:00:00 2001 From: Brad King Date: Wed, 5 Aug 2009 09:56:02 -0400 Subject: 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. --- Source/cmFindPackageCommand.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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 << -- cgit v0.12