Fix a few more places to use cmsys::[io]fstream instead of std::fstream.
This commit is contained in:
parent
c5fdca7c17
commit
42e39bb37d
@ -33,8 +33,8 @@ void cmCTestBatchTestHandler::WriteBatchScript()
|
|||||||
{
|
{
|
||||||
this->Script = this->CTest->GetBinaryDir()
|
this->Script = this->CTest->GetBinaryDir()
|
||||||
+ "/Testing/CTestBatch.txt";
|
+ "/Testing/CTestBatch.txt";
|
||||||
std::fstream fout;
|
cmsys::ofstream fout;
|
||||||
fout.open(this->Script.c_str(), std::ios::out);
|
fout.open(this->Script.c_str());
|
||||||
fout << "#!/bin/sh\n";
|
fout << "#!/bin/sh\n";
|
||||||
|
|
||||||
for(TestMap::iterator i = this->Tests.begin(); i != this->Tests.end(); ++i)
|
for(TestMap::iterator i = this->Tests.begin(); i != this->Tests.end(); ++i)
|
||||||
@ -48,7 +48,7 @@ void cmCTestBatchTestHandler::WriteBatchScript()
|
|||||||
}
|
}
|
||||||
|
|
||||||
//---------------------------------------------------------
|
//---------------------------------------------------------
|
||||||
void cmCTestBatchTestHandler::WriteSrunArgs(int test, std::fstream& fout)
|
void cmCTestBatchTestHandler::WriteSrunArgs(int test, cmsys::ofstream& fout)
|
||||||
{
|
{
|
||||||
cmCTestTestHandler::cmCTestTestProperties* properties =
|
cmCTestTestHandler::cmCTestTestProperties* properties =
|
||||||
this->Properties[test];
|
this->Properties[test];
|
||||||
@ -79,7 +79,7 @@ void cmCTestBatchTestHandler::WriteSrunArgs(int test, std::fstream& fout)
|
|||||||
}
|
}
|
||||||
|
|
||||||
//---------------------------------------------------------
|
//---------------------------------------------------------
|
||||||
void cmCTestBatchTestHandler::WriteTestCommand(int test, std::fstream& fout)
|
void cmCTestBatchTestHandler::WriteTestCommand(int test, cmsys::ofstream& fout)
|
||||||
{
|
{
|
||||||
std::vector<std::string> args = this->Properties[test]->Args;
|
std::vector<std::string> args = this->Properties[test]->Args;
|
||||||
std::vector<std::string> processArgs;
|
std::vector<std::string> processArgs;
|
||||||
|
@ -17,6 +17,7 @@
|
|||||||
#include <cmCTestTestHandler.h>
|
#include <cmCTestTestHandler.h>
|
||||||
#include <cmCTestMultiProcessHandler.h>
|
#include <cmCTestMultiProcessHandler.h>
|
||||||
#include <cmCTestRunTest.h>
|
#include <cmCTestRunTest.h>
|
||||||
|
#include <cmsys/FStream.hxx>
|
||||||
|
|
||||||
/** \class cmCTestBatchTestHandler
|
/** \class cmCTestBatchTestHandler
|
||||||
* \brief run parallel ctest
|
* \brief run parallel ctest
|
||||||
@ -30,8 +31,8 @@ public:
|
|||||||
virtual void RunTests();
|
virtual void RunTests();
|
||||||
protected:
|
protected:
|
||||||
void WriteBatchScript();
|
void WriteBatchScript();
|
||||||
void WriteSrunArgs(int test, std::fstream& fout);
|
void WriteSrunArgs(int test, cmsys::ofstream& fout);
|
||||||
void WriteTestCommand(int test, std::fstream& fout);
|
void WriteTestCommand(int test, cmsys::ofstream& fout);
|
||||||
|
|
||||||
void SubmitBatchScript();
|
void SubmitBatchScript();
|
||||||
|
|
||||||
|
@ -319,8 +319,8 @@ void cmCTestMultiProcessHandler::UpdateCostData()
|
|||||||
{
|
{
|
||||||
std::string fname = this->CTest->GetCostDataFile();
|
std::string fname = this->CTest->GetCostDataFile();
|
||||||
std::string tmpout = fname + ".tmp";
|
std::string tmpout = fname + ".tmp";
|
||||||
std::fstream fout;
|
cmsys::ofstream fout;
|
||||||
fout.open(tmpout.c_str(), std::ios::out);
|
fout.open(tmpout.c_str());
|
||||||
|
|
||||||
PropertiesMap temp = this->Properties;
|
PropertiesMap temp = this->Properties;
|
||||||
|
|
||||||
@ -610,8 +610,8 @@ void cmCTestMultiProcessHandler::WriteCheckpoint(int index)
|
|||||||
{
|
{
|
||||||
std::string fname = this->CTest->GetBinaryDir()
|
std::string fname = this->CTest->GetBinaryDir()
|
||||||
+ "/Testing/Temporary/CTestCheckpoint.txt";
|
+ "/Testing/Temporary/CTestCheckpoint.txt";
|
||||||
std::fstream fout;
|
cmsys::ofstream fout;
|
||||||
fout.open(fname.c_str(), std::ios::app | std::ios::out);
|
fout.open(fname.c_str(), std::ios::app);
|
||||||
fout << index << "\n";
|
fout << index << "\n";
|
||||||
fout.close();
|
fout.close();
|
||||||
}
|
}
|
||||||
|
@ -1180,9 +1180,9 @@ cmQtAutoGenerators::WriteOldMocDefinitionsFile(
|
|||||||
cmSystemTools::ConvertToUnixSlashes(filename);
|
cmSystemTools::ConvertToUnixSlashes(filename);
|
||||||
filename += "/AutomocOldMocDefinitions.cmake";
|
filename += "/AutomocOldMocDefinitions.cmake";
|
||||||
|
|
||||||
std::fstream outfile;
|
cmsys::ofstream outfile;
|
||||||
outfile.open(filename.c_str(),
|
outfile.open(filename.c_str(),
|
||||||
std::ios::out | std::ios::trunc);
|
std::ios::trunc);
|
||||||
outfile << "set(AM_OLD_COMPILE_SETTINGS "
|
outfile << "set(AM_OLD_COMPILE_SETTINGS "
|
||||||
<< cmLocalGenerator::EscapeForCMake(
|
<< cmLocalGenerator::EscapeForCMake(
|
||||||
this->CurrentCompileSettingsStr) << ")\n";
|
this->CurrentCompileSettingsStr) << ")\n";
|
||||||
@ -1451,9 +1451,9 @@ bool cmQtAutoGenerators::RunAutogen(cmMakefile* makefile)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// source file that includes all remaining moc files (_automoc.cpp file)
|
// source file that includes all remaining moc files (_automoc.cpp file)
|
||||||
std::fstream outfile;
|
cmsys::ofstream outfile;
|
||||||
outfile.open(this->OutMocCppFilename.c_str(),
|
outfile.open(this->OutMocCppFilename.c_str(),
|
||||||
std::ios::out | std::ios::trunc);
|
std::ios::trunc);
|
||||||
outfile << automocSource;
|
outfile << automocSource;
|
||||||
outfile.close();
|
outfile.close();
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user