python2.6+sles11.1+lxml3.0+spyne2.8.2安装
2012-09-10 16:28
513 查看
需要搭建webservice环境,决定使用spyne模块
1. 安装distribute-0.6.26.tar.gz
最好安装上,否则有些软件安装会报错。
2. 安装lxml:
安装过程报错,原因为没有安装python-devel-2.6.0-8.9.20包,其次对“error: command 'gcc' failed with exit status 1”报错,还需要安装libxml2-dev和libxslt-dev包。
building 'lxml.etree' extension
gcc -pthread -fno-strict-aliasing -DNDEBUG -fmessage-length=0 -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -g -fwrapv -fPIC -I/usr/include/libxml2 -I/root/lxml-3.0alpha2/src/lxml/includes -I/usr/include/python2.6
-c src/lxml/lxml.etree.c -o build/temp.linux-x86_64-2.6/src/lxml/lxml.etree.o
src/lxml/lxml.etree.c:4:20: error: Python.h: No such file or directory
src/lxml/lxml.etree.c:6:6: error: #error Python headers needed to compile C extensions, please install development version of Python.
error: command 'gcc' failed with exit status 1
3. 安装spyne2.8.2
安装报错:“error: Could not find suitable distribution for Requirement.parse('pytz')" ,原因为没有安装pytz模块,需要先安装该模块
Installed /usr/local/lib64/python2.6/site-packages/spyne-2.8.2_rc-py2.6.egg
Processing dependencies for spyne==2.8.2-rc
Searching for pytz
Reading http://pypi.python.org/simple/pytz/
Download error on http://pypi.python.org/simple/pytz/: [Errno -2] Name or service not known -- Some packages may not be found!
Reading http://pypi.python.org/simple/pytz/
Download error on http://pypi.python.org/simple/pytz/: [Errno -2] Name or service not known -- Some packages may not be found!
Couldn't find index page for 'pytz' (maybe misspelled?)
Scanning index of all packages (this may take a while)
Reading http://pypi.python.org/simple/
Download error on http://pypi.python.org/simple/: [Errno -2] Name or service not known -- Some packages may not be found!
No local packages or download links found for pytz
error: Could not find suitable distribution for Requirement.parse('pytz')
总结: 为了安装spyne,需要先安装依赖模块,安装顺序为distribute,lxml,pytz,spyne
1. 安装distribute-0.6.26.tar.gz
最好安装上,否则有些软件安装会报错。
2. 安装lxml:
安装过程报错,原因为没有安装python-devel-2.6.0-8.9.20包,其次对“error: command 'gcc' failed with exit status 1”报错,还需要安装libxml2-dev和libxslt-dev包。
building 'lxml.etree' extension
gcc -pthread -fno-strict-aliasing -DNDEBUG -fmessage-length=0 -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -g -fwrapv -fPIC -I/usr/include/libxml2 -I/root/lxml-3.0alpha2/src/lxml/includes -I/usr/include/python2.6
-c src/lxml/lxml.etree.c -o build/temp.linux-x86_64-2.6/src/lxml/lxml.etree.o
src/lxml/lxml.etree.c:4:20: error: Python.h: No such file or directory
src/lxml/lxml.etree.c:6:6: error: #error Python headers needed to compile C extensions, please install development version of Python.
error: command 'gcc' failed with exit status 1
3. 安装spyne2.8.2
安装报错:“error: Could not find suitable distribution for Requirement.parse('pytz')" ,原因为没有安装pytz模块,需要先安装该模块
Installed /usr/local/lib64/python2.6/site-packages/spyne-2.8.2_rc-py2.6.egg
Processing dependencies for spyne==2.8.2-rc
Searching for pytz
Reading http://pypi.python.org/simple/pytz/
Download error on http://pypi.python.org/simple/pytz/: [Errno -2] Name or service not known -- Some packages may not be found!
Reading http://pypi.python.org/simple/pytz/
Download error on http://pypi.python.org/simple/pytz/: [Errno -2] Name or service not known -- Some packages may not be found!
Couldn't find index page for 'pytz' (maybe misspelled?)
Scanning index of all packages (this may take a while)
Reading http://pypi.python.org/simple/
Download error on http://pypi.python.org/simple/: [Errno -2] Name or service not known -- Some packages may not be found!
No local packages or download links found for pytz
error: Could not find suitable distribution for Requirement.parse('pytz')
总结: 为了安装spyne,需要先安装依赖模块,安装顺序为distribute,lxml,pytz,spyne
相关文章推荐
- win8环境python3.5安装lxml
- Windows下Python安装lxml 3.4.4
- 记录一次CentOS环境升级Python2.6到Python2.7并安装最新版pip
- CentOS6.5升级Python2.6到Python2.7并安装pip
- 如何从word开始处理html文件?以及windows上安装python lxml beautifulsoup
- centos7,win10 python2.7 安装lxml
- Python及bs4、lxml、numpy模块包的安装
- python numpy、lxml等库安装总是安装失败,啊哈哈哈哈哈哈我这次知道了一个神奇的软件!
- 相比于python2.6,python3.0的新特性。
- mac上 python 安装lxml失败Could not find function xmlCheckVersion in library libxml2. Is libxml2 installed
- mac中安装python, pydev, beautifulsoup, lxml, scrapy
- Python安装lxml(编译安装其依赖的库)
- centos默认python2.6升级到python2.7,并用pip方式安装python工具包
- tensoflow 安装出现futures requires Python '>=2.6, <3' but the running Python is 3.5.3的解决方法
- windows 下安装 python lxml
- Python: Win7下使用 pip install lxml 无法安装lxml?
- Python学习心得之lxml的安装之路
- Python 2.6 安装wxPython后提示"64.....32"错误解决办法
- python Lxml库的安装
- PYQT4 + Python2.6 + eric4-4.3.10 的安装全过程