user23517194
user23517194

Reputation: 1

Emacs flycheck lsp include paths

I use LSP for code completion with Emacs for C++ development. My project is quite big and has few 1000s of source files. I have generated compile_commands.json, but using flycheck-compile explicitly doesn't help it to get the custom include paths & pre-processor macros.

Have worked around this by including custom include paths & macros using .dir-locals.el inside project root area. This requires mentioning the include paths explicitly.

However, I feel there must be a way to find the include paths & macros through lsp itself. How can I let flycheck use lsp to get these info rather than depending on .dir-locals.el ? This way an extra management for .dir-locals won't be required.

Tried flycheck-compile in Emacs for C++.

Upvotes: 0

Views: 100

Answers (0)

Related Questions