Identifying function calls made to a library

Hi Guys,

I am trying to identify all the function calls made to a particular library. While visiting all the statements in the Clang AST, I can find the “CallExpr” but I don’t know how I can figure out if the callee belongs to a particular library.

What characteristics a callee belonging to a library will have? Is there even a way to distinguish a callee in a library from a callee defined in the same source file? Please let me know.

Thanks a lot !