Index: Source/cmFindPackageCommand.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmFindPackageCommand.cxx,v
retrieving revision 1.49
diff -u -r1.49 cmFindPackageCommand.cxx
--- Source/cmFindPackageCommand.cxx	8 Oct 2008 14:56:23 -0000	1.49
+++ Source/cmFindPackageCommand.cxx	8 Dec 2008 22:07:29 -0000
@@ -272,17 +272,21 @@
     "Path entries ending in \"/bin\" or \"/sbin\" are automatically "
     "converted to their parent directories.\n"
     "   PATH\n"
-    "5. Search project build trees recently configured in a CMake GUI.  "
+	"5. Typical instalation paths. For now this only applies to Windows "
+	"for the paths that match the following pattern (where <name> is " 
+    "case insensitive):\n"
+	"  ${ProgramFiles}/<name>*                                 (W)\n"
+    "6. Search project build trees recently configured in a CMake GUI.  "
     "This can be skipped if NO_CMAKE_BUILDS_PATH is passed.  "
     "It is intended for the case when a user is building multiple "
     "dependent projects one after another.\n"
-    "6. Search cmake variables defined in the Platform files "
+    "7. Search cmake variables defined in the Platform files "
     "for the current system.  This can be skipped if NO_CMAKE_SYSTEM_PATH "
     "is passed.\n"
     "   CMAKE_SYSTEM_PREFIX_PATH\n"
     "   CMAKE_SYSTEM_FRAMEWORK_PATH\n"
     "   CMAKE_SYSTEM_APPBUNDLE_PATH\n"
-    "7. Search paths specified by the PATHS option.  "
+    "8. Search paths specified by the PATHS option.  "
     "These are typically hard-coded guesses.\n"
     ;
   this->CommandDocumentation += this->GenericDocumentationMacPolicy;
@@ -1017,6 +1021,7 @@
   this->AddPrefixesCMakeEnvironment();
   this->AddPrefixesUserHints();
   this->AddPrefixesSystemEnvironment();
+  this->AddPrefixesTypicalInstallDirs();
   this->AddPrefixesBuilds();
   this->AddPrefixesCMakeSystemVariable();
   this->AddPrefixesUserGuess();
@@ -1084,6 +1089,39 @@
 }
 
 //----------------------------------------------------------------------------
+void cmFindPackageCommand::AddPrefixesTypicalInstallDirs()
+{
+    // Look for typical directories where the module may be installed:
+    //  ${ProgramFiles}/<NAME>*
+    std::string progfiles_path;
+    if(cmSystemTools::GetEnv("ProgramFiles", progfiles_path) && !progfiles_path.empty())
+	{
+       cmSystemTools::ConvertToUnixSlashes(progfiles_path);
+
+	   // Look for <progfiles_path>/<NAME>*
+	   std::string exp = progfiles_path;
+	   exp += std::string("/");
+	   exp += this->Name;
+	   exp += std::string("*");
+
+	   cmsys::Glob	glob;
+	   glob.SetRecurse(false);
+	   glob.FindFiles(exp);
+
+	   std::vector<std::string> lstPath = glob.GetFiles();
+
+	   for (std::vector<std::string>::iterator p=lstPath.begin();p!=lstPath.end();p++)
+	   {
+	       if(cmSystemTools::FileIsFullPath(p->c_str()) &&
+	          cmSystemTools::FileIsDirectory(p->c_str()))
+           {
+             this->AddPathInternal(*p, FullPath);
+           }
+	   }
+    }
+}
+
+//----------------------------------------------------------------------------
 void cmFindPackageCommand::AddPrefixesBuilds()
 {
   if(!this->NoBuilds && !this->NoDefaultPath)
Index: Source/cmFindPackageCommand.h
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmFindPackageCommand.h,v
retrieving revision 1.25
diff -u -r1.25 cmFindPackageCommand.h
--- Source/cmFindPackageCommand.h	10 Sep 2008 14:11:48 -0000	1.25
+++ Source/cmFindPackageCommand.h	8 Dec 2008 21:25:16 -0000
@@ -87,6 +87,7 @@
   void AddPrefixesCMakeEnvironment();
   void AddPrefixesCMakeVariable();
   void AddPrefixesSystemEnvironment();
+  void AddPrefixesTypicalInstallDirs();
   void AddPrefixesBuilds();
   void AddPrefixesCMakeSystemVariable();
   void AddPrefixesUserGuess();
