简体   繁体   中英

mod_wsgi 2.5 on Ubuntu 9.04 with Python 2.6.2 installation

Has anybody succeeded with mod_wsgi 2.5 on Ubuntu 9.04 with default Python installation (2.6.2)?

I got compilation errors:

mod_wsgi.c:119:2: error: #error Sorry, mod_wsgi requires at least Python 2.3.0.
mod_wsgi.c:123:2: error: #error Sorry, mod_wsgi requires that Python supporting thread.

which Python gives /usr/bin/python and /usr/bin/python -V returns Python 2.6.2 so I'm not sure what's wrong with the 1st one, and honestly I don't know how to check options used in compiling default Python on Ubuntu.

There are a lot of other errors but those 2 looks most relevant.

What else could be possibly wrong??

From your errors I see that you're having to compile python extensions. If you haven't already, I suggest you install the python-dev package because it's usually required for compiling python extensions and it's not part of the default installation.

Installing the package is as easy as running:

sudo apt-get install python-dev

from a command line.

Perhaps the user that the server is running as does not have /usr/bin on its path, and there is another version of python somewhere else on the path that is < 2.3

Try:

which -a python

to find all of the pythons on your path. Perhaps one of these is what the server is running.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM