[Cmake-commits] CMake branch, next, updated. v3.2.0-rc2-717-g0d9f208

Brad King brad.king at kitware.com
Tue Feb 24 16:45:18 EST 2015


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".

The branch, next has been updated
       via  0d9f208ce393702510ba29b3193f760a5cf71b63 (commit)
       via  f4bf45211ee4fa6e869a6953b4b7b87e7731ce4c (commit)
      from  d81a19c7edb2dffa9f4bdbdeadacc8cce16522b2 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=0d9f208ce393702510ba29b3193f760a5cf71b63
commit 0d9f208ce393702510ba29b3193f760a5cf71b63
Merge: d81a19c f4bf452
Author:     Brad King <brad.king at kitware.com>
AuthorDate: Tue Feb 24 16:45:17 2015 -0500
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Tue Feb 24 16:45:17 2015 -0500

    Merge topic 'revert_error_in_read_script' into next
    
    f4bf4521 Revert topic 'error_in_read_script'


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=f4bf45211ee4fa6e869a6953b4b7b87e7731ce4c
commit f4bf45211ee4fa6e869a6953b4b7b87e7731ce4c
Author:     Brad King <brad.king at kitware.com>
AuthorDate: Tue Feb 24 16:44:59 2015 -0500
Commit:     Brad King <brad.king at kitware.com>
CommitDate: Tue Feb 24 16:44:59 2015 -0500

    Revert topic 'error_in_read_script'

diff --git a/Source/CTest/cmCTestCoverageHandler.cxx b/Source/CTest/cmCTestCoverageHandler.cxx
index ea95401..790e488 100644
--- a/Source/CTest/cmCTestCoverageHandler.cxx
+++ b/Source/CTest/cmCTestCoverageHandler.cxx
@@ -183,7 +183,6 @@ bool cmCTestCoverageHandler::StartCoverageLogFile(
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE, "Cannot open log file: "
       << covLogFilename << std::endl);
-    this->SetScriptErrorOccurred(true);
     return false;
     }
   std::string local_start_time = this->CTest->CurrentTime();
@@ -349,7 +348,6 @@ int cmCTestCoverageHandler::ProcessHandler()
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE,
       "Cannot create LastCoverage.log file" << std::endl);
-    this->SetScriptErrorOccurred(true);
     }
 
   ofs << "Performing coverage: " << elapsed_time_start << std::endl;
@@ -458,7 +456,6 @@ int cmCTestCoverageHandler::ProcessHandler()
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE,
       "Cannot open coverage summary file." << std::endl);
-    this->SetScriptErrorOccurred(true);
     return -1;
     }
 
@@ -526,7 +523,6 @@ int cmCTestCoverageHandler::ProcessHandler()
       {
       cmCTestLog(this->CTest, ERROR_MESSAGE, "Cannot find file: "
         << fullFileName << std::endl);
-      this->SetScriptErrorOccurred(true);
       continue;
       }
 
@@ -688,7 +684,6 @@ int cmCTestCoverageHandler::ProcessHandler()
       cmCTestLog(this->CTest, ERROR_MESSAGE,
         "  " << *erIt << std::endl);
       }
-    this->SetScriptErrorOccurred(true);
     }
 
   long total_lines = total_tested + total_untested;
@@ -1010,7 +1005,6 @@ int cmCTestCoverageHandler::HandleGCovCoverage(
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE,
       "Could not find gcov." << std::endl);
-    this->SetScriptErrorOccurred(true);
     return 0;
     }
   std::string gcovExtraFlags
@@ -1118,7 +1112,6 @@ int cmCTestCoverageHandler::HandleGCovCoverage(
       cmCTestLog(this->CTest, ERROR_MESSAGE,
         "Command produced error: " << errors << std::endl);
       cont->Error ++;
-      this->SetScriptErrorOccurred(true);
       continue;
       }
     if ( retVal != 0 )
@@ -1127,7 +1120,6 @@ int cmCTestCoverageHandler::HandleGCovCoverage(
         << retVal << " while processing: " << *it << std::endl);
       cmCTestLog(this->CTest, ERROR_MESSAGE,
         "Command produced error: " << cont->Error << std::endl);
-      this->SetScriptErrorOccurred(true);
       }
     cmCTestOptionalLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
       "--------------------------------------------------------------"
@@ -1164,7 +1156,6 @@ int cmCTestCoverageHandler::HandleGCovCoverage(
           cmCTestLog(this->CTest, ERROR_MESSAGE, "Unknown gcov output style e1"
             << std::endl);
           cont->Error ++;
-          this->SetScriptErrorOccurred(true);
           break;
           }
 
@@ -1182,7 +1173,6 @@ int cmCTestCoverageHandler::HandleGCovCoverage(
           cmCTestLog(this->CTest, ERROR_MESSAGE, "Unknown gcov output style e2"
             << std::endl);
           cont->Error ++;
-          this->SetScriptErrorOccurred(true);
           break;
           }
 
@@ -1199,7 +1189,6 @@ int cmCTestCoverageHandler::HandleGCovCoverage(
           cmCTestLog(this->CTest, ERROR_MESSAGE, "Unknown gcov output style e3"
             << std::endl);
           cont->Error ++;
-          this->SetScriptErrorOccurred(true);
           break;
           }
 
@@ -1217,7 +1206,6 @@ int cmCTestCoverageHandler::HandleGCovCoverage(
           cmCTestLog(this->CTest, ERROR_MESSAGE, "Unknown gcov output style e4"
             << std::endl);
           cont->Error ++;
-          this->SetScriptErrorOccurred(true);
           break;
           }
         }
@@ -1232,7 +1220,6 @@ int cmCTestCoverageHandler::HandleGCovCoverage(
           cmCTestLog(this->CTest, ERROR_MESSAGE, "Unknown gcov output style e5"
             << std::endl);
           cont->Error ++;
-          this->SetScriptErrorOccurred(true);
           break;
           }
 
@@ -1249,7 +1236,6 @@ int cmCTestCoverageHandler::HandleGCovCoverage(
           cmCTestLog(this->CTest, ERROR_MESSAGE, "Unknown gcov output style e6"
             << std::endl);
           cont->Error ++;
-          this->SetScriptErrorOccurred(true);
           break;
           }
 
@@ -1267,7 +1253,6 @@ int cmCTestCoverageHandler::HandleGCovCoverage(
           cmCTestLog(this->CTest, ERROR_MESSAGE, "Unknown gcov output style e7"
             << std::endl);
           cont->Error ++;
-          this->SetScriptErrorOccurred(true);
           break;
           }
 
@@ -1285,7 +1270,6 @@ int cmCTestCoverageHandler::HandleGCovCoverage(
           cmCTestLog(this->CTest, ERROR_MESSAGE, "Unknown gcov output style e8"
             << std::endl);
           cont->Error ++;
-          this->SetScriptErrorOccurred(true);
           break;
           }
 
@@ -1303,7 +1287,6 @@ int cmCTestCoverageHandler::HandleGCovCoverage(
           cmCTestLog(this->CTest, ERROR_MESSAGE,
             "Unknown gcov output line: [" << *line << "]"
             << std::endl);
-          this->SetScriptErrorOccurred(true);
           cont->Error ++;
           //abort();
           }
@@ -1327,7 +1310,6 @@ int cmCTestCoverageHandler::HandleGCovCoverage(
           {
           cmCTestLog(this->CTest, ERROR_MESSAGE, "Cannot open file: "
             << gcovFile << std::endl);
-          this->SetScriptErrorOccurred(true);
           }
         else
           {
@@ -1544,7 +1526,6 @@ int cmCTestCoverageHandler::HandleLCovCoverage(
       cmCTestLog(this->CTest, ERROR_MESSAGE,
         "Command produced error: " << errors << std::endl);
       cont->Error ++;
-      this->SetScriptErrorOccurred(true);
       continue;
       }
     if ( retVal != 0 )
@@ -1553,7 +1534,6 @@ int cmCTestCoverageHandler::HandleLCovCoverage(
         << retVal << " while processing: " << *it << std::endl);
       cmCTestLog(this->CTest, ERROR_MESSAGE,
         "Command produced error: " << cont->Error << std::endl);
-      this->SetScriptErrorOccurred(true);
       }
     cmCTestOptionalLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
       "--------------------------------------------------------------"
@@ -1604,7 +1584,6 @@ int cmCTestCoverageHandler::HandleLCovCoverage(
           {
           cmCTestLog(this->CTest, ERROR_MESSAGE, "Cannot open file: "
                      << lcovFile << std::endl);
-          this->SetScriptErrorOccurred(true);
           }
         std::string srcname;
 
@@ -1614,7 +1593,6 @@ int cmCTestCoverageHandler::HandleLCovCoverage(
           cmCTestLog(this->CTest, ERROR_MESSAGE,
                      "Error while parsing lcov file '" << lcovFile << "':"
                      << " No source file name found!" << std::endl);
-          this->SetScriptErrorOccurred(true);
           return 0;
           }
         srcname = srcname.substr(18);
@@ -1648,7 +1626,6 @@ int cmCTestCoverageHandler::HandleLCovCoverage(
             {
             cmCTestLog(this->CTest, ERROR_MESSAGE, "Cannot open file: "
                        << lcovFile << std::endl);
-            this->SetScriptErrorOccurred(true);
             }
           else
             {
@@ -1824,7 +1801,6 @@ int cmCTestCoverageHandler::HandleTracePyCoverage(
       cmCTestLog(this->CTest, ERROR_MESSAGE,
         "Cannot find source Python file corresponding to: "
         << *fileIt << std::endl);
-      this->SetScriptErrorOccurred(true);
       continue;
       }
 
@@ -1842,7 +1818,6 @@ int cmCTestCoverageHandler::HandleTracePyCoverage(
       {
       cmCTestLog(this->CTest, ERROR_MESSAGE, "Cannot open file: "
         << *fileIt << std::endl);
-      this->SetScriptErrorOccurred(true);
       }
     else
       {
@@ -1879,7 +1854,6 @@ int cmCTestCoverageHandler::HandleTracePyCoverage(
               cmCTestLog(this->CTest, ERROR_MESSAGE,
                 "Currently the limit is maximum coverage of 999999"
                 << std::endl);
-              this->SetScriptErrorOccurred(true);
               }
             }
           }
@@ -1974,7 +1948,6 @@ int cmCTestCoverageHandler::RunBullseyeCoverageBranch(
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE,
                "Files and full path files not the same size?:\n");
-    this->SetScriptErrorOccurred(true);
     return 0;
     }
   // create the output stream for the CoverageLog-N.xml file
@@ -1982,7 +1955,6 @@ int cmCTestCoverageHandler::RunBullseyeCoverageBranch(
   int logFileCount = 0;
   if ( !this->StartCoverageLogFile(covLogFile, logFileCount) )
     {
-    this->SetScriptErrorOccurred(true);
     return -1;
     }
   // for each file run covbr on that file to get the coverage
@@ -1994,7 +1966,6 @@ int cmCTestCoverageHandler::RunBullseyeCoverageBranch(
   if(!this->RunBullseyeCommand(cont, "covbr", 0, outputFile))
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE, "error running covbr for." << "\n");
-    this->SetScriptErrorOccurred(true);
     return -1;
     }
   cmCTestOptionalLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
@@ -2006,7 +1977,6 @@ int cmCTestCoverageHandler::RunBullseyeCoverageBranch(
     cmCTestLog(this->CTest, ERROR_MESSAGE,
                "Cannot open coverage file: " <<
                outputFile << std::endl);
-    this->SetScriptErrorOccurred(true);
     return 0;
     }
   std::map<std::string, std::string> fileMap;
@@ -2119,7 +2089,6 @@ int cmCTestCoverageHandler::RunBullseyeCommand(
   if(program.empty())
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE, "Cannot find :" << cmd << "\n");
-    this->SetScriptErrorOccurred(true);
     return 0;
     }
   if(arg)
@@ -2151,7 +2120,6 @@ int cmCTestCoverageHandler::RunBullseyeCommand(
                << program << " " << arg << "\n"
                << "kwsys process state : "
                << runCoverageSrc.GetProcessState());
-    this->SetScriptErrorOccurred(true);
     return 0;
     }
   // since we set the output file names wait for it to end
@@ -2169,7 +2137,6 @@ int cmCTestCoverageHandler::RunBullseyeSourceSummary(
   if(!this->RunBullseyeCommand(cont, "covsrc", "-c", outputFile))
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE, "error running covsrc:\n");
-    this->SetScriptErrorOccurred(true);
     return 0;
     }
 
