diff --git a/Source/cmCommands.cxx b/Source/cmCommands.cxx index cd1b5af822..f71be0da58 100644 --- a/Source/cmCommands.cxx +++ b/Source/cmCommands.cxx @@ -320,8 +320,7 @@ void GetProjectCommands(cmState* state) "output_required_files", cmOutputRequiredFilesCommand, cmPolicies::CMP0032, "The output_required_files command should not be called; see CMP0032."); state->AddDisallowedCommand( - "subdir_depends", cm::make_unique(), - cmPolicies::CMP0029, + "subdir_depends", cmSubdirDependsCommand, cmPolicies::CMP0029, "The subdir_depends command should not be called; see CMP0029."); state->AddDisallowedCommand( "utility_source", cm::make_unique(), diff --git a/Source/cmSubdirDependsCommand.cxx b/Source/cmSubdirDependsCommand.cxx index 0bb2c0ac49..496c60da75 100644 --- a/Source/cmSubdirDependsCommand.cxx +++ b/Source/cmSubdirDependsCommand.cxx @@ -4,8 +4,8 @@ class cmExecutionStatus; -bool cmSubdirDependsCommand::InitialPass(std::vector const&, - cmExecutionStatus&) +bool cmSubdirDependsCommand(std::vector const&, + cmExecutionStatus&) { return true; } diff --git a/Source/cmSubdirDependsCommand.h b/Source/cmSubdirDependsCommand.h index 64c28b9ac0..bf99bd17d8 100644 --- a/Source/cmSubdirDependsCommand.h +++ b/Source/cmSubdirDependsCommand.h @@ -8,21 +8,9 @@ #include #include -#include "cm_memory.hxx" - -#include "cmCommand.h" - class cmExecutionStatus; -class cmSubdirDependsCommand : public cmCommand -{ -public: - std::unique_ptr Clone() override - { - return cm::make_unique(); - } - bool InitialPass(std::vector const& args, - cmExecutionStatus& status) override; -}; +bool cmSubdirDependsCommand(std::vector const& args, + cmExecutionStatus& status); #endif