ivanmurashko added a comment.

> Can this be solved at the build-system level, without changing the source 
> code in ways that aren't otherwise useful?
> For example, with a `CLANG_TIDY_EXTRA_CHECKS` cmake variable that adds more 
> deps? This seems like it could also work for the `clang-tidy` binary.

As it was mentioned at D145228 <https://reviews.llvm.org/D145228>, we use LLVM 
as a set of libraries and headers that allow us to create custom components. 
The build system we use for the component is different from CMake (it's buck). 
Thus, unfortunately, the CMake customization does not work for us.

> IIUC we want to link some extra targets into the `clangd` binary in order to 
> provide extra clang-tidy checks, but *don't* want to customize the binary 
> further.
> (The latter can be useful, but this interface isn't sufficient for it).

I agree that the current interface does not provide any way to customize the 
binary. My primary reason was the following: I tried to keep the changes as 
minimal as possible to get an ability to build the clangd outside LLVM repo. I 
assumed that additional customization API can be added later as soon as it is 
be required.

BTW: I added the copy of the single header file (API) instead of copying all 
internal headers. That will allow to abandon D145228 
<https://reviews.llvm.org/D145228> and add future external API at the select 
set of headers in future.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D145302/new/

https://reviews.llvm.org/D145302

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to