mod_python - problem with dynamic loading

Andrew Csillag andrew at starmedia.net
Tue May 4 11:01:01 EDT 1999


Oleg Broytmann wrote:
> 
> Hello!
> 
>    I need an advice from guru who understands shared libraries issues.
> 
>    I have Python 1.5.1, Apache 1.3.4 and PyApache 4.14.
>    Initially I ran all this on Sun, Solaris 2.5.1. All worked pretty good.
> Then I tried to move things to linux, but I experienced many troubles.
..snip..

When you link apache, you need to add a command-line switch to export
all of it's symbols to be available to loaded shared objects (so the
.so's can see python symbols).  I think it's -rdynamic or -Bshareable
(or something like that, I've been in FreeBSD land for a while.  The ld
man page will say which it is).

The other alternative is to compile your python installation statically
(instead of using dynamic modules (.so's)), but the linker switch is
probably what you want. 

BTW: you may have to pass the linker switch to gcc as -Xlinker
<linkerswitch> or something like that (like I said, it's been a while). 
Of course the gcc man page on this is more authoritative.
-- 
"There are two major products that come out of Berkeley: 
LSD and UNIX. We don't believe this to be a coincidence." 
- Jeremy S. Anderson




More information about the Python-list mailing list