Message200889
| Author |
automatthias |
| Recipients |
automatthias, jcea |
| Date |
2013年10月22日.07:52:39 |
| SpamBayes Score |
-1.0 |
| Marked as misclassified |
Yes |
| Message-id |
<1382428359.83.0.283963752576.issue19317@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
The specific case that breaks for me is this:
OpeCSW Python package includes:
/opt/csw/bin/python2.6 (also 2.7, 3.3, etc)
/opt/csw/lib/libpython2.6.so.1.0
(other files)
On the operating system there is only:
/usr/lib/libpython2.4.so.1.0
Let's say there's libmagic installed in /opt/csw/lib, and there's no libmagic in /usr/lib. Let's suppose you run this:
ctypes.cdll.LoadLibrary('libmagic.so.1')
The OpenCSW Python will successfully load libmagic.so.1. But without the patch, find_library will not find libmagic.so.1, it will fail to translate 'magic' to 'libmagic.so.1', even though the libmagic.so symlink is present in /opt/csw/lib.
For the patch, the RPATH of the library itself doesn't matter, the important one is the RPATH of the Python executable itself, which influences what _ctypes.dlopen() does when looking for a library.
I could write a test by providing providing a sample /usr/ccs/bin/dump output and mocking out some libraries. Would that be good? |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2013年10月22日 07:52:39 | automatthias | set | recipients:
+ automatthias, jcea |
| 2013年10月22日 07:52:39 | automatthias | set | messageid: <1382428359.83.0.283963752576.issue19317@psf.upfronthosting.co.za> |
| 2013年10月22日 07:52:39 | automatthias | link | issue19317 messages |
| 2013年10月22日 07:52:39 | automatthias | create |
|