diff options
author | Alex Neundorf <neundorf@kde.org> | 2011-09-15 14:20:33 (GMT) |
---|---|---|
committer | Alex Neundorf <neundorf@kde.org> | 2011-09-15 14:20:33 (GMT) |
commit | 31f43fdb5af80029bc644bffd853c81a25424623 (patch) | |
tree | ed89871c2d104a8b84067fdb4cce632c43578638 /Source/cmTryRunCommand.cxx | |
parent | 98d5623a7b809a8d730fd197412935b52f234e7d (diff) | |
download | CMake-31f43fdb5af80029bc644bffd853c81a25424623.zip CMake-31f43fdb5af80029bc644bffd853c81a25424623.tar.gz CMake-31f43fdb5af80029bc644bffd853c81a25424623.tar.bz2 |
Remove trailing whitespace
Alex
Diffstat (limited to 'Source/cmTryRunCommand.cxx')
-rw-r--r-- | Source/cmTryRunCommand.cxx | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/Source/cmTryRunCommand.cxx b/Source/cmTryRunCommand.cxx index c9c4ed5..ce402a8 100644 --- a/Source/cmTryRunCommand.cxx +++ b/Source/cmTryRunCommand.cxx @@ -49,8 +49,8 @@ bool cmTryRunCommand { tryCompile.push_back(argv[i]); } - } - else + } + else { if (argv[i] == "OUTPUT_VARIABLE") { @@ -94,8 +94,8 @@ bool cmTryRunCommand // although they could be used together, don't allow it, because // using OUTPUT_VARIABLE makes crosscompiling harder - if (this->OutputVariable.size() - && ((this->RunOutputVariable.size()) + if (this->OutputVariable.size() + && ((this->RunOutputVariable.size()) || (this->CompileOutputVariable.size()))) { cmSystemTools::Error( @@ -141,8 +141,8 @@ bool cmTryRunCommand std::string runOutputContents; if (this->Makefile->IsOn("CMAKE_CROSSCOMPILING")) { - this->DoNotRunExecutable(runArgs, - argv[3], + this->DoNotRunExecutable(runArgs, + argv[3], captureRunOutput ? &runOutputContents : 0); } else @@ -153,7 +153,7 @@ bool cmTryRunCommand // now put the output into the variables if(this->RunOutputVariable.size()) { - this->Makefile->AddDefinition(this->RunOutputVariable.c_str(), + this->Makefile->AddDefinition(this->RunOutputVariable.c_str(), runOutputContents.c_str()); } @@ -167,7 +167,7 @@ bool cmTryRunCommand { runOutputContents = std::string(compileOutput) + runOutputContents; } - this->Makefile->AddDefinition(this->OutputVariable.c_str(), + this->Makefile->AddDefinition(this->OutputVariable.c_str(), runOutputContents.c_str()); } } @@ -212,9 +212,9 @@ void cmTryRunCommand::RunExecutable(const std::string& runArgs, /* This is only used when cross compiling. Instead of running the executable, two cache variables are created which will hold the results - the executable would have produced. + the executable would have produced. */ -void cmTryRunCommand::DoNotRunExecutable(const std::string& runArgs, +void cmTryRunCommand::DoNotRunExecutable(const std::string& runArgs, const std::string& srcFile, std::string* out ) @@ -249,7 +249,7 @@ void cmTryRunCommand::DoNotRunExecutable(const std::string& runArgs, comment += "Run result of TRY_RUN(), indicates whether the executable " "would have been able to run on its target platform.\n"; comment += detailsString; - this->Makefile->AddCacheDefinition(this->RunResultVariable.c_str(), + this->Makefile->AddCacheDefinition(this->RunResultVariable.c_str(), "PLEASE_FILL_OUT-FAILED_TO_RUN", comment.c_str(), cmCacheManager::STRING); @@ -276,7 +276,7 @@ void cmTryRunCommand::DoNotRunExecutable(const std::string& runArgs, "would have printed on stdout and stderr on its target platform.\n"; comment += detailsString; - this->Makefile->AddCacheDefinition(internalRunOutputName.c_str(), + this->Makefile->AddCacheDefinition(internalRunOutputName.c_str(), "PLEASE_FILL_OUT-NOTFOUND", comment.c_str(), cmCacheManager::STRING); @@ -294,7 +294,7 @@ void cmTryRunCommand::DoNotRunExecutable(const std::string& runArgs, if (error) { static bool firstTryRun = true; - std::ofstream file(resultFileName.c_str(), + std::ofstream file(resultFileName.c_str(), firstTryRun ? std::ios::out : std::ios::app); if ( file ) { |