Shared object library that uses another shared object library
I have a project I'm working on that makes a shared object library (.so) containing its code that I am using in another project. I would like to be able to split up the first project into several shared object files so that I don't have to bring all of it into another project when I only need one or two classes from it.
The problem I'm running into now is that some of the classes in one shared library now requires code from the other shared library. Each shared library builds and installs just fine. My other project needs both shared libraries. When I go to build the project, make tells me that there are undefined references to things in the smaller shared object that are being called in the bigger shared object.
I'm not sure where the problem is, since I've specified both libraries in the LIBS variable in the makefile. Is there a way to have a shared object library that uses code in another shared object library?