diff options
Diffstat (limited to 'Source/cmFindCommon.cxx')
-rw-r--r-- | Source/cmFindCommon.cxx | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/Source/cmFindCommon.cxx b/Source/cmFindCommon.cxx index 2a33bbb..82acfed 100644 --- a/Source/cmFindCommon.cxx +++ b/Source/cmFindCommon.cxx @@ -11,8 +11,10 @@ #include "cmExecutionStatus.h" #include "cmMakefile.h" +#include "cmMessageType.h" #include "cmStringAlgorithms.h" #include "cmSystemTools.h" +#include "cmake.h" cmFindCommon::PathGroup cmFindCommon::PathGroup::All("ALL"); cmFindCommon::PathLabel cmFindCommon::PathLabel::PackageRoot( @@ -53,6 +55,8 @@ cmFindCommon::cmFindCommon(cmExecutionStatus& status) this->SearchAppBundleLast = false; this->InitializeSearchPathGroups(); + + this->DebugMode = false; } void cmFindCommon::SetError(std::string const& e) @@ -60,6 +64,19 @@ void cmFindCommon::SetError(std::string const& e) this->Status.SetError(e); } +void cmFindCommon::DebugMessage(std::string const& msg) const +{ + if (this->Makefile) { + this->Makefile->IssueMessage(MessageType::LOG, msg); + } +} + +bool cmFindCommon::ComputeIfDebugModeWanted() +{ + return this->Makefile->IsOn("CMAKE_FIND_DEBUG_MODE") || + this->Makefile->GetCMakeInstance()->GetDebugFindOutput(); +} + void cmFindCommon::InitializeSearchPathGroups() { std::vector<PathLabel>* labels; |