CentOS6.5源码安装python3.5.2
前提:
1、实现自动补全需要安装模块 readline-devel (yum install -y readline-devel)
2、实现支持SSL协议需安装模块 openssl-devel (yum install -y openssl-devel)
否则使用pip时会有报错,如下
安装步骤
1、下载python3.5源码包到/usr/local/src/ (https://www.python.org/ftp/python/3.5.2/Python-3.5.2.tgz)
2、 tar xf Python-3.5.2.tgz
cd Python-3.5.2
./configure --prefix=/usr/local/python-3.5.2
make && make >python_install.log
3、设置PATH(里面包含pip3) echo "PATH=$PATH:/usr/local/python-3.5.2/bin">> /etc/profile.d/python.sh
4、设置默认python路径
(1) which python ----> /usr/bin/python
(2) rm -rf /usr/bin/python
(3) ln -s /usr/local/python3.5.2/bin/python /usr/bin/python
(4) 修改/usr/bin/yum中python路径为/usr/bin/python2(yum中python只支持原python)
注释:因为python3.5.2中已安装了pip(python包管理工具),故不需要再安装
其他版本如没有安装pip,需要再安装,源码安装:需要先安装setuptools-28.8.0(python setup.py install),之后安装pip-9.0.1(python setup.py install)
具体安装内容参考:https://pip.pypa.io/en/stable/installing/#installing-with-get-pip-py
CentOS6.5源码安装python3.5.2的更多相关文章
- centos7源码安装Python3的前提条件
centos7源码安装Python3的前提条件: # yum -y install openssl-devel bzip2-devel expat-devel gdbm-devel readline- ...
- CentOS7 下源码安装 python3
CentOS 7 下源码安装 python3 在CentOS7下,默认安装的是python2.7:为满足项目要求,安装python3 的方法如下: 1. 首先安装python3.6可能使用的依 ...
- CENTOS6.5源码安装LNMP
CENTOS6.5源码安装LNMP 一.安装前准备 ########################################################################## ...
- CentOS6.5源码安装MySQL5.6.35
CentOS6.5源码安装MySQL5.6.35 一.卸载旧版本 1.使用下面的命令检查是否安装有mysql [root@localhost tools]# rpm -qa|grep -i mysql ...
- 源码安装Python3
源码安装Python3 一.安装Python3需要的依赖包 [root@localhost ~]# yum install -y gcc make wget openssl openssl-devel ...
- CentOS6.7源码安装MySQL5.6
1.源码安装MySQL5.6 # CentOS6操作系统安装完成后,默认会在/etc目录下存在一个my.cnf, # 强制卸载了mysql-libs之后,my.cnf就会消失 rpm -qa | gr ...
- CentOS6下源码安装mysql-5.6.25
1.1.系统环境检查 1)检查系统版本 mkdir -p /server/tools/ cd /server/tools/ cat /etc/redhat-release 2)配置域名解析 vim / ...
- Centos源码安装Python3
CentOS7默认安装了python2.7.5,当需要使用python3的时候,可以手动下载Python源码后编译安装. 下载python(https://www.python.org/ftp/pyt ...
- Linux 源码安装 Python3
下载源码包https://www.python.org/downloads/ 解压(以3.64版本为例)wget https://www.python.org/ftp/python/3.6.4/Pyt ...
随机推荐
- 并发-Java中的Copy-On-Write容器
Copy-On-Write简称COW,是一种用于程序设计中的优化策略.其基本思路是,从一开始大家都在共享同一个内容,当某个人想要修改这个内容的时候,才会真正把内容Copy出去形成一个新的内容然后再改, ...
- 64位系统上运行32位程序能否申请到8G内存?
申请不到,因为64为系统在运行32位程序的时候只是为了向下兼容而已,对于32位程序来讲,申请8G的存储空间没有任何意义,因为32位的程序最大寻址空间只有4G,32位程序在编译之后的机器代码也只有32位 ...
- 【javascript 进阶】异步调用
前言 javascript的中的异步是很重要的概念,特别是ajax的提出,给整个web带来了很大的影响,今天就介绍下javascript的异步编程. 同步与异步 何为同步?何为异步呢? 同步:说白了就 ...
- 【HOW】如何通过URL给Reporting Services报表传递参数
[本地模式Reporting Services] 参见官方文档:http://msdn.microsoft.com/en-us/library/ms154042.aspx 示例:http://serv ...
- 线程,join合并线程
在A中,调用B.join()那么,A会“等”B先执行 public class Join01 extends Thread { @Override public void run() { int su ...
- ASP.net 中手工调用WS(POST方式)
ASP.net 中手工调用WS(POST方式)核心代码:string strUrl="http://localhost:21695/service1.asmx/getmythmod" ...
- Arch Linux LibreOffice 中文输入法不能切换
From: http://blog.csdn.net/shallowgrave/article/details/8501629 卸载libreoffice-kde4 # pacman -R libre ...
- 一致性 hash 算法( consistent hashing )a
一致性 hash 算法( consistent hashing ) 张亮 consistent hashing 算法早在 1997 年就在论文 Consistent hashing and rando ...
- hadoop 运维
1:hdfs dfsadmin -report //查看集群运行状态
- swiper
<!DOCTYPE html><html lang="en"><head> <meta charset="utf-8" ...