By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
432,306 Members | 1,621 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 432,306 IT Pros & Developers. It's quick & easy.

symbol not found involving dynlink/dlopen/embedding Python

P: n/a
With the following situation, Numarray can't find Python's symbols.

problematic-Python::
Main dlopens Two
Two dynlinks Python
Python dlopens Numarray
Numarray dynlinks Python

I have another pure-C example that tries to mirror this, with::

minimal-C::
Main dlopen Two
Two dynlink Middle
Middle dlopen Three
Three dynlink Middle

and it works fine.

AFAICT, I'm using the same dlopen flags that Python is.

The minimal reproduction code is very small, but broken into several
files (to emulate the different parts). It's browsable at
http://twistedmatrix.com/users/radix/dynlink-problem , and
downloadable at
http://twistedmatrix.com/users/radix...problem.tar.gz

After doing some googling, I've found several people that look like
they have similar problems. I even found one workaround involving
LD_PRELOAD. if you LD_PRELOAD=python2.3.so ./main, then the symbols
are found.

Does anyone have any idea on how I can solve this? I'd like to not
hack CPython, and not have tie the build to a single machine.

--
Twisted | Christopher Armstrong: International Man of Twistery
Radix | -- http://radix.twistedmatrix.com
| Release Manager, Twisted Project
\\\V/// | -- http://twistedmatrix.com
|o O| | Founding Member, Hobart Hacking Society
w----v----w-+ -- http://hackingsociety.org/chapters/hash
Jul 18 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.