You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For ExternalProject-based CMake superbuild, one might have a lot of compile_commands.json files placed in different directories, which might not respect the project set up of clangd.
In VScode one could use CMakeTools extension to merge all these compile_commands.json files into a unique one by setting the following option:
I noticed your use of ${workspaceFolder} in the clangd.arguments. Does that currently work for you (minus the "merged" part)?
I ask because using named workspaces in there does not. (eg. replace yours with ${workspaceFolder:<name>}/<...>
I noticed your use of ${workspaceFolder} in the clangd.arguments. Does that currently work for you (minus the "merged" part)? I ask because using named workspaces in there does not. (eg. replace yours with ${workspaceFolder:<name>}/<...>
${workspaceFolder} works because its substitution has been manually implemented in vscode-clangd.
There is no comparable implementation of ${workspaceFolder:<name>}, though I imagine a patch to add that would be welcome. (Even better would be to call into some sort of VSCode API to automatically handle all the variable substitutions that VSCode itself handles, if such a thing exists.)
For ExternalProject-based CMake superbuild, one might have a lot of
compile_commands.json
files placed in different directories, which might not respect the project set up of clangd.In VScode one could use
CMakeTools
extension to merge all thesecompile_commands.json
files into a unique one by setting the following option:In this case for example, the merged file is called
merged_compile_commands.json
to distinguish it from the othercompile_commands.json
files.Though, this new file is not found by
clangd
when setting the following option:It would be helpful to have an option like
--compile-commands-file
that one could set as follows:The text was updated successfully, but these errors were encountered: