ubuntu安裝uwsgi遇到的問題python
Command "/root/myenv/bin/python3.4 -c "import setuptools, tokenize;__file__='/tmp/pip-build-7cr2or3v/uwsgi/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-omoei_c8-record/install-record.txt --single-version-externally-managed --compile --install-headers /root/myenv/include/site/python3.4/uwsgi" failed with error code 1 in /tmp/pip-build-7cr2or3v/uwsgi (myenv)root@iZ94oziy87wZ:~#
上面的問題不知道緣由,也沒有給我太多錯誤提示。linux
python-dev已經安裝。ubuntu
直接 下載源碼安裝 http://projects.unbit.it/downloads/uwsgi-latest.tar.gzui
*** uWSGI compiling embedded plugins *** [x86_64-linux-gnu-gcc -pthread] plugins/python/python_plugin.o In file included from plugins/python/python_plugin.c:1:0: plugins/python/uwsgi_python.h:2:20: fatal error: Python.h: No such file or directory #include <Python.h> ^
這回算是知道問題在哪裏了,Python.hspa
find /usr -name Pythond.hcode
只在Python2.7下面找到這個。token
apt-get install python3-devip