I have a side project I am working on, which is a port of a game engine. This creates a SObj library (.so) and an executable that uses it.
I managed to build everything, but as soon as I ran the executable, this crashes with a complaint about accessing a symbol.
I believe that the problem is because of mixing shared and static libraries, some of them might not be compiled with -fPIC. I might need to rebuild all the libraries with -fPIC just to be sure, but...
I tried different things and I still get the same error. The last thing I tried was to build the .so library with all the needed libraries linked statically, and then use that with the main executable linked dynamically. When I did that, it still required some of the other libraries to be linked again, so I did that dynamically. And then I got the same error.
My questions are:
1. Does it make sense to try and create the .so with the required libraries statically linked?
2. Do you have any other ideas to solve that issue?