Full output:
In file included from src/server/mod_wsgi.c:22:0:
src/server/wsgi_python.h:26:10: fatal error: Python.h: No such file or directory
#include <Python.h>
^~~~~~~~~~
compilation terminated.
apxs:Error: Command failed with rc=65536
.
make: *** [src/server/mod_wsgi.la] Error 1
I've been trying to compile mod_wsgi with python 3.11 using make to no avail. I've already installed python3-devel but it doesn't look like Python.h is being installed in the correct location or something? I've even tried copying Python.h into the same directory as the code that is looking for it, i.e src/server/
I made sure to compile Python with enable-shared as well.
Where exactly is this file supposed to be located and how can I get it? I was hoping there was a python311-devel I could install but there is only up to python34-devel
Thank you in advance
I had a similar issue with a pip install requiring thriftpy2.
A workaround that appears to be working for me is to expand the visibility of gcc environment variables as follows: