CentOS 6.6自带的是Python 2.6.6,而编译llvm需要Python 2.7以上。

checking for python... /usr/bin/python
checking for python >= 2.7... not found
configure: error: found python 2.6.6 (/usr/bin/python); required >= 2.7

yum中最新的也是Python 2.6.6,只能下载Python 2.7.9的源代码自己编译安装。

操作步骤如下:

1)安装devtoolset

yum groupinstall "Development tools"

2)安装编译Python需要的包包

yum install zlib-devel
yum install bzip2-devel
yum install openssl-devel
yum install ncurses-devel
yum install sqlite-devel

3)下载并解压Python 2.7.9的源代码

cd /opt
wget --no-check-certificate https://www.python.org/ftp/python/2.7.9/Python-2.7.9.tar.xz
tar xf Python-2.7.9.tar.xz
cd Python-2.7.9

4)编译与安装Python 2.7.9

./configure --prefix=/usr/local
make
make altinstall

5)将python命令指向Python 2.7.9

ln -s /usr/local/bin/python2.7 /usr/local/bin/python

6)检查Python版本

sh
sh-4.1# python -V
Python 2.7.9
 
 
转载自:http://www.cnblogs.com/dudu/p/4294238.html

CentOS 6.5上安装Python 2.7.9的更多相关文章

  1. [转]在Linux CentOS 6.6上安装Python 2.7.9

    在Linux CentOS 6.6上安装Python 2.7.9 查看python安装版本 python -V yum中最新的也是Python 2.6.6,所以只能下载Python 2.7.9的源代码 ...

  2. 在Linux CentOS 6.6上安装Python 2.7.9

    CentOS 6.6自带的是Python 2.6.6,而编译llvm需要Python 2.7以上. checking for python... /usr/bin/python checking fo ...

  3. 如何在centos 7.4 上安装 python 3.6

    yum -y install https://centos7.iuscommunity.org/ius-release.rpmyum -y install python36uyum -y instal ...

  4. centos上安装python环境

    1.安装python-pip ​ 首先安装epel扩展源: ​ yum -y install epel-release ​ 更新完成之后,安装pip: ​ yum -y install python- ...

  5. CentOS 6.5上安装MySQL-Cluster

    参考博文: CentOS 6.2下MySQL Cluster 7.2 配置数据库集群 CentOS 6.5上安装MySQL-Cluster 7.3.4过程笔记--下一步学习 MySQL Cluster ...

  6. CentOS 6.5下安装Python 3.5.2(与Python2并存)

    CentOS 6.5下安装Python 3.5.2(与Python2并存) 安装步骤 1,准备编译环境(环境不对,在安装过程中可能遇到各种问题.比如wget无法下载链接的文件) yum groupin ...

  7. 转载:CentOS 6.5下安装Python 3.5.2(与Python2并存)

    原文:https://www.jb51.net/article/115370.htm 这篇文章主要给大家介绍了在CentOS 6.5下安装Python 3.5.2的方法教程,安装后的python3与P ...

  8. 在CentOS或RHEL上安装Nux Dextop仓库

    介绍 Nux Dextop是类似CentOS.RHEL.ScientificLinux的第三方RPM仓库(比如:Ardour,Shutter等等).目前,Nux Dextop对CentOS/RHEL ...

  9. 在CentOS 6.X 上面安装 Python 2.7.X

    在CentOS 6.X 上面安装 Python 2.7.X CentOS 6.X 自带的python版本是 2.6 , 由于工作需要,很多时候需要2.7版本.所以需要进行版本升级.由于一些系统工具和服 ...

随机推荐

  1. WinDebug 常用命令表【摘】

    启动, 附加进程, 执行和退出(Starting, Attaching, Executing and Exiting) ======================= Start -> All ...

  2. 常用的JQuery UI框架

    http://www.ligerui.com/ http://www.jeasyui.com/index.php http://www.jqwidgets.com/

  3. 配置Session变量的生命周期

    在Web.config文件中配置Session变量的生命周期是在<sessionState></sessionState>节中完成的,在配置Session的生命周期时,可以设置 ...

  4. axd与ashx区别

    简单说明一下axd文件.axd文件实际上并不是在硬盘上存在的文件,而是HttpHandler的一种映射.在ASP.NET MVC中有很多内置的axd到ashx的映射.你可以在web.config中通过 ...

  5. 【动态规划】HDU 1081 & XMU 1031 To the Max

    题目链接: http://acm.hdu.edu.cn/showproblem.php?pid=1081 http://acm.xmu.edu.cn/JudgeOnline/problem.php?i ...

  6. 【转】Contrary to the answers here, you DON'T need to worry about encoding!

    For those goals, I honestly do not understand why people keep telling you that you need the encoding ...

  7. HDU_1071——积分求面积,抛物线顶点公式

    Problem Description Ignatius bought a land last week, but he didn't know the area of the land becaus ...

  8. libevent的简单应用【转载】

    本文转载自: http://blog.csdn.net/liuguanghui1988/article/details/7090531 Libevent的应用主要围绕几大事件:超时事件.信号事件.读/ ...

  9. Spring 4.0 StandaloneMockMvcBuilder java.lang.NoClassDefFoundError: javax/servlet/SessionCookieConfig 问题解决

    standaloneSetup(clrr). build(); 执行第二行 build() 时,出现下面的错误提示. java.lang.NoClassDefFoundError: javax/ser ...

  10. NSOutputStream\NSInputStream

    NSOutputStream-保存网络资源到本地 _filePath = [[NetworkManager sharedInstance] pathForTemporaryFileWithPrefix ...