From f8c259b443c95d2fce7f0ed7fd75e1acaf69b056 Mon Sep 17 00:00:00 2001
From: Bill Hoffman <bill.hoffman@kitware.com>
Date: Sat, 10 Sep 2005 10:33:10 -0400
Subject: BUG: try to fix qt problems

---
 Modules/FindQt.cmake     | 8 ++++++--
 Source/cmFileCommand.cxx | 6 ------
 bootstrap                | 1 +
 3 files changed, 7 insertions(+), 8 deletions(-)

diff --git a/Modules/FindQt.cmake b/Modules/FindQt.cmake
index 5b30cd0..5aab2d4 100644
--- a/Modules/FindQt.cmake
+++ b/Modules/FindQt.cmake
@@ -116,10 +116,14 @@ IF(DESIRED_QT_VERSION MATCHES 4)
 ENDIF(DESIRED_QT_VERSION MATCHES 4)
 
 IF(NOT QT3_INSTALLED AND NOT QT4_INSTALLED)
-  MESSAGE(SEND_ERROR "CMake was unable to find any QT versions, put qmake in your path, or set QT_QMAKE_EXECUTABLE.")
+  IF(QT_REQUIRED)
+    MESSAGE(SEND_ERROR "CMake was unable to find any QT versions, put qmake in your path, or set QT_QMAKE_EXECUTABLE.")
+  ENDIF(QT_REQUIRED)
 ELSE(NOT QT3_INSTALLED AND NOT QT4_INSTALLED)
   IF(NOT QT_FOUND AND NOT DESIRED_QT_VERSION)
-    MESSAGE(SEND_ERROR "Multiple versions of QT found please set DESIRED_QT_VERSION")
+    IF(QT_REQUIRED)
+      MESSAGE(SEND_ERROR "Multiple versions of QT found please set DESIRED_QT_VERSION")
+    ENDIF(QT_REQUIRED)
   ENDIF(NOT QT_FOUND AND NOT DESIRED_QT_VERSION)
   IF(NOT QT_FOUND AND DESIRED_QT_VERSION)
     MESSAGE(SEND_ERROR "CMake was unable to find QT version: ${DESIRED_QT_VERSION}. Set advanced values QT_QMAKE_EXECUTABLE and QT${DESIRED_QT_VERSION}_QGLOBAL_FILE.")
diff --git a/Source/cmFileCommand.cxx b/Source/cmFileCommand.cxx
index 46e2945..8b9daa2 100644
--- a/Source/cmFileCommand.cxx
+++ b/Source/cmFileCommand.cxx
@@ -182,7 +182,6 @@ bool cmFileCommand::HandleGlobCommand(std::vector<std::string> const& args,
     return false;
     }
 
-#ifdef CMAKE_BUILD_WITH_CMAKE
   std::vector<std::string>::const_iterator i = args.begin();
 
   i++; // Get rid of subcommand
@@ -227,11 +226,6 @@ bool cmFileCommand::HandleGlobCommand(std::vector<std::string> const& args,
     }
   m_Makefile->AddDefinition(variable.c_str(), output.c_str());
   return true;
-#else
-  (void)recurse;
-  this->SetError("GLOB is not implemented in the bootstrap CMake");
-  return false;
-#endif
 }
 
 //----------------------------------------------------------------------------
diff --git a/bootstrap b/bootstrap
index 3d398ec..7e912ff 100755
--- a/bootstrap
+++ b/bootstrap
@@ -45,6 +45,7 @@ CMAKE_CXX_SOURCES="\
   cmMakefile \
   cmGeneratedFileStream \
   cmGlobalGenerator \
+  cmGlob \
   cmLocalGenerator \
   cmSourceFile \
   cmSystemTools \
-- 
cgit v0.12