HowTo Compile mod_wsgi for LAMP servers
Tags: UoL Lamp Server HowTo Python
Why it didn't work how it should
mod_wsgi
is not in the repositories for SUSE linux, because the hate us. Therefore, you have to compile it yourself.pip
doesn't work on the LAMP servers, so you can't use the easy way.- Stuff isn't where setup.py expects, and it doesn't adequately allow you to change the places to look, so you can't do it that way either.
- Also stuff isn't where the make file expects things to be either, so compiling doesn't work properly. But you can tell it where to look.
- Finally, you aren't allowed to put the compiled file where is should go, so
make install
doesn't work. But it leaves it lying around, so you can copy it somewhere manually.
Resources
- https://github.com/GrahamDumpleton/mod_wsgi
- https://code.google.com/p/modwsgi/wiki/InstallationIssues#Missing_Include_Files_On_SUSE
Procedure
- Get the latest version of
mod_wsgi
from https://github.com/GrahamDumpleton/mod_wsgi/releases and unzip it - Set up the configuration:
./configure --with-apxs=/usr/sbin/apxs2-prefork --with-python=/usr/bin/python
Here we have to tell it where to find python and the Apache libraries.
- Compile it:
make
- Copy the compiled file to somewhere where it can be used by Apache:
cp {mod_wsgi directory}/src/server/.libs/mod_wsgi.so /local/apache2/etc/
Last modified
9 years ago
Last modified on 07/08/15 19:13:21
Note:
See TracWiki
for help on using the wiki.