@@ -2180,7 +2147,6 @@ int cmCTestCoverageHandler::RunBullseyeSourceSummary(
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE,
       "Cannot open coverage summary file." << std::endl);
-    this->SetScriptErrorOccurred(true);
     return 0;
     }
   this->CTest->StartXML(covSumFile, this->AppendXML);
@@ -2221,7 +2187,6 @@ int cmCTestCoverageHandler::RunBullseyeSourceSummary(
     cmCTestLog(this->CTest, ERROR_MESSAGE,
                "Cannot open coverage summary file: " <<
                outputFile << std::endl);
-    this->SetScriptErrorOccurred(true);
     return 0;
     }
   std::set<std::string> coveredFileNames;
@@ -2386,7 +2351,6 @@ int cmCTestCoverageHandler::HandleBullseyeCoverage(
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE,
                "Error running bullseye summary.\n");
-    this->SetScriptErrorOccurred(true);
     return 0;
     }
   cmCTestOptionalLog(this->CTest, DEBUG, "HandleBullseyeCoverage return 1 "
@@ -2425,7 +2389,6 @@ bool cmCTestCoverageHandler::ParseBullsEyeCovsrcLine(
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE, "Error parsing string : "
                << inputLine << "\n");
-    this->SetScriptErrorOccurred(true);
     return false;
     }
   // the source file has "" around it so extract out the file name
@@ -2461,7 +2424,6 @@ bool cmCTestCoverageHandler::ParseBullsEyeCovsrcLine(
     cmCTestLog(this->CTest, ERROR_MESSAGE, "Error parsing input : "
                << inputLine << " last pos not npos =  " << pos <<
                "\n");
-    this->SetScriptErrorOccurred(true);
     }
   return true;
 }
diff --git a/Source/CTest/cmCTestGenericHandler.cxx b/Source/CTest/cmCTestGenericHandler.cxx
index c16ec2b..81eb0a8 100644
--- a/Source/CTest/cmCTestGenericHandler.cxx
+++ b/Source/CTest/cmCTestGenericHandler.cxx
@@ -23,7 +23,6 @@ cmCTestGenericHandler::cmCTestGenericHandler()
   this->SubmitIndex = 0;
   this->AppendXML = false;
   this->Quiet = false;
-  this->ScriptErrorOccurred = false;
 }
 
 //----------------------------------------------------------------------
diff --git a/Source/CTest/cmCTestGenericHandler.h b/Source/CTest/cmCTestGenericHandler.h
index d83ad7b..8567dd7 100644
--- a/Source/CTest/cmCTestGenericHandler.h
+++ b/Source/CTest/cmCTestGenericHandler.h
@@ -90,12 +90,6 @@ public:
   void SetQuiet(bool b) { this->Quiet = b; }
   bool GetQuiet() { return this->Quiet; }
 
-  /**
-   * Get/Set whether or not a script-level error occurred.
-   */
-  bool GetScriptErrorOccurred() { return this->ScriptErrorOccurred; }
-  void SetScriptErrorOccurred(bool b) { this->ScriptErrorOccurred = b; }
-
 protected:
   bool StartResultingXML(cmCTest::Part part,
                          const char* name, cmGeneratedFileStream& xofs);
@@ -103,7 +97,6 @@ protected:
 
   bool AppendXML;
   bool Quiet;
-  bool ScriptErrorOccurred;
   cmSystemTools::OutputOption HandlerVerbose;
   cmCTest *CTest;
   t_StringToString Options;
