How call other lib functions in a pass?

I modify the Makefile, and it is not a problem. :slight_smile:

My pass has to call one function of a binary library. But when opt loads my pass, it tells me that the function is "undefined symbol".

I copy the library to /usr/lib, and run ldconfig, but this is unuseful.

Should I modify the Makefile? :frowning:





That's not the best way to deal with it. The opt program can dynamically
load your pass, if its compiled to a shared object. See the manual page
for opt and in particular the -load option: