[mod_python] Point of frustration/disappointment

Jim Popovitch jimpop at yahoo.com
Thu Jul 28 21:18:10 EDT 2005


On Thu, 2005-07-28 at 19:44 -0400, Jim Popovitch wrote:
> On Fri, 2005-07-29 at 09:20 +1000, Graham Dumpleton wrote:
> > On 29/07/2005, at 9:10 AM, Jim Popovitch wrote:
> > >
> > > It doesn't.
> > >
> > > $ PYTHON_BIN=/usr/bin/python2.2 ./configure
> > > ...
> > > checking for --with-python... no
> > > checking for python... (cached) /usr/bin/python
> > > checking Python version... 1.5
> > > checking whether Python is compiled with thread support... yes
> > > ....
> > 
> > Run:
> > 
> >    make distclean
> > 
> > It looks like you are rerunning configure when there is already a
> > cached set of values from running configure a previous time where
> > it picked up the version of Python you don't want. Ie., you don't
> > want to see "(cached)".
> 
> Ahhh, good eyes.  Yes, this does work then, at least it now configures
> cleanly.  Here are my notes:
> 
>  systems have:
>    apache      1.3  
>    python      1.5  (primarily for yum)
>    python2     2.2  (exists for Mailman)
> 
>  adding:
>    mod_python  2.7.8 (from Fedora Legacy RH7.3 repository)
>   
>    download SRPM mod_python-2.7.8-1.7.3.2.legacy.src.rpm
>    manually extract, and manually apply included patches
> 
>    configure mod_python with:
>    $PYTHON_BIN=/usr/bin/python2.2 ./configure --with-apxs=/usr/sbin/apxs
>    
>    in order to 'make' the Makefile and other pieces still need
>    for /usr/bin/python to be v2.2.  /usr/bin/python is a hard-link
>    to /usr/bin/python1.5 (just as /usr/bin/python2 is a hard-link
>    to /usr/bin/python2.2). To get around this we replace the existing
>    /usr/bin/python with a hard-link to the python2.2 binary.
> 
>    $rm -f /usr/bin/python; ln /usr/bin/python2.2 /usr/bin/python
> 
>    now we can compile and install successfully.
>    
>    $make OPT="`/usr/sbin/apxs -q CFLAGS` -fPIC"
>    $make install
> 
> 
> Hope this helps someone, please email me if it ever does.
> 
> -Jim P.
> 

Well, now that it compiles cleanly... guess what...  I've run into the
(in)famous "cannot unmarshal code objects in restricted execution mode"
error for which google reveals years worth of past pleas for mod_python
to address.  I guess I'm not alone in my frustration and disappointment:

http://mail.zope.org/pipermail/zodb-dev/2005-March/008590.html

http://www.modpython.org/pipermail/mod_python/2005-March/017790.html

http://mail.python.org/pipermail/python-list/2002-June/109646.html

http://www.talkaboutprogramming.com/group/comp.lang.python/messages/255375.html

I guess I have a better understanding of restricted execution mode (one
of the primary reasons I stick w/ Py on this new project).
Unfortunately I need more help in understanding what to do.

-Jim P.





More information about the Mod_python mailing list