diff --git a/Source/CTest/cmCTestHandlerCommand.cxx b/Source/CTest/cmCTestHandlerCommand.cxx
index 571e539..3003e8a 100644
--- a/Source/CTest/cmCTestHandlerCommand.cxx
+++ b/Source/CTest/cmCTestHandlerCommand.cxx
@@ -141,12 +141,6 @@ bool cmCTestHandlerCommand
   cmSystemTools::ChangeDirectory(
     this->CTest->GetCTestConfiguration("BuildDirectory"));
   int res = handler->ProcessHandler();
-  cmSystemTools::ChangeDirectory(current_dir);
-
-  if (handler->GetScriptErrorOccurred())
-    {
-    return false;
-    }
   if ( this->Values[ct_RETURN_VALUE] && *this->Values[ct_RETURN_VALUE])
     {
     std::ostringstream str;
@@ -154,6 +148,7 @@ bool cmCTestHandlerCommand
     this->Makefile->AddDefinition(
       this->Values[ct_RETURN_VALUE], str.str().c_str());
     }
+  cmSystemTools::ChangeDirectory(current_dir);
   return true;
 }
 
diff --git a/Source/CTest/cmCTestMemCheckHandler.cxx b/Source/CTest/cmCTestMemCheckHandler.cxx
index f603297..061f3fd 100644
--- a/Source/CTest/cmCTestMemCheckHandler.cxx
+++ b/Source/CTest/cmCTestMemCheckHandler.cxx
@@ -51,7 +51,6 @@ static void xmlReportError(int line, const char* msg, void* data)
   cmCTestLog(ctest, ERROR_MESSAGE,
              "Error parsing XML in stream at line "
              << line << ": " << msg << std::endl);
-  ctest->GetHandler("memcheck")->SetScriptErrorOccurred(true);
 }
 
 // parse the xml file containing the results of last BoundsChecker run
@@ -112,7 +111,6 @@ public:
         this->Errors.push_back(cmCTestMemCheckHandler::ABW); // do not know
         cmCTestLog(this->CTest, ERROR_MESSAGE,
                    "No Category found in Bounds checker XML\n" );
-        this->CTest->GetHandler("memcheck")->SetScriptErrorOccurred(true);
         return;
         }
       while(ptr->ErrorCategory && cat)
@@ -130,7 +128,6 @@ public:
         cmCTestLog(this->CTest, ERROR_MESSAGE,
                    "Found unknown Bounds Checker error "
                    << ptr->ErrorCategory << std::endl);
-        this->CTest->GetHandler("memcheck")->SetScriptErrorOccurred(true);
         }
     }
   cmCTest* CTest;
@@ -178,7 +175,6 @@ int cmCTestMemCheckHandler::PreProcessHandler()
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE,
       "Problem executing pre-memcheck command(s)." << std::endl);
-    this->SetScriptErrorOccurred(true);
     return 0;
     }
   return 1;
@@ -191,7 +187,6 @@ int cmCTestMemCheckHandler::PostProcessHandler()
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE,
       "Problem executing post-memcheck command(s)." << std::endl);
-    this->SetScriptErrorOccurred(true);
     return 0;
     }
   return 1;
@@ -651,7 +646,6 @@ bool cmCTestMemCheckHandler::InitializeMemoryChecking()
             "Cannot find memory checker suppression file: "
             << this->CTest->GetCTestConfiguration(
               "MemoryCheckSuppressionFile") << std::endl);
-          this->SetScriptErrorOccurred(true);
           return false;
           }
         std::string suppressions = "--suppressions="
@@ -677,7 +671,6 @@ bool cmCTestMemCheckHandler::InitializeMemoryChecking()
                      "Cannot find memory checker suppression file: "
                      << this->CTest->GetCTestConfiguration(
                        "MemoryCheckSuppressionFile").c_str() << std::endl);
-          this->SetScriptErrorOccurred(true);
           return false;
           }
         std::string filterFiles = "/FilterFiles="
@@ -749,7 +742,6 @@ bool cmCTestMemCheckHandler::InitializeMemoryChecking()
       cmCTestLog(this->CTest, ERROR_MESSAGE,
         "Do not understand memory checker: " << this->MemoryTester
         << std::endl);
-      this->SetScriptErrorOccurred(true);
       return false;
     }
 
@@ -916,7 +908,6 @@ bool cmCTestMemCheckHandler::ProcessMemCheckPurifyOutput(
           << pfW.match(1) << std::endl);
         ostr << "*** Unknown Purify memory fault: " << pfW.match(1)
           << std::endl;
-        this->SetScriptErrorOccurred(true);
         }
       }
     if ( failure != this->ResultStrings.size() )
@@ -1152,7 +1143,6 @@ bool cmCTestMemCheckHandler::ProcessMemCheckBoundsCheckerOutput(
         cmCTestLog(this->CTest, ERROR_MESSAGE,
                    "Error in ParseChunk: " << theLine
                    << std::endl);
-        this->SetScriptErrorOccurred(true);
         }
       }
     }
