【发布时间】:2015-07-06 17:52:49
【问题描述】:
我在开始时遇到了很多麻烦,这是我的规格
windows 8
64 bit
python 2.7
Apachehaus 2.4.12
我终其一生都无法弄清楚如何编译 mod_wsgi 以从源代码中生成必要的 mod_wsgi.so 文件。 https://github.com/GrahamDumpleton/mod_wsgi/releases
我正在尝试编译 ap24py27-win64-VC9.mk 并在打开 Visual C++ 2008 64 位命令提示符后
c:\mod_wsgi-4.4.13> nmake -f ap24py27-win64-VC9.mk
c:\mod_wsgi-4.4.13\src\server\wsgi_python.h(24) : fatal error 1083: Cannot open include file: 'Python.h': No such file or directory wsgi_restrict.c
c:\mod_wsgi-4.4.13\src\server\wsgi_python.h(24) : fatal error 1083: Cannot open include file: 'Python.h': No such file or directory wsgi_server.c
c:\python27\mod_wsgi-4.4.13\src\server\wsgi_python.h(24) : fatal error C1083: Cannot open include file: 'Python.h': No such file or directory wsgi_stream.c
c:\mod_wsgi-4.4.13\src\server\wsgi_python.h(24) : fatal error C1083: Cannot open include file: 'Python.h': No such file or directory wsgi_validate.c
c:\mod_wsgi-4.4.13\src\server\wsgi_python.h(24) : fatal error C1083: Cannot open include file: 'Python.h': No such file or directory
Generating Code...
c:\mod_wsgi-4.4.13\src\server\wsgi_memory.c(124) : warning C4711: function 'getPeakRSS' selected for automatic inline expansion
c:\mod_wsgi-4.4.13\src\server\wsgi_memory.c(125) : warning C4711: function 'getCurrentRSS' selected for automatic inline expansion
NMAKE : fatal error U1077: '"C:\Users\User\AppData\Local\Programs\Common\Microsoft\Visual C++ for Python\9.0\VC\Bin\amd64\cl.EXE"' : return code '0x2'
Stop.
我已经将路径设置为 path=%path% Python27/include,因为那是 Python.h 文件所在的位置。
我也试过
python setup install
Traceback (most recent call last):
File "setup.py", line 139, in <module>
'missing Apache httpd server packages.' % APXS)
RuntimeError: The 'apxs' command appears not to be installed or is not executable. Please check the list of prerequisites in the documentation for this package and install any missing Apache httpd server packages.
【问题讨论】:
标签: python c++ django apache mod-wsgi