安装 uwsgi报错解决
背景:
安装 uwsgi时报错如下,查阅相关资料说是 python-devel的问题,于是安装之后python-devel后问题解决
报错如下:
(venv) [xxxxxxx]# pip install uwsgi
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
Looking in indexes: http://mirrors.aliyun.com/pypi/simple/
Collecting uwsgi
Downloading http://mirrors.aliyun.com/pypi/packages/e7/1e/3dcca007f974fe4eb369bf1b8629d5e342bb3055e2001b2e5340aaefae7a/uwsgi-2.0.18.tar.gz (801kB)
|????????????????????????????????| 808kB 3.1MB/s
Building wheels for collected packages: uwsgi
Building wheel for uwsgi (setup.py) ... error
ERROR: Command errored out with exit status 1:
command: /xxxxxx/bin/python2 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-dy5kN5/uwsgi/setup.py'"'"'; __file__='"'"'/tmp/pip-install-dy5kN5/uwsgi/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-BZc6P_ --python-tag cp27
cwd: /tmp/pip-install-dy5kN5/uwsgi/
Complete output (98 lines):
/usr/lib64/python2.7/distutils/dist.py:267: UserWarning: Unknown distribution option: 'descriptions'
warnings.warn(msg)
running bdist_wheel
running build
running build_py
creating build
creating build/lib
copying uwsgidecorators.py -> build/lib
installing to build/bdist.linux-x86_64/wheel
running install
using profile: buildconf/default.ini
detected include path: ['/usr/lib/gcc/x86_64-redhat-linux/4.8.5/include', '/usr/local/include', '/usr/include']
Patching "bin_name" to properly install_scripts dir
detected CPU cores: 1
configured CFLAGS: -O2 -I. -Wall -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fno-strict-aliasing -Wextra -Wno-unused-parameter -Wno-missing-field-initializers -Wno-format -Wno-format-security -DUWSGI_HAS_IFADDRS -DUWSGI_ZLIB -DUWSGI_LOCK_USE_MUTEX -DUWSGI_EVENT_USE_EPOLL -DUWSGI_EVENT_TIMER_USE_TIMERFD -DUWSGI_EVENT_FILEMONITOR_USE_INOTIFY -DUWSGI_PCRE -DUWSGI_ROUTING -DUWSGI_VERSION="\"2.0.18\"" -DUWSGI_VERSION_BASE="" -DUWSGI_VERSION_MAJOR="" -DUWSGI_VERSION_MINOR="" -DUWSGI_VERSION_REVISION="" -DUWSGI_VERSION_CUSTOM="\"\"" -DUWSGI_YAML -DUWSGI_SSL -DUWSGI_PLUGIN_DIR="\".\"" -DUWSGI_DECLARE_EMBEDDED_PLUGINS="UDEP(python);UDEP(gevent);UDEP(ping);UDEP(cache);UDEP(nagios);UDEP(rrdtool);UDEP(carbon);UDEP(rpc);UDEP(corerouter);UDEP(fastrouter);UDEP(http);UDEP(ugreen);UDEP(signal);UDEP(syslog);UDEP(rsyslog);UDEP(logsocket);UDEP(router_uwsgi);UDEP(router_redirect);UDEP(router_basicauth);UDEP(zergpool);UDEP(redislog);UDEP(mongodblog);UDEP(router_rewrite);UDEP(router_http);UDEP(logfile);UDEP(router_cache);UDEP(rawrouter);UDEP(router_static);UDEP(sslrouter);UDEP(spooler);UDEP(cheaper_busyness);UDEP(symcall);UDEP(transformation_tofile);UDEP(transformation_gzip);UDEP(transformation_chunked);UDEP(transformation_offload);UDEP(router_memcached);UDEP(router_redis);UDEP(router_hash);UDEP(router_expires);UDEP(router_metrics);UDEP(transformation_template);UDEP(stats_pusher_socket);" -DUWSGI_LOAD_EMBEDDED_PLUGINS="ULEP(python);ULEP(gevent);ULEP(ping);ULEP(cache);ULEP(nagios);ULEP(rrdtool);ULEP(carbon);ULEP(rpc);ULEP(corerouter);ULEP(fastrouter);ULEP(http);ULEP(ugreen);ULEP(signal);ULEP(syslog);ULEP(rsyslog);ULEP(logsocket);ULEP(router_uwsgi);ULEP(router_redirect);ULEP(router_basicauth);ULEP(zergpool);ULEP(redislog);ULEP(mongodblog);ULEP(router_rewrite);ULEP(router_http);ULEP(logfile);ULEP(router_cache);ULEP(rawrouter);ULEP(router_static);ULEP(sslrouter);ULEP(spooler);ULEP(cheaper_busyness);ULEP(symcall);ULEP(transformation_tofile);ULEP(transformation_gzip);ULEP(transformation_chunked);ULEP(transformation_offload);ULEP(router_memcached);ULEP(router_redis);ULEP(router_hash);ULEP(router_expires);ULEP(router_metrics);ULEP(transformation_template);ULEP(stats_pusher_socket);"
*** uWSGI compiling server core ***
[gcc -pthread] core/utils.o
[gcc -pthread] core/protocol.o
[gcc -pthread] core/socket.o
[gcc -pthread] core/logging.o
[gcc -pthread] core/master.o
[gcc -pthread] core/master_utils.o
[gcc -pthread] core/emperor.o
[gcc -pthread] core/notify.o
[gcc -pthread] core/mule.o
[gcc -pthread] core/subscription.o
[gcc -pthread] core/stats.o
[gcc -pthread] core/sendfile.o
[gcc -pthread] core/async.o
[gcc -pthread] core/master_checks.o
[gcc -pthread] core/fifo.o
[gcc -pthread] core/offload.o
[gcc -pthread] core/io.o
[gcc -pthread] core/static.o
[gcc -pthread] core/websockets.o
[gcc -pthread] core/spooler.o
[gcc -pthread] core/snmp.o
[gcc -pthread] core/exceptions.o
[gcc -pthread] core/config.o
[gcc -pthread] core/setup_utils.o
[gcc -pthread] core/clock.o
[gcc -pthread] core/init.o
[gcc -pthread] core/buffer.o
[gcc -pthread] core/reader.o
[gcc -pthread] core/writer.o
[gcc -pthread] core/alarm.o
[gcc -pthread] core/cron.o
[gcc -pthread] core/hooks.o
[gcc -pthread] core/plugins.o
[gcc -pthread] core/lock.o
[gcc -pthread] core/cache.o
[gcc -pthread] core/daemons.o
[gcc -pthread] core/errors.o
[gcc -pthread] core/hash.o
[gcc -pthread] core/master_events.o
[gcc -pthread] core/chunked.o
[gcc -pthread] core/queue.o
[gcc -pthread] core/event.o
[gcc -pthread] core/signal.o
[gcc -pthread] core/strings.o
[gcc -pthread] core/progress.o
[gcc -pthread] core/timebomb.o
[gcc -pthread] core/ini.o
[gcc -pthread] core/fsmon.o
[gcc -pthread] core/mount.o
[gcc -pthread] core/metrics.o
[gcc -pthread] core/plugins_builder.o
[gcc -pthread] core/sharedarea.o
[gcc -pthread] core/rpc.o
[gcc -pthread] core/gateway.o
[gcc -pthread] core/loop.o
[gcc -pthread] core/cookie.o
[gcc -pthread] core/querystring.o
[gcc -pthread] core/rb_timers.o
[gcc -pthread] core/transformations.o
[gcc -pthread] core/uwsgi.o
[gcc -pthread] proto/base.o
[gcc -pthread] proto/uwsgi.o
[gcc -pthread] proto/http.o
[gcc -pthread] proto/fastcgi.o
[gcc -pthread] proto/scgi.o
[gcc -pthread] proto/puwsgi.o
[gcc -pthread] lib/linux_ns.o
[gcc -pthread] core/zlib.o
[gcc -pthread] core/regexp.o
[gcc -pthread] core/routing.o
[gcc -pthread] core/yaml.o
[gcc -pthread] core/ssl.o
[gcc -pthread] core/legion.o
[gcc -pthread] core/dot_h.o
[gcc -pthread] core/config_py.o
*** uWSGI compiling embedded plugins ***
[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>
^
compilation terminated.
----------------------------------------
ERROR: Failed building wheel for uwsgi
Running setup.py clean for uwsgi
Failed to build uwsgi
Installing collected packages: uwsgi
Running setup.py install for uwsgi ... error
ERROR: Command errored out with exit status 1:
command: /xxxxxxxx/python2 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-dy5kN5/uwsgi/setup.py'"'"'; __file__='"'"'/tmp/pip-install-dy5kN5/uwsgi/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-z3qq7P/install-record.txt --single-version-externally-managed --compile --install-headers /xxxxxxxx/include/site/python2.7/uwsgi
cwd: /tmp/pip-install-dy5kN5/uwsgi/
Complete output (91 lines):
/usr/lib64/python2.7/distutils/dist.py:267: UserWarning: Unknown distribution option: 'descriptions'
warnings.warn(msg)
running install
using profile: buildconf/default.ini
detected include path: ['/usr/lib/gcc/x86_64-redhat-linux/4.8.5/include', '/usr/local/include', '/usr/include']
Patching "bin_name" to properly install_scripts dir
detected CPU cores: 1
configured CFLAGS: -O2 -I. -Wall -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -fno-strict-aliasing -Wextra -Wno-unused-parameter -Wno-missing-field-initializers -Wno-format -Wno-format-security -DUWSGI_HAS_IFADDRS -DUWSGI_ZLIB -DUWSGI_LOCK_USE_MUTEX -DUWSGI_EVENT_USE_EPOLL -DUWSGI_EVENT_TIMER_USE_TIMERFD -DUWSGI_EVENT_FILEMONITOR_USE_INOTIFY -DUWSGI_PCRE -DUWSGI_ROUTING -DUWSGI_VERSION="\"2.0.18\"" -DUWSGI_VERSION_BASE="" -DUWSGI_VERSION_MAJOR="" -DUWSGI_VERSION_MINOR="" -DUWSGI_VERSION_REVISION="" -DUWSGI_VERSION_CUSTOM="\"\"" -DUWSGI_YAML -DUWSGI_SSL -DUWSGI_PLUGIN_DIR="\".\"" -DUWSGI_DECLARE_EMBEDDED_PLUGINS="UDEP(python);UDEP(gevent);UDEP(ping);UDEP(cache);UDEP(nagios);UDEP(rrdtool);UDEP(carbon);UDEP(rpc);UDEP(corerouter);UDEP(fastrouter);UDEP(http);UDEP(ugreen);UDEP(signal);UDEP(syslog);UDEP(rsyslog);UDEP(logsocket);UDEP(router_uwsgi);UDEP(router_redirect);UDEP(router_basicauth);UDEP(zergpool);UDEP(redislog);UDEP(mongodblog);UDEP(router_rewrite);UDEP(router_http);UDEP(logfile);UDEP(router_cache);UDEP(rawrouter);UDEP(router_static);UDEP(sslrouter);UDEP(spooler);UDEP(cheaper_busyness);UDEP(symcall);UDEP(transformation_tofile);UDEP(transformation_gzip);UDEP(transformation_chunked);UDEP(transformation_offload);UDEP(router_memcached);UDEP(router_redis);UDEP(router_hash);UDEP(router_expires);UDEP(router_metrics);UDEP(transformation_template);UDEP(stats_pusher_socket);" -DUWSGI_LOAD_EMBEDDED_PLUGINS="ULEP(python);ULEP(gevent);ULEP(ping);ULEP(cache);ULEP(nagios);ULEP(rrdtool);ULEP(carbon);ULEP(rpc);ULEP(corerouter);ULEP(fastrouter);ULEP(http);ULEP(ugreen);ULEP(signal);ULEP(syslog);ULEP(rsyslog);ULEP(logsocket);ULEP(router_uwsgi);ULEP(router_redirect);ULEP(router_basicauth);ULEP(zergpool);ULEP(redislog);ULEP(mongodblog);ULEP(router_rewrite);ULEP(router_http);ULEP(logfile);ULEP(router_cache);ULEP(rawrouter);ULEP(router_static);ULEP(sslrouter);ULEP(spooler);ULEP(cheaper_busyness);ULEP(symcall);ULEP(transformation_tofile);ULEP(transformation_gzip);ULEP(transformation_chunked);ULEP(transformation_offload);ULEP(router_memcached);ULEP(router_redis);ULEP(router_hash);ULEP(router_expires);ULEP(router_metrics);ULEP(transformation_template);ULEP(stats_pusher_socket);"
*** uWSGI compiling server core ***
core/utils.o is up to date
core/protocol.o is up to date
core/socket.o is up to date
core/logging.o is up to date
core/master.o is up to date
core/master_utils.o is up to date
core/emperor.o is up to date
core/notify.o is up to date
core/mule.o is up to date
core/subscription.o is up to date
core/stats.o is up to date
core/sendfile.o is up to date
core/async.o is up to date
core/master_checks.o is up to date
core/fifo.o is up to date
core/offload.o is up to date
core/io.o is up to date
core/static.o is up to date
core/websockets.o is up to date
core/spooler.o is up to date
core/snmp.o is up to date
core/exceptions.o is up to date
core/config.o is up to date
core/setup_utils.o is up to date
core/clock.o is up to date
core/init.o is up to date
core/buffer.o is up to date
core/reader.o is up to date
core/writer.o is up to date
core/alarm.o is up to date
core/cron.o is up to date
core/hooks.o is up to date
core/plugins.o is up to date
core/lock.o is up to date
core/cache.o is up to date
core/daemons.o is up to date
core/errors.o is up to date
core/hash.o is up to date
core/master_events.o is up to date
core/chunked.o is up to date
core/queue.o is up to date
core/event.o is up to date
core/signal.o is up to date
core/strings.o is up to date
core/progress.o is up to date
core/timebomb.o is up to date
core/ini.o is up to date
core/fsmon.o is up to date
core/mount.o is up to date
core/metrics.o is up to date
core/plugins_builder.o is up to date
core/sharedarea.o is up to date
core/rpc.o is up to date
core/gateway.o is up to date
core/loop.o is up to date
core/cookie.o is up to date
core/querystring.o is up to date
core/rb_timers.o is up to date
core/transformations.o is up to date
core/uwsgi.o is up to date
proto/base.o is up to date
proto/uwsgi.o is up to date
proto/http.o is up to date
proto/fastcgi.o is up to date
proto/scgi.o is up to date
proto/puwsgi.o is up to date
lib/linux_ns.o is up to date
core/zlib.o is up to date
core/regexp.o is up to date
core/routing.o is up to date
core/yaml.o is up to date
core/ssl.o is up to date
core/legion.o is up to date
[gcc -pthread] core/dot_h.o
[gcc -pthread] core/config_py.o
*** uWSGI compiling embedded plugins ***
[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>
^
compilation terminated.
----------------------------------------
ERROR: Command errored out with exit status 1: /xxxxxxx/bin/python2 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-dy5kN5/uwsgi/setup.py'"'"'; __file__='"'"'/tmp/pip-install-dy5kN5/uwsgi/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-z3qq7P/install-record.txt --single-version-externally-managed --compile --install-headers /xxxxxxxx/include/site/python2.7/uwsgi Check the logs for full command output.
解决:
安装 python-devel
yum install python-devel
安装完成后再安装 uwsgi,成功安装
pip install uwsgi
更新:
https://www.cnblogs.com/whycai/p/12492617.html
安装 uwsgi报错解决的更多相关文章
- Ubuntu16.04上使用Anaconda3的Python3.6的pip安装UWSGI报错解决办法
具体报错信息: lto1: fatal error: bytecode stream generated with LTO version 6.0 instead of the expected 4. ...
- python︱模块加载(pip安装)以及pycharm安装与报错解决方式
每每以为攀得众山小,可.每每又切实来到起点,大牛们,缓缓脚步来俺笔记葩分享一下吧,please~ --------------------------- 准备放下R开始学python,真是痛苦,因为找 ...
- 安装APK报错解决方法【转】
本文转载自:http://blog.csdn.net/zy1235678/article/details/38122827 adb install xxx.apk 报错,安装APK报错:INSTALL ...
- python 2.7安装pygame报错解决办法pygame-1.9.4-cp27-cp27m-win_amd64.whl is not a supported wheel on this platform.
python下载python安装包 https://www.lfd.uci.edu/~gohlke/pythonlibs/#pygame 下载完后进入cmd命令行执行安装,报错: pygame-1.9 ...
- Mac安装MySQL-python报错解决
Mac安装MySQL-pyhton报错 今天在Mac上安装MySQL-python报错,搜遍网络都说什么mysql config路径问题,但是都不行. 解决方案 一开始遇到的问题是: Complete ...
- hp安装oracle报错解决
hpux上安装oracle 11gR2刚开始报错:集群验证框架内部发生了错误 解决办法http://www.it165.net/database/html/201509/14181.html 将文件后 ...
- ubuntu pip 安装django报错解决
系统版本 ubuntu Kylin 16.04 LTS 安装pip3 安装 Django 总是提示time out,无法安装. 逛了好多论坛终于遭到了解决办法,分享保存: sudo pi ...
- Linux安装oracle报错解决
安装报错:[oracle@centos1 database]$ ./runInstaller Starting Oracle Universal Installer... Checking insta ...
- darknet的安装及报错解决
darknet 是YOLO网络的一个框架,安装见官网:https://pjreddie.com/darknet/ 跟着步骤就可以安装好了. 由于官网是全英文的,所以本文根据官网进行中文释义. 本人在按 ...
随机推荐
- mac自带ssh在哪
打开Finder,前往> 前往文件夹,输入 ~/.ssh 回车就到ssh目录了. 点击Mac顶部菜单-->“苹果”图标-->最近使用的项目-->终端--输入 open ~/.s ...
- 【python小记】python操作excel文件
题记: 最近因为工作需要,学习了python,瞬间对这个轻松快捷的语给吸引了,以前只知道js脚本是写网页的,没有想到python这个脚本语言的应用范围可以这么广泛,现在做一些简单或稍微复杂的操作,基本 ...
- flask框架(五)——支持正则写法、模板用法、请求响应、session
如果用正则的话,我们要用自定义的路由. 1导入from werkzeug.routing import BaseConverter 2我先要写一个类,然后继承BaseConverter,然后实现__i ...
- 微信小程序的登入与授权
官方文档:https://developers.weixin.qq.com/miniprogram/dev/framework/open-ability/login.html 小程序登录 小程序可以通 ...
- Python中logging快速上手教程
本文使用得日志需要导入logging模块和logging.handlers模块,即 import logging import logging.handlers ''' author = " ...
- Springboot 整合ApachShiro完成登录验证和权限管理
1.前言 做一个系统最大的问题就是安全问题以及权限的问题,如何正确的选择一个安全框架对自己的系统进行保护,这方面常用的框架有SpringSecurity,但考虑到它的庞大和复杂,大多数公司还是会选择 ...
- 论文笔记 Large Pose 3D Face Reconstruction from a Single Image via Direct Volumetric CNN Regression
Large Pose 3D Face Reconstruction from a Single Image via Direct Volumetric CNN Regression 该文献采用一个新型 ...
- zookerper入门、核心概念和使用场景
zookeeper是一个分布式程序的高性能协调服务,提供集中式信息存储服务,数据存储于内存中,类似文件系统的树形结构,高吞吐量和低延时,集群高可靠,基于zookeeper可以实现分布式统一配置中心.分 ...
- 2.9_Database Interface ADO结构组成及连接方式实例
说通俗点OLE DB和ODBC都是最底层的东西,而ADO对象给我们提供了一个“可视化”和应用层直接交互的组件,ADO对象T通过OLE DB间接取得数据库中的数据,如下图: 从上面看出,可以说ADO是应 ...
- sqlite 一些常用的句子
有关SQLITE最完整的操作语句参考资料,应当是官方网址的http://www.sqlite.org/lang.html这个地方. select max(id) from table 取最大id ...