assume I extend a C++ function to python by creating libA.so, but libA.so depends also on another shared library libB.so. I want to distribute libA.so to a final user in a way that it already contains (embeds) libB.so, i.e. the final user does not need to obtain libB.so or to set his/her LD_LIBRARY_PATH to point to the folder containing libB.so (in the case this library is present in the final user's file system).
So basically I want to create a shared library libA.so which does not refer to any other (static or shared) library.
Question 1: Is there a way to do this in linux?
Question 2: Can this be done by configuring a python setup script based on distutils.core? (probably question 1 will also provide the answer to this)
Thanks