summaryrefslogtreecommitdiffstats
path: root/Source/cmMessageCommand.cxx
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2006-10-06 15:11:59 (GMT)
committerBill Hoffman <bill.hoffman@kitware.com>2006-10-06 15:11:59 (GMT)
commit017cec95ada69369e3959cc9c09248335ea2dbfa (patch)
tree8605887f13d7632a16e94899ad5fdc955aa990a9 /Source/cmMessageCommand.cxx
parent7f7374e8189871289b604fcc8f109411bca793dd (diff)
downloadCMake-017cec95ada69369e3959cc9c09248335ea2dbfa.zip
CMake-017cec95ada69369e3959cc9c09248335ea2dbfa.tar.gz
CMake-017cec95ada69369e3959cc9c09248335ea2dbfa.tar.bz2
ENH: do not print a call stack if the user does a message error unless --debug-output is used
Diffstat (limited to 'Source/cmMessageCommand.cxx')
-rw-r--r--Source/cmMessageCommand.cxx17
1 files changed, 14 insertions, 3 deletions
diff --git a/Source/cmMessageCommand.cxx b/Source/cmMessageCommand.cxx
index 7ab17fb..266bcf8 100644
--- a/Source/cmMessageCommand.cxx
+++ b/Source/cmMessageCommand.cxx
@@ -59,8 +59,14 @@ bool cmMessageCommand::InitialPass(std::vector<std::string> const& args)
if (send_error || fatal_error)
{
- //cmSystemTools::Error(message.c_str());
- this->SetError(message.c_str());
+ if( !this->Makefile->GetCMakeInstance()->GetDebugOutput())
+ {
+ cmSystemTools::Error(message.c_str());
+ }
+ else
+ {
+ this->SetError(message.c_str());
+ }
}
else
{
@@ -77,6 +83,11 @@ bool cmMessageCommand::InitialPass(std::vector<std::string> const& args)
{
cmSystemTools::SetFatalErrorOccured();
}
- return (!send_error && !fatal_error);
+ // if debug is on then retru
+ if(this->Makefile->GetCMakeInstance()->GetDebugOutput())
+ {
+ return (!send_error && !fatal_error);
+ }
+ return true;
}