summaryrefslogtreecommitdiffstats
path: root/Source/CTest/cmCTestConfigureCommand.cxx
diff options
context:
space:
mode:
authorVitaly Stakhovsky <vvs31415@gitlab.org>2020-07-27 15:00:00 (GMT)
committerVitaly Stakhovsky <vvs31415@gitlab.org>2020-07-27 14:58:39 (GMT)
commit825b04c67ac7ff3f759fd474e9a16b3b6076d591 (patch)
tree5b212042a645c3dba30c725b91137ebd870ce59c /Source/CTest/cmCTestConfigureCommand.cxx
parent7788494257e0a1a22468b5542f9d8c5cb8c3dfed (diff)
downloadCMake-825b04c67ac7ff3f759fd474e9a16b3b6076d591.zip
CMake-825b04c67ac7ff3f759fd474e9a16b3b6076d591.tar.gz
CMake-825b04c67ac7ff3f759fd474e9a16b3b6076d591.tar.bz2
cmCTest: Members accept std::string parameters
Diffstat (limited to 'Source/CTest/cmCTestConfigureCommand.cxx')
-rw-r--r--Source/CTest/cmCTestConfigureCommand.cxx19
1 files changed, 10 insertions, 9 deletions
diff --git a/Source/CTest/cmCTestConfigureCommand.cxx b/Source/CTest/cmCTestConfigureCommand.cxx
index f42c3f1..8716b31 100644
--- a/Source/CTest/cmCTestConfigureCommand.cxx
+++ b/Source/CTest/cmCTestConfigureCommand.cxx
@@ -12,6 +12,7 @@
#include "cmCTestConfigureHandler.h"
#include "cmGlobalGenerator.h"
#include "cmMakefile.h"
+#include "cmProperty.h"
#include "cmStringAlgorithms.h"
#include "cmSystemTools.h"
#include "cmake.h"
@@ -38,12 +39,12 @@ cmCTestGenericHandler* cmCTestConfigureCommand::InitializeHandler()
return nullptr;
}
- const char* ctestConfigureCommand =
- this->Makefile->GetDefinition("CTEST_CONFIGURE_COMMAND");
+ cmProp ctestConfigureCommand =
+ this->Makefile->GetDef("CTEST_CONFIGURE_COMMAND");
- if (ctestConfigureCommand && *ctestConfigureCommand) {
+ if (cmNonempty(ctestConfigureCommand)) {
this->CTest->SetCTestConfiguration("ConfigureCommand",
- ctestConfigureCommand, this->Quiet);
+ *ctestConfigureCommand, this->Quiet);
} else {
const char* cmakeGeneratorName =
this->Makefile->GetDefinition("CTEST_CMAKE_GENERATOR");
@@ -125,8 +126,8 @@ cmCTestGenericHandler* cmCTestConfigureCommand::InitializeHandler()
cmakeConfigureCommand += source_dir;
cmakeConfigureCommand += "\"";
- this->CTest->SetCTestConfiguration(
- "ConfigureCommand", cmakeConfigureCommand.c_str(), this->Quiet);
+ this->CTest->SetCTestConfiguration("ConfigureCommand",
+ cmakeConfigureCommand, this->Quiet);
} else {
this->SetError(
"Configure command is not specified. If this is a "
@@ -136,10 +137,10 @@ cmCTestGenericHandler* cmCTestConfigureCommand::InitializeHandler()
}
}
- if (const char* labelsForSubprojects =
- this->Makefile->GetDefinition("CTEST_LABELS_FOR_SUBPROJECTS")) {
+ if (cmProp labelsForSubprojects =
+ this->Makefile->GetDef("CTEST_LABELS_FOR_SUBPROJECTS")) {
this->CTest->SetCTestConfiguration("LabelsForSubprojects",
- labelsForSubprojects, this->Quiet);
+ *labelsForSubprojects, this->Quiet);
}
cmCTestConfigureHandler* handler = this->CTest->GetConfigureHandler();