diff options
author | Brad King <brad.king@kitware.com> | 2006-10-04 19:24:26 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2006-10-04 19:24:26 (GMT) |
commit | 2dfa2ba888bb3f1ea5dd5eedf84a3c5b23bdb202 (patch) | |
tree | 91630ef8018256a23451bbdba07436c2374732ea /Source/cmCustomCommand.cxx | |
parent | 523075ded543cbb7044bc4b56203d329aff0cb42 (diff) | |
download | CMake-2dfa2ba888bb3f1ea5dd5eedf84a3c5b23bdb202.zip CMake-2dfa2ba888bb3f1ea5dd5eedf84a3c5b23bdb202.tar.gz CMake-2dfa2ba888bb3f1ea5dd5eedf84a3c5b23bdb202.tar.bz2 |
ENH: Added APPEND option to ADD_CUSTOM_COMMAND to allow extra dependencies to be connected later. This is useful to create one rule and then have a macro add things to it later. This addresses bug#2151.
Diffstat (limited to 'Source/cmCustomCommand.cxx')
-rw-r--r-- | Source/cmCustomCommand.cxx | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/Source/cmCustomCommand.cxx b/Source/cmCustomCommand.cxx index e3fc69a..c070174 100644 --- a/Source/cmCustomCommand.cxx +++ b/Source/cmCustomCommand.cxx @@ -95,6 +95,26 @@ const char* cmCustomCommand::GetComment() const } //---------------------------------------------------------------------------- +void cmCustomCommand::AppendCommands(const cmCustomCommandLines& commandLines) +{ + for(cmCustomCommandLines::const_iterator i=commandLines.begin(); + i != commandLines.end(); ++i) + { + this->CommandLines.push_back(*i); + } +} + +//---------------------------------------------------------------------------- +void cmCustomCommand::AppendDepends(const std::vector<std::string>& depends) +{ + for(std::vector<std::string>::const_iterator i=depends.begin(); + i != depends.end(); ++i) + { + this->Depends.push_back(*i); + } +} + +//---------------------------------------------------------------------------- bool cmCustomCommand::GetEscapeOldStyle() const { return this->EscapeOldStyle; |