shared library search path
ndbecker2 at gmail.com
Thu Nov 3 15:21:13 CET 2005
Stefan Arentz wrote:
> Hi. I've wrapped a C++ class with Boost.Python and that works great. But,
> I am now packaging my application so that it can be distributed. The
> structure is basically this:
> In foo.py I do the following:
> sys.path.append(os.path.dirname(sys.path) + '/lib')
> and this allows foo.py to import bar. Great.
> But, the foo.so cannot be imported. The import only succeeds if I place
> foo.so next to foo.py in the bin directory.
> I searched through the 2.4.2 documentation on python.org but I can't find
> a proper explanation on how the shared library loader works.
> Does anyone understand what it going on here?
No, but here is the code I use:
More information about the Python-list