码迷,mamicode.com
首页 > 编程语言 > 详细

centos和readhat下安装python2.7

时间:2014-04-30 04:58:42      阅读:400      评论:0      收藏:0      [点我收藏+]

标签:http   c   tar   t   get   amp   python   安装   re   read   install   

1、安装基本库
yum install gcc
yum install make
yum install zlib-devel
yum install bzip2-devel
yum install openssl-devel
yum install ncurses-devel

2、获得python2.7.4
wget http://www.python.org/ftp/python/2.7.4/Python-2.7.4.tar.bz2

3、解压 tar xf Python-2.7.4.tar.bz2

4、配置 cd Python-2.7.4 ./configure

5、生成&安装 make make install

6、默认安装的是Python2.4,需要修改为2.7 ln -sf /usr/local/bin/python2.7 /usr/local/bin/python

7、重进shell python -V

centos和readhat下安装python2.7,码迷,mamicode.com

centos和readhat下安装python2.7

标签:http   c   tar   t   get   amp   python   安装   re   read   install   

原文地址:http://www.cnblogs.com/jeffsun/p/3695660.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!