diff options
author | Brad King <brad.king@kitware.com> | 2019-08-05 14:40:43 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2019-08-05 14:42:50 (GMT) |
commit | 2327cc0e0575175e8dec4b7a6fa6cafd5d0f7ca9 (patch) | |
tree | 0e0ac231e503b95b16112189407c160158def992 /Source/cmMakefile.h | |
parent | c969d4628bff6c5b45c788d3a61fff85c36272f6 (diff) | |
parent | 41364824ad84a40c9906b7b5de492e45a74c8945 (diff) | |
download | CMake-2327cc0e0575175e8dec4b7a6fa6cafd5d0f7ca9.zip CMake-2327cc0e0575175e8dec4b7a6fa6cafd5d0f7ca9.tar.gz CMake-2327cc0e0575175e8dec4b7a6fa6cafd5d0f7ca9.tar.bz2 |
Merge topic 'control-block3'
41364824ad cmFunctionBlocker: Recycle functions
6491270e0d cmFunctionBlocker: Move check for matching args
af24e4ef6e cmFunctionBlocker: Move common logic to base
ef38ff22f7 cm*FunctionBlocker: Extract function Replay
b51fba6298 cmMakefile: Add OnExecuteCommand callback
c76500949d cm*FunctionBlocker: Move to source file
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !3632
Diffstat (limited to 'Source/cmMakefile.h')
-rw-r--r-- | Source/cmMakefile.h | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/Source/cmMakefile.h b/Source/cmMakefile.h index dc196ac..4d61c05 100644 --- a/Source/cmMakefile.h +++ b/Source/cmMakefile.h @@ -107,8 +107,7 @@ public: * Remove the function blocker whose scope ends with the given command. * This returns ownership of the function blocker object. */ - std::unique_ptr<cmFunctionBlocker> RemoveFunctionBlocker( - cmFunctionBlocker* fb, const cmListFileFunction& lff); + std::unique_ptr<cmFunctionBlocker> RemoveFunctionBlocker(); /** * Try running cmake and building a file. This is used for dynalically @@ -628,6 +627,11 @@ public: void PrintCommandTrace(const cmListFileFunction& lff) const; /** + * Set a callback that is invoked whenever ExecuteCommand is called. + */ + void OnExecuteCommand(std::function<void()> callback); + + /** * Execute a single CMake command. Returns true if the command * succeeded or false if it failed. */ @@ -964,6 +968,7 @@ private: bool EnforceUniqueDir(const std::string& srcPath, const std::string& binPath) const; + std::function<void()> ExecuteCommandCallback; using FunctionBlockerPtr = std::unique_ptr<cmFunctionBlocker>; using FunctionBlockersType = std::stack<FunctionBlockerPtr, std::vector<FunctionBlockerPtr>>; |