Do not define cout/cerr preprocessor symbols

Apply the change from commit bd3d0eaf (cmCTest: don't redefine cout and
cerr, 2016-09-01) to the rest of ctest and cpack.  These definitions
are no longer needed because our conventions are well established.
This commit is contained in:
Brad King 2016-10-04 09:34:37 -04:00
parent 834efe12bf
commit 5385817762
7 changed files with 0 additions and 39 deletions

View File

@ -32,16 +32,6 @@ class cmMakefile;
cmCPackLog_msg.str().c_str()); \
} while (0)
#ifdef cerr
#undef cerr
#endif
#define cerr no_cerr_use_cmCPack_Log
#ifdef cout
#undef cout
#endif
#define cout no_cout_use_cmCPack_Log
/** \class cmCPackGenerator
* \brief A superclass of all CPack Generators
*

View File

@ -15,8 +15,6 @@ cmCPackLog::cmCPackLog()
this->NewLine = true;
this->LastTag = cmCPackLog::NOTAG;
#undef cerr
#undef cout
this->DefaultOutput = &std::cout;
this->DefaultError = &std::cerr;

View File

@ -19,16 +19,6 @@
(ctSelf)->Log(logType, __FILE__, __LINE__, cmCPackLog_msg.str().c_str()); \
} while (0)
#ifdef cerr
#undef cerr
#endif
#define cerr no_cerr_use_cmCPack_Log
#ifdef cout
#undef cout
#endif
#define cout no_cout_use_cmCPack_Log
/** \class cmCPackLog
* \brief A container for CPack generators
*

View File

@ -415,9 +415,7 @@ int main(int argc, char const* const* argv)
}
doc.SetSection("Generators", v);
#undef cout
return doc.PrintRequestedDocumentation(std::cout) ? 0 : 1;
#define cout no_cout_use_cmCPack_Log
}
if (cmSystemTools::GetErrorOccuredFlag()) {

View File

@ -375,11 +375,7 @@ void cmCTestMemCheckHandler::GenerateDartOutput(cmXMLWriter& xml)
xml.StartElement("DefectList");
for (cc = 0; cc < this->GlobalResults.size(); cc++) {
if (this->GlobalResults[cc]) {
#ifdef cerr
#undef cerr
#endif
std::cerr.width(35);
#define cerr no_cerr
cmCTestOptionalLog(this->CTest, HANDLER_OUTPUT,
this->ResultStringsLong[cc]
<< " - " << this->GlobalResults[cc] << std::endl,

View File

@ -2651,13 +2651,6 @@ static const char* cmCTestStringLogType[] = { "DEBUG",
"ERROR_MESSAGE",
CM_NULLPTR };
#ifdef cerr
#undef cerr
#endif
#ifdef cout
#undef cout
#endif
#define cmCTestLogOutputFileLine(stream) \
if (this->ShowLineNumbers) { \
(stream) << std::endl << file << ":" << line << " "; \

View File

@ -163,11 +163,7 @@ int main(int argc, char const* const* argv)
doc.SetSection("Name", cmDocumentationName);
doc.SetSection("Usage", cmDocumentationUsage);
doc.PrependSection("Options", cmDocumentationOptions);
#ifdef cout
#undef cout
#endif
return doc.PrintRequestedDocumentation(std::cout) ? 0 : 1;
#define cout no_cout_use_cmCTestLog
}
}