diff options
author | Brendan Jackman <jackmanb@google.com> | 2024-05-16 19:40:53 +0000 |
---|---|---|
committer | Shuah Khan <skhan@linuxfoundation.org> | 2024-09-12 09:52:36 -0600 |
commit | e4835f1da425fbc75e37ce8258c9927170de5bfe (patch) | |
tree | 41d77c2fdf43c07dd3c70ba6aeb41315eb2961ca /lib/bitmap-str.c | |
parent | a4311c274e08001b129bd5ffd2a41dcbd3e0a855 (diff) |
kunit: tool: Build compile_commands.json
compile_commands.json is used by clangd[1] to provide code navigation
and completion functionality to editors. See [2] for an example
configuration that includes this functionality for VSCode.
It can currently be built manually when using kunit.py, by running:
./scripts/clang-tools/gen_compile_commands.py -d .kunit
With this change however, it's built automatically so you don't need to
manually keep it up to date.
Unlike the manual approach, having make build the compile_commands.json
means that it appears in the build output tree instead of at the root of
the source tree, so you'll need to add --compile-commands-dir=.kunit to
your clangd args for it to be found. This might turn out to be pretty
annoying, I'm not sure yet. If so maybe we can later add some hackery to
kunit.py to work around it.
[1] https://clangd.llvm.org/
[2] https://github.com/FlorentRevest/linux-kernel-vscode
Signed-off-by: Brendan Jackman <jackmanb@google.com>
Reviewed-by: Nathan Chancellor <nathan@kernel.org>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
Diffstat (limited to 'lib/bitmap-str.c')
0 files changed, 0 insertions, 0 deletions