Browse Source

CTest: Do not fail with submodules and Git < 1.6.5.0

Several major Linux distributions still do not provide Git >= 1.6.5.0 in
their stable package lists.  Prior to commit 1173cc4a (Update Git
submodules with --recursive, 2011-02-22) CTest was able to use older Git
versions but simply silently failed to update submodules recursively.
Instead of failing with older Git versions preserve the status quo and
add a warning in the update log.  Users testing projects with recursive
submodules may simply update to a Git new enough to support them.
Brad King 14 years ago
parent
commit
732af7fbba
1 changed files with 1 additions and 2 deletions
  1. 1 2
      Source/CTest/cmCTestGIT.cxx

+ 1 - 2
Source/CTest/cmCTestGIT.cxx

@@ -281,8 +281,7 @@ bool cmCTestGIT::UpdateImpl()
     // No need to require >= 1.6.5.0 if there are no submodules.
     if(cmSystemTools::FileExists((top_dir + "/.gitmodules").c_str()))
       {
-      this->Log << "Git >= 1.6.5.0 required for submodule support\n";
-      return false;
+      this->Log << "Git < 1.6.5.0 cannot update submodules recursively\n";
       }
     }