-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add specific dependency handling for clang #13134
base: master
Are you sure you want to change the base?
Conversation
81506a3
to
ab5966d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks pretty reasonable so far.
docs/markdown/Dependencies.md
Outdated
Both libclang (the C interface) and the C++ interfaces are supported via the | ||
`language` keyword. The default is to search for the `C++` interface. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't understand why we can't do this for Rust dependencies, @xclaesse.
/cc @thesamesam |
f65099e
to
9a5107e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks solid.
ed30059
to
287c36b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for doing this, this looks good to me.
287c36b
to
25c9116
Compare
Now for the fun of getting the CI green. |
7c967db
to
e2718dc
Compare
59050cc
to
87afe53
Compare
f81683b
to
834ef61
Compare
This check considers whether `-l{libname}` will find the lib correctly, and that is true if library *must* be shared as well as if the library should be shared, but can fall back to static.
…with modules I don't understand why these wouldn't be used for modules if they exist, and this breaks Clang, which only sets a global Clang_INCLUDE_DIRS, and doesn't provide per-module support.
Clang has two ways to be found, CMake, and by hand. Clang has some hurdles of use because of the way it's installed on many Linux distros, either in a separate prefix, in a prefix with LLVM, or in a common prefix, which requires some amount of effort to make it work.
834ef61
to
6d6a0e8
Compare
Clang is fun. It has a C API library and C++ API libraries. It has the following configurations that need to be accounted for:
On top of that, to get the Clang Version for the C API you need to resort to some trickery. I've checked the implementation I came up with for clang 6-17 and it works for all of those. For the C++ API it's easy, because the header required is a C++ header.
TODO: