diff options
Diffstat (limited to 'Source/cmQTWrapUICommand.cxx')
-rw-r--r-- | Source/cmQTWrapUICommand.cxx | 33 |
1 files changed, 20 insertions, 13 deletions
diff --git a/Source/cmQTWrapUICommand.cxx b/Source/cmQTWrapUICommand.cxx index f98f0b3..8b2a42c 100644 --- a/Source/cmQTWrapUICommand.cxx +++ b/Source/cmQTWrapUICommand.cxx @@ -2,10 +2,14 @@ file Copyright.txt or https://cmake.org/licensing for details. */ #include "cmQTWrapUICommand.h" +#include <utility> + +#include <cm/memory> + +#include "cmCustomCommand.h" #include "cmCustomCommandLines.h" #include "cmExecutionStatus.h" #include "cmMakefile.h" -#include "cmPolicies.h" #include "cmRange.h" #include "cmSourceFile.h" #include "cmStringAlgorithms.h" @@ -84,23 +88,26 @@ bool cmQTWrapUICommand(std::vector<std::string> const& args, std::vector<std::string> depends; depends.push_back(uiName); - std::string no_main_dependency; - const char* no_comment = nullptr; - const char* no_working_dir = nullptr; - mf.AddCustomCommandToOutput(hName, depends, no_main_dependency, - hCommandLines, no_comment, no_working_dir, - mf.GetPolicyStatus(cmPolicies::CMP0116)); + auto cc = cm::make_unique<cmCustomCommand>(); + cc->SetOutputs(hName); + cc->SetDepends(depends); + cc->SetCommandLines(hCommandLines); + mf.AddCustomCommandToOutput(std::move(cc)); depends.push_back(hName); - mf.AddCustomCommandToOutput(cxxName, depends, no_main_dependency, - cxxCommandLines, no_comment, no_working_dir, - mf.GetPolicyStatus(cmPolicies::CMP0116)); + cc = cm::make_unique<cmCustomCommand>(); + cc->SetOutputs(cxxName); + cc->SetDepends(depends); + cc->SetCommandLines(cxxCommandLines); + mf.AddCustomCommandToOutput(std::move(cc)); depends.clear(); depends.push_back(hName); - mf.AddCustomCommandToOutput(mocName, depends, no_main_dependency, - mocCommandLines, no_comment, no_working_dir, - mf.GetPolicyStatus(cmPolicies::CMP0116)); + cc = cm::make_unique<cmCustomCommand>(); + cc->SetOutputs(mocName); + cc->SetDepends(depends); + cc->SetCommandLines(mocCommandLines); + mf.AddCustomCommandToOutput(std::move(cc)); } } |