This GCC is problematic for using with clangd language server #385
Closed
super-betonamu-jin
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
This is my conclusion after spending days trying to figure out what’s going on. Based on the output of
gcc -E -v, I found that the header paths are duplicated and redirected through multiple levels of relative paths. The output on other GCC versions is much clearer.I previously thought
clangdwas buggy and that I needed to manually specify--sysrootand-isystemfor CMake to include them incompile_commands.json, since it doesn’t do so by default. However, the output ofgcc -E -vpuzzled me. Later I discovered that Premake5 does include-isystemin thecompile_commands.jsonit generates. I quickly wrote apremake5.luaand tested it. Even when I made everything as conformant as possible,clangdstill complained that the path incompile_commands.jsonwas invalid, which validated my earlier speculation.Beta Was this translation helpful? Give feedback.
All reactions