原文http://www.coder4.com/archives/1551
Debian5 (lenny)上安装的python是2.5的,很老,怎么安装2.7的呢?
除了编译之外,我们还可以用apt的方法搞定。如下:
1、修改源
实际上python2.7在unstable源中
sudo vim /etc/apt/sources.list #添加 deb http://ftp.us.debian.org/debian/ unstable main contrib non-free #更新 sudo apt-get update
2、安装
sudo apt-get install python2.7
3、替换
sudo rm /usr/bin/python sudo ln -s /usr/bin/python2.7 /usr/bin/python
- 本文固定链接: https://www.fengshen.cn/2013/03/debian-安装-python-2-7/storyofwind/
- 转载请注明: fengshen 发表于 Dream of Wind | 一梦风神
觉得文章有用,微信打赏一元。
