Introduce new tool: -t compdb-targets

Fixes #1544

Co-authored-by: Linkun Chen <lkchen@google.com>
Co-authored-by: csmoe <csmoe@msn.com>
Co-authored-by: James Widman <james.widman@gmail.com>
This commit is contained in:
James Widman
2024-10-04 16:45:44 -07:00
parent fc2f81e072
commit 4e4ec4c8ab
7 changed files with 386 additions and 62 deletions

View File

@@ -289,6 +289,11 @@ http://clang.llvm.org/docs/JSONCompilationDatabase.html[JSON format] expected
by the Clang tooling interface.
_Available since Ninja 1.2._
`compdb-targets`:: like `compdb`, but takes a list of targets instead of rules,
and expects at least one target. The resulting compilation database contains
all commands required to build the indicated targets, and _only_ those
commands.
`deps`:: show all dependencies stored in the `.ninja_deps` file. When given a
target, show just the target's dependencies. _Available since Ninja 1.4._