ubuntu install pip

方法一:

1)apt-get update

2)apt-get -y install python-pip

方法二:

1)curl "https://bootstrap.pypa.io/get-pip.py" -o "get-pip.py"

2)python get-pip.py

需要root权限

方法一:

 

错误:

File "/usr/lib/python2.7/dist-packages/setuptools/command/easy_install.py", line 1028, in run_setup

    raise DistutilsError("Setup script exited with %s" % (v.args[0],))

distutils.errors.DistutilsError: Setup script exited with error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

解决办法:

apt-get install -y libffi-dev libssl-dev

 

问题:

File "/usr/local/lib/python2.7/dist-packages/packaging/requirements.py", line 9, in <module>
    from pyparsing import stringStart, stringEnd, originalTextFor, ParseException
ImportError: No module named pyparsing

解决办法:

     重新安装pip

 

posted @ 2016-01-22 15:23  开心星  阅读(298)  评论(0编辑  收藏  举报