@@ -1227,7 +1217,6 @@ cmCTestMemCheckHandler::PostProcessBoundsCheckerTest(cmCTestTestResult& res,
     {
     std::string log = "Cannot read memory tester output file: " + ofile;
     cmCTestLog(this->CTest, ERROR_MESSAGE, log.c_str() << std::endl);
-    this->SetScriptErrorOccurred(true);
     return;
     }
   res.Output += BOUNDS_CHECKER_MARKER;
@@ -1263,7 +1252,6 @@ cmCTestMemCheckHandler::AppendMemTesterOutput(cmCTestTestResult& res,
     {
     std::string log = "Cannot read memory tester output file: " + ofile;
     cmCTestLog(this->CTest, ERROR_MESSAGE, log.c_str() << std::endl);
-    this->SetScriptErrorOccurred(true);
     return;
     }
   std::string line;
@@ -1302,7 +1290,6 @@ void cmCTestMemCheckHandler::TestOutputFileNames(int test,
       std::string log = "Cannot find memory tester output file: "
         + ofile;
       cmCTestLog(this->CTest, ERROR_MESSAGE, log.c_str() << std::endl);
-      this->SetScriptErrorOccurred(true);
       ofile = "";
       }
     else
@@ -1316,7 +1303,6 @@ void cmCTestMemCheckHandler::TestOutputFileNames(int test,
     std::string log = "Cannot find memory tester output file: "
       + ofile;
     cmCTestLog(this->CTest, ERROR_MESSAGE, log.c_str() << std::endl);
-    this->SetScriptErrorOccurred(true);
     ofile = "";
     }
   files.push_back(ofile);
diff --git a/Source/CTest/cmCTestSubmitHandler.cxx b/Source/CTest/cmCTestSubmitHandler.cxx
index ddb5f4c..d585863 100644
--- a/Source/CTest/cmCTestSubmitHandler.cxx
+++ b/Source/CTest/cmCTestSubmitHandler.cxx
@@ -235,7 +235,6 @@ bool cmCTestSubmitHandler::SubmitUsingFTP(const std::string& localprefix,
           << local_file << std::endl);
         ::curl_easy_cleanup(curl);
         ::curl_global_cleanup();
-        this->SetScriptErrorOccurred(true);
         return false;
         }
       unsigned long filelen = cmSystemTools::FileLength(local_file);
@@ -315,7 +314,6 @@ bool cmCTestSubmitHandler::SubmitUsingFTP(const std::string& localprefix,
         *this->LogFile << std::endl;
         ::curl_easy_cleanup(curl);
         ::curl_global_cleanup();
-        this->SetScriptErrorOccurred(true);
         return false;
         }
       // always cleanup
@@ -479,7 +477,6 @@ bool cmCTestSubmitHandler::SubmitUsingHTTP(const std::string& localprefix,
           << local_file << std::endl);
         ::curl_easy_cleanup(curl);
         ::curl_global_cleanup();
-        this->SetScriptErrorOccurred(true);
         return false;
         }
       unsigned long filelen = cmSystemTools::FileLength(local_file);
@@ -624,7 +621,6 @@ bool cmCTestSubmitHandler::SubmitUsingHTTP(const std::string& localprefix,
           }
         ::curl_easy_cleanup(curl);
         ::curl_global_cleanup();
-        this->SetScriptErrorOccurred(true);
         return false;
         }
       // always cleanup
@@ -787,7 +783,6 @@ bool cmCTestSubmitHandler::TriggerUsingHTTP(
           }
         ::curl_easy_cleanup(curl);
         ::curl_global_cleanup();
-        this->SetScriptErrorOccurred(true);
         return false;
         }
 
@@ -913,7 +908,6 @@ bool cmCTestSubmitHandler::SubmitUsingSCP(
   cmsysProcess_Delete(cp);
   if ( problems )
     {
-    this->SetScriptErrorOccurred(true);
     return false;
     }
   return true;
@@ -935,7 +929,6 @@ bool cmCTestSubmitHandler::SubmitUsingCP(
                << "\tNumber of files: " << files.size() << "\n"
                << "\tremoteprefix: " << remoteprefix << "\n"
                << "\tdestination: " << destination << std::endl);
-    this->SetScriptErrorOccurred(true);
     return 0;
     }
 
@@ -1003,7 +996,6 @@ bool cmCTestSubmitHandler::SubmitUsingXMLRPC(const std::string& localprefix,
       {
       cmCTestLog(this->CTest, ERROR_MESSAGE, "  Cannot find file: "
         << local_file.c_str() << std::endl);
-      this->SetScriptErrorOccurred(true);
       return false;
       }
 
@@ -1014,7 +1006,6 @@ bool cmCTestSubmitHandler::SubmitUsingXMLRPC(const std::string& localprefix,
       {
       cmCTestLog(this->CTest, ERROR_MESSAGE, "  File too big: "
         << local_file.c_str() << std::endl);
-      this->SetScriptErrorOccurred(true);
       return false;
       }
     size_t fileSize = static_cast<size_t>(st.st_size);
@@ -1023,7 +1014,6 @@ bool cmCTestSubmitHandler::SubmitUsingXMLRPC(const std::string& localprefix,
       {
       cmCTestLog(this->CTest, ERROR_MESSAGE, "  Cannot open file: "
         << local_file.c_str() << std::endl);
-      this->SetScriptErrorOccurred(true);
       return false;
       }
 
@@ -1034,7 +1024,6 @@ bool cmCTestSubmitHandler::SubmitUsingXMLRPC(const std::string& localprefix,
       fclose(fp);
       cmCTestLog(this->CTest, ERROR_MESSAGE, "  Cannot read file: "
         << local_file.c_str() << std::endl);
-      this->SetScriptErrorOccurred(true);
       return false;
       }
     fclose(fp);
@@ -1052,7 +1041,6 @@ bool cmCTestSubmitHandler::SubmitUsingXMLRPC(const std::string& localprefix,
         << env.fault_string << " (" << env.fault_code << ")" << std::endl);
       xmlrpc_env_clean(&env);
       xmlrpc_client_cleanup();
-      this->SetScriptErrorOccurred(true);
       return false;
       }
 
@@ -1109,14 +1097,12 @@ int cmCTestSubmitHandler::HandleCDashUploadFile(std::string const& file,
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE,
                "Upload file not specified\n");
-    this->SetScriptErrorOccurred(true);
     return -1;
     }
   if (!cmSystemTools::FileExists(file))
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE,
                "Upload file not found: '" << file << "'\n");
