ENH: Use CMake's error reporting mechanism

This commit is contained in:
Andy Cedilnik 2006-06-22 15:37:58 -04:00
parent 99f4edb4e4
commit a6e68ac582
1 changed files with 12 additions and 11 deletions

View File

@ -57,25 +57,26 @@ bool cmMessageCommand::InitialPass(std::vector<std::string> const& args)
message += *i; message += *i;
} }
if (send_error) if (send_error || fatal_error)
{ {
cmSystemTools::Error(message.c_str()); //cmSystemTools::Error(message.c_str());
this->SetError(message.c_str());
} }
else else
{ {
if (status) if (status)
{ {
this->Makefile->DisplayStatus(message.c_str(), -1); this->Makefile->DisplayStatus(message.c_str(), -1);
} }
else else
{ {
cmSystemTools::Message(message.c_str()); cmSystemTools::Message(message.c_str());
} }
} }
if(fatal_error ) if(fatal_error )
{ {
cmSystemTools::SetFatalErrorOccured(); cmSystemTools::SetFatalErrorOccured();
} }
return true; return (!send_error && !fatal_error);
} }