Explorar o código

also check path for test executables

Ken Martin %!s(int64=24) %!d(string=hai) anos
pai
achega
bd4c5cf362
Modificáronse 1 ficheiros con 10 adicións e 0 borrados
  1. 10 0
      Source/ctest.cxx

+ 10 - 0
Source/ctest.cxx

@@ -72,6 +72,16 @@ std::string ctest::FindExecutable(const char *exe)
     return fullPath;
     }
 
+  // if everything else failed, check the users path
+  if (dir != "")
+    {
+    std::string path = cmSystemTools::FindProgram(file.c_str());
+    if (path != "")
+      {
+      return path;
+      }
+    }
+  
   return fullPath;
 }