-    this->SetScriptErrorOccurred(true);
     return -1;
     }
   cmCTestCurl curl(this->CTest);
@@ -1134,7 +1120,6 @@ int cmCTestSubmitHandler::HandleCDashUploadFile(std::string const& file,
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE,
                "Only http and https are supported for CDASH_UPLOAD\n");
-    this->SetScriptErrorOccurred(true);
     return -1;
     }
   char md5sum[33];
@@ -1177,7 +1162,6 @@ int cmCTestSubmitHandler::HandleCDashUploadFile(std::string const& file,
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE,
                "Error in HttpRequest\n" << response);
-    this->SetScriptErrorOccurred(true);
     return -1;
     }
   cmCTestOptionalLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
@@ -1189,7 +1173,6 @@ int cmCTestSubmitHandler::HandleCDashUploadFile(std::string const& file,
     cmCTestLog(this->CTest, ERROR_MESSAGE,
                "error parsing json string [" << response << "]\n"
                << reader.getFormattedErrorMessages() << "\n");
-    this->SetScriptErrorOccurred(true);
     return -1;
     }
   if(json["status"].asInt() != 0)
@@ -1197,7 +1180,6 @@ int cmCTestSubmitHandler::HandleCDashUploadFile(std::string const& file,
     cmCTestLog(this->CTest, ERROR_MESSAGE,
                "Bad status returned from CDash: "
                << json["status"].asInt());
-    this->SetScriptErrorOccurred(true);
     return -1;
     }
   if(json["datafilesmd5"].isArray())
@@ -1216,7 +1198,6 @@ int cmCTestSubmitHandler::HandleCDashUploadFile(std::string const& file,
     cmCTestLog(this->CTest, ERROR_MESSAGE,
                "bad datafilesmd5 value in response "
                << response << "\n");
-    this->SetScriptErrorOccurred(true);
     return -1;
     }
 
@@ -1231,7 +1212,6 @@ int cmCTestSubmitHandler::HandleCDashUploadFile(std::string const& file,
     cmCTestLog(this->CTest, ERROR_MESSAGE,
                "error uploading to CDash. "
                << file << " " << url << " " << fstr.str());
-    this->SetScriptErrorOccurred(true);
     return -1;
     }
   if(!reader.parse(response, json))
@@ -1239,7 +1219,6 @@ int cmCTestSubmitHandler::HandleCDashUploadFile(std::string const& file,
     cmCTestLog(this->CTest, ERROR_MESSAGE,
                "error parsing json string [" << response << "]\n"
                << reader.getFormattedErrorMessages() << "\n");
-    this->SetScriptErrorOccurred(true);
     return -1;
     }
   cmCTestOptionalLog(this->CTest, HANDLER_VERBOSE_OUTPUT,
@@ -1270,7 +1249,6 @@ int cmCTestSubmitHandler::ProcessHandler()
     cmCTestLog(this->CTest, ERROR_MESSAGE,
       "Cannot find BuildDirectory  key in the DartConfiguration.tcl"
       << std::endl);
-    this->SetScriptErrorOccurred(true);
     return -1;
     }
 
@@ -1479,7 +1457,6 @@ int cmCTestSubmitHandler::ProcessHandler()
         "   Problems when submitting via FTP"
         << std::endl);
       ofs << "   Problems when submitting via FTP" << std::endl;
-      this->SetScriptErrorOccurred(true);
       return -1;
       }
     if(!this->CDash)
@@ -1497,7 +1474,6 @@ int cmCTestSubmitHandler::ProcessHandler()
         cmCTestLog(this->CTest, ERROR_MESSAGE,
                    "   Problems when triggering via HTTP" << std::endl);
         ofs << "   Problems when triggering via HTTP" << std::endl;
-        this->SetScriptErrorOccurred(true);
         return -1;
         }
       cmCTestOptionalLog(this->CTest, HANDLER_OUTPUT,
@@ -1541,7 +1517,6 @@ int cmCTestSubmitHandler::ProcessHandler()
       cmCTestLog(this->CTest, ERROR_MESSAGE,
         "   Problems when submitting via HTTP" << std::endl);
       ofs << "   Problems when submitting via HTTP" << std::endl;
-      this->SetScriptErrorOccurred(true);
       return -1;
       }
     if(!this->CDash)
@@ -1557,7 +1532,6 @@ int cmCTestSubmitHandler::ProcessHandler()
         cmCTestLog(this->CTest, ERROR_MESSAGE,
                    "   Problems when triggering via HTTP" << std::endl);
         ofs << "   Problems when triggering via HTTP" << std::endl;
