Ubuntu 14.04 .5 LTS 安装Python-pip(三)

查看pip的版本

pip -V
pip 10.0.1 from /usr/local/lib/python3.6/site-packages/pip-10.0.1-py3.6.egg/pip (python 3.6)

卸载pip

sudo apt-get autoremove python-pip
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package 'python-pip' is not installed, so not removed
The following packages will be REMOVED:
  libqpdf13 python-colorama python-distlib python-html5lib python-wheel
0 upgraded, 0 newly installed, 5 to remove and 8 not upgraded.
After this operation, 2,318 kB disk space will be freed.
Do you want to continue? [Y/n] y
(Reading database ... 212939 files and directories currently installed.)
Removing libqpdf13:amd64 (5.1.1-1) ...
Removing python-colorama (0.2.5-0.1ubuntu2) ...
Removing python-distlib (0.1.8-1ubuntu1) ...
Removing python-html5lib (0.999-3~ubuntu1) ...
Removing python-wheel (0.24.0-1~ubuntu1) ...
Processing triggers for libc-bin (2.19-0ubuntu6.14) ...

最终还是放弃命令行安装了,实在是不太明白。
换一种安装方法:

sudo add-apt-repository ppa:fkrull/deadsnakes
This repository is kept for historical purposes, but NOT UPDATED. Please use the new repository at

https://launchpad.net/~deadsnakes/+archive/ubuntu/ppa

instead!
More info: https://launchpad.net/~fkrull/+archive/ubuntu/deadsnakes
Press [ENTER] to continue or ctrl-c to cancel adding it

gpg: keyring `/tmp/tmpo1byfdym/secring.gpg' created
gpg: keyring `/tmp/tmpo1byfdym/pubring.gpg' created
gpg: requesting key DB82666C from hkp server keyserver.ubuntu.com
gpg: /tmp/tmpo1byfdym/trustdb.gpg: trustdb created
gpg: key DB82666C: public key "Launchpad Old Python Versions" imported
gpg: Total number processed: 1
gpg:               imported: 1  (RSA: 1)
OK

1

#sudo apt-get update
#sudo apt-get install python3.6
E: Sub-process /usr/bin/dpkg returned an error code (1)

那就解决这个dpkg包的问题。

cd /var/lib/dpkg        
sudo mv info info.bak   #做备份 
sudo mkdir info
sudo apt-get install cmake --reinstall 
sudo rm -rf info
sudo mv info.bak info

然后在执行

sudo apt-get install python3.6
Reading package lists... Done
Building dependency tree       
Reading state information... Done
python3.6 is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 8 not upgraded.

这样是不是python3.6就安装好了那。

pip install  web.py
Could not find a version that satisfies the requirement web.py (from     versions: )
No matching distribution found for web.py

问题我没有全部复制上来,总之就是还有问题。看来这个pip我是装不明白了,需要手动下载库了。

你可能感兴趣的:(Ubuntu 14.04 .5 LTS 安装Python-pip(三))