Retrieving Appropriate Headers

Hi,

Regarding the problem I exposed, I found the next tutorial:

https://github.com/loarabia/Clang-tutorial/blob/master/tutorial6.cpp

In that tutorial, they use the option:

headerSearchOptions->AddPath(“/usr/include/linux”,
clang::frontend::Angled,
false, false);

But:
1- I don’t know if this is what I’m looking for (how could my tool know that a header file like "<name_x/file.h> is in a path which does not even has the directory “name_x” in it?)
2- I don’t know how can I adapt this code to my tool, as I don’t use anything similar to:

clang::ParseAST(preprocessor,&astConsumer,astContext);

Can anyone give me a clue to solve this?