3 ms·
> Meson automatically generates compile_commands.json, which can be consumed by clangd to provide a LSP server for any editor. Wait, what now? Where can I lea
by carapace 7y ago
> Meson automatically generates compile_commands.json, which can be consumed by clangd to provide a LSP server for any editor.
Wait, what now? Where can I learn more of this strange magic?
- Memosyne 7y agoThe compile_commands.json is the compilation database used by clang tools[1]. If you use CMake, enabling CMAKE_EXPORT_COMPILE_COMMANDS basically does the same thing[2]. 1 - https://clang.llvm.org/docs/JSONCompilationDatabase.html https://clang.llvm.org/docs/JSONCompilationDatabase.html 2 - https://cmake.org/cmake/help/latest/variable/CMAKE_EXPORT_COMPILE_COMMANDS.html https://cmake.org/cmake/help/latest/variable/CMAKE_EXPORT_CO...
- carapace 7y agoThank you!