diff options
author | Adam Strzelecki <ono@java.pl> | 2014-06-27 20:13:52 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2014-06-30 13:33:37 (GMT) |
commit | 93371ed592b85ccc179845dbd6e6018ca2193659 (patch) | |
tree | 7a43634f2c71a9e866c724c334eeececc0cf726b /Source/cmNinjaTargetGenerator.h | |
parent | 7243c95129fd8cd0d01495d33848663c796f91db (diff) | |
download | CMake-93371ed592b85ccc179845dbd6e6018ca2193659.zip CMake-93371ed592b85ccc179845dbd6e6018ca2193659.tar.gz CMake-93371ed592b85ccc179845dbd6e6018ca2193659.tar.bz2 |
Ninja: Skip generating empty phony rules
Ninja generator ensures that all custom commands being target
dependencies are run before other source compilations. However in case
there are no such dependencies it currently generates empty phony rules
which clutter the build graph.
Teach the Ninja generator to produce such rules only when necessary.
Diffstat (limited to 'Source/cmNinjaTargetGenerator.h')
-rw-r--r-- | Source/cmNinjaTargetGenerator.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Source/cmNinjaTargetGenerator.h b/Source/cmNinjaTargetGenerator.h index 94c420f..40a15a3 100644 --- a/Source/cmNinjaTargetGenerator.h +++ b/Source/cmNinjaTargetGenerator.h @@ -114,7 +114,8 @@ protected: void WriteLanguageRules(const std::string& language); void WriteCompileRule(const std::string& language); void WriteObjectBuildStatements(); - void WriteObjectBuildStatement(cmSourceFile const* source); + void WriteObjectBuildStatement(cmSourceFile const* source, + bool writeOrderDependsTargetForTarget); void WriteCustomCommandBuildStatement(cmCustomCommand *cc); cmNinjaDeps GetObjects() const |