So you have an executable and a shared library. The library exports symbols to be used by the executable.
But you also want the library to access a symbol from the executable. This is called 'reverse dependency' and your executable must also export the symbol. This can be done by using the
--export-dynamic
linker option. See also section 3.4. Creating a Shared Library of the
Program Library HOWTO[
^].