-        this->SetScriptErrorOccurred(true);
         return -1;
         }
       }
@@ -1593,7 +1567,6 @@ int cmCTestSubmitHandler::ProcessHandler()
       cmCTestLog(this->CTest, ERROR_MESSAGE,
         "   Problems when submitting via XML-RPC" << std::endl);
       ofs << "   Problems when submitting via XML-RPC" << std::endl;
-      this->SetScriptErrorOccurred(true);
       return -1;
       }
     cmCTestOptionalLog(this->CTest, HANDLER_OUTPUT, "   Submission successful"
@@ -1604,7 +1577,6 @@ int cmCTestSubmitHandler::ProcessHandler()
     cmCTestLog(this->CTest, ERROR_MESSAGE,
                "   Submission method \"xmlrpc\" not compiled into CTest!"
                << std::endl);
-    this->SetScriptErrorOccurred(true);
     return -1;
 #endif
     }
@@ -1633,7 +1605,6 @@ int cmCTestSubmitHandler::ProcessHandler()
         "   Problems when submitting via SCP"
         << std::endl);
       ofs << "   Problems when submitting via SCP" << std::endl;
-      this->SetScriptErrorOccurred(true);
       return -1;
       }
     cmSystemTools::ChangeDirectory(oldWorkingDirectory);
@@ -1667,7 +1638,6 @@ int cmCTestSubmitHandler::ProcessHandler()
         "   Problems when submitting via CP"
         << std::endl);
       ofs << "   Problems when submitting via cp" << std::endl;
-      this->SetScriptErrorOccurred(true);
       return -1;
       }
     cmSystemTools::ChangeDirectory(oldWorkingDirectory);
@@ -1679,7 +1649,6 @@ int cmCTestSubmitHandler::ProcessHandler()
 
   cmCTestLog(this->CTest, ERROR_MESSAGE, "   Unknown submission method: \""
     << dropMethod << "\"" << std::endl);
-  this->SetScriptErrorOccurred(true);
   return -1;
 }
 
diff --git a/Source/CTest/cmCTestUpdateHandler.cxx b/Source/CTest/cmCTestUpdateHandler.cxx
index 57e9216..b18786a 100644
--- a/Source/CTest/cmCTestUpdateHandler.cxx
+++ b/Source/CTest/cmCTestUpdateHandler.cxx
@@ -204,7 +204,6 @@ int cmCTestUpdateHandler::ProcessHandler()
     cmCTestLog(this->CTest, ERROR_MESSAGE,
       "Cannot find SourceDirectory  key in the DartConfiguration.tcl"
       << std::endl);
-    this->SetScriptErrorOccurred(true);
     return -1;
     }
 
@@ -254,7 +253,6 @@ int cmCTestUpdateHandler::ProcessHandler()
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE, "Cannot open log file"
       << std::endl);
-    this->SetScriptErrorOccurred(true);
     return -1;
     }
   std::string start_time = this->CTest->CurrentTime();
@@ -320,14 +318,12 @@ int cmCTestUpdateHandler::ProcessHandler()
     cmCTestLog(this->CTest, ERROR_MESSAGE,
       "   There are modified or conflicting files in the repository"
       << std::endl);
-    this->SetScriptErrorOccurred(true);
     }
   if(!updated)
     {
     os << "Update command failed:\n" << vc->GetUpdateCommandLine();
     cmCTestLog(this->CTest, ERROR_MESSAGE, "   Update command failed: "
                << vc->GetUpdateCommandLine() << "\n");
-    this->SetScriptErrorOccurred(true);
     }
   os << "</UpdateReturnStatus>" << std::endl;
   os << "</Update>" << std::endl;
@@ -428,7 +424,6 @@ bool cmCTestUpdateHandler::SelectVCS()
         }
       e << " configuration key.";
       cmCTestLog(this->CTest, ERROR_MESSAGE, e.str() << std::endl);
-      this->SetScriptErrorOccurred(true);
       return false;
       }
     }
diff --git a/Source/CTest/cmCTestUploadHandler.cxx b/Source/CTest/cmCTestUploadHandler.cxx
index 965f88e..579190a 100644
--- a/Source/CTest/cmCTestUploadHandler.cxx
+++ b/Source/CTest/cmCTestUploadHandler.cxx
@@ -42,7 +42,6 @@ int cmCTestUploadHandler::ProcessHandler()
     {
     cmCTestLog(this->CTest, ERROR_MESSAGE,
       "Cannot open Upload.xml file" << std::endl);
-    this->SetScriptErrorOccurred(true);
     return -1;
     }
   std::string buildname = cmCTest::SafeBuildIdField(
diff --git a/Source/cmCTest.cxx b/Source/cmCTest.cxx
index aec943e..e6d3960 100644
--- a/Source/cmCTest.cxx
+++ b/Source/cmCTest.cxx
@@ -3122,6 +3122,7 @@ void cmCTest::Log(int logType, const char* file, int line, const char* msg,
       cmCTestLogOutputFileLine(err);
       err << msg;
       err.flush();
+      cmSystemTools::SetErrorOccured();
       break;
     default:
       cmCTestLogOutputFileLine(out);
diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx
index f989aff..ccfe2b1 100644
--- a/Source/cmMakefile.cxx
+++ b/Source/cmMakefile.cxx
@@ -382,21 +382,8 @@ bool cmMakefile::ExecuteCommand(const cmListFileFunction& lff,
         {
         if(!status.GetNestedError())
           {
-          if (cmSystemTools::GetFilenameName(
-              this->GetSafeDefinition("CMAKE_CURRENT_LIST_FILE")) ==
-              this->GetSafeDefinition("CTEST_SCRIPT_NAME") &&
-              std::string(pcmd->GetError()).find("unknown error") !=
-              std::string::npos)
-            {
-            // Don't report "unknown error" from a CTest script.
-            // Instead simply note that an error occurred.
-            cmSystemTools::SetFatalErrorOccured();
-            }
-          else
-            {
-            // The command invocation requested that we report an error.
-            this->IssueMessage(cmake::FATAL_ERROR, pcmd->GetError());
-            }
+          // The command invocation requested that we report an error.
+          this->IssueMessage(cmake::FATAL_ERROR, pcmd->GetError());
           }
         result = false;
         if ( this->GetCMakeInstance()->GetWorkingMode() != cmake::NORMAL_MODE)
diff --git a/Tests/RunCMake/ctest_build/BuildCompileError-stderr.txt b/Tests/RunCMake/ctest_build/BuildCompileError-stderr.txt
deleted file mode 100644
index d8e63fa..0000000
--- a/Tests/RunCMake/ctest_build/BuildCompileError-stderr.txt
+++ /dev/null
@@ -1 +0,0 @@
-Error\(s\) when building project$
diff --git a/Tests/RunCMake/ctest_build/BuildCompileError-stdout.txt b/Tests/RunCMake/ctest_build/BuildCompileError-stdout.txt
deleted file mode 100644
index 63215c0..0000000
--- a/Tests/RunCMake/ctest_build/BuildCompileError-stdout.txt
+++ /dev/null
@@ -1,16 +0,0 @@
-Run dashboard with model Experimental
-   Source directory: .*/Tests/RunCMake/ctest_build/BuildCompileError
-   Build directory: .*/Tests/RunCMake/ctest_build/BuildCompileError-build
-   Reading ctest configuration file: .*/Tests/RunCMake/ctest_build/BuildCompileError/CTestConfig.cmake
-   Site: test-site
-   Build name: test-build-name
-   Use Experimental tag: [0-9-]+
-Configure project
-   Each . represents 1024 bytes of output
-    . Size of output: [0-9]+K
-Build project
-   Each symbol represents 1024 bytes of output.
-   '!' represents an error and '\*' a warning.
-    . Size of output: [0-9]+K
-   [1-9] Compiler errors
-   0 Compiler warnings
diff --git a/Tests/RunCMake/ctest_build/CMakeLists.txt.in b/Tests/RunCMake/ctest_build/CMakeLists.txt.in
index 55ccc19..9ba08e9 100644
--- a/Tests/RunCMake/ctest_build/CMakeLists.txt.in
+++ b/Tests/RunCMake/ctest_build/CMakeLists.txt.in
@@ -1,6 +1,4 @@
 cmake_minimum_required(VERSION 3.1)
-project(CTestBuild at CASE_NAME@)
+project(CTestBuild at CASE_NAME@ NONE)
 include(CTest)
 add_test(NAME RunCMakeVersion COMMAND "${CMAKE_COMMAND}" --version)
-add_executable(compile_error EXCLUDE_FROM_ALL
-  @RunCMake_SOURCE_DIR@/../../CTestTestFailure/badCode.cxx)
diff --git a/Tests/RunCMake/ctest_build/RunCMakeTest.cmake b/Tests/RunCMake/ctest_build/RunCMakeTest.cmake
index 2fc80d3..5826fe4 100644
--- a/Tests/RunCMake/ctest_build/RunCMakeTest.cmake
+++ b/Tests/RunCMake/ctest_build/RunCMakeTest.cmake
@@ -8,4 +8,3 @@ function(run_ctest_build CASE_NAME)
 endfunction()
 
 run_ctest_build(BuildQuiet QUIET)
-run_ctest_build(BuildCompileError TARGET compile_error)

-----------------------------------------------------------------------

Summary of changes:
 Source/CTest/cmCTestCoverageHandler.cxx            |   38 --------------------
 Source/CTest/cmCTestGenericHandler.cxx             |    1 -
 Source/CTest/cmCTestGenericHandler.h               |    7 ----
 Source/CTest/cmCTestHandlerCommand.cxx             |    7 +---
 Source/CTest/cmCTestMemCheckHandler.cxx            |   14 --------
 Source/CTest/cmCTestSubmitHandler.cxx              |   31 ----------------
 Source/CTest/cmCTestUpdateHandler.cxx              |    5 ---
 Source/CTest/cmCTestUploadHandler.cxx              |    1 -
 Source/cmCTest.cxx                                 |    1 +
 Source/cmMakefile.cxx                              |   17 ++-------
 .../ctest_build/BuildCompileError-stderr.txt       |    1 -
 .../ctest_build/BuildCompileError-stdout.txt       |   16 ---------
 Tests/RunCMake/ctest_build/CMakeLists.txt.in       |    4 +--
 Tests/RunCMake/ctest_build/RunCMakeTest.cmake      |    1 -
 14 files changed, 5 insertions(+), 139 deletions(-)
 delete mode 100644 Tests/RunCMake/ctest_build/BuildCompileError-stderr.txt
 delete mode 100644 Tests/RunCMake/ctest_build/BuildCompileError-stdout.txt


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list