c++linuxgentooldd

How to find out what tries to load libmysqlclient_r.so library


I am using clang-9 with mysql-connector-c++8.

After mysql-connector-c++ upgrade from 1.1.12 to 8.x and running function in my app: get_driver_instance() an exception is being thrown:

"Couldn't load library libmysqlclient_r.so: libmysqlclient_r.so: cannot open shared object file"

What I've tried so far:

There are no errors during compilation. I've got out of ideas what might be wrong. What might I do to diagnose it further?


Solution

  • Runtime dlopen calls will not produce any output in ldd, but you can convince ld.so to print when a library is loaded by whom by setting the environment variable LD_DEBUG=files.