首页 > 编程语言 > 详细

安装python 2.7.11

时间:2016-04-08 01:05:32      阅读:165      评论:0      收藏:0      [点我收藏+]

rehat 6.5 安装python2.7.11(系统里已存在2.6)
wget https://www.python.org/ftp/python/2.7.11/Python-2.7.11.tar.xz
tar [J]xvf Python-2.7.11.tar.xz
cd Python-2.7.11
./configure --prefix=/usr/ --enable-shared --with-system-expat --with-system-ffi --enable-unicode=ucs4 && make && make install
echo $?
chmod -v 755 /usr/lib/libpython2.7.so.1.0
vim /etc/ld.so.conf
添加include  /usr/lib
/sbin/ldconfig
/sbin/ldconfig -v
python

--with-system-expat: This switch enables linking against system version of Expat.
--with-system-ffi: This switch enables linking against system version of libffi. Remove if you have not installed libffi-3.2.1.
--enable-unicode=ucs4: This switch enables 32bit Unicode support in Python.
要求python编译的时候,需要有动态链接库即加上--enable-shared

将tab.py放到/usr/lib/python2.7/site-packages/

安装python 2.7.11

原文:http://wl133.blog.51cto.com/9410504/1761506

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!