记录一下安装pip的过程。安装过程中,遇到了一些问题:
[c.plm@localhost samba]$ python3.3 get-pip.py
Traceback (most recent call last):
File "get-pip.py", line 17474, in <module>
main()
File "get-pip.py", line 17466, in main
bootstrap(tmpdir=tmpdir)
File "get-pip.py", line 17406, in bootstrap
import pip
File "/tmp/tmpru8qrk/pip.zip/pip/__init__.py", line 10, in <module>
File "/tmp/tmpru8qrk/pip.zip/pip/util.py", line 18, in <module>
File "/tmp/tmpru8qrk/pip.zip/pip/_vendor/distlib/version.py", line 14, in <module>
File "/tmp/tmpru8qrk/pip.zip/pip/_vendor/distlib/compat.py", line 66, in <module>
ImportError: cannot import name HTTPSHandler
原因在于openssl,openssl-devel两个文件包未正确安装。用下来的命令来安装:
yum install openssl -y
yum install openssl-devel -y
安装完成后,重新安装python:
cd python3.3
./configure
make install
再次安装pip正常。
--本篇文章转自:http://jingyan.baidu.com/article/e52e3615aba39640c60c51c3.html