Mac下自带了Python 2.7.6,心血来潮,想跟着廖老师的教程学习一下,教程上说安装python的包管理工具pip的步骤可以跳过,
但是命令下显示-bash: pip: command not found
在stackoverflow上看到相同问题,于是跟着做了,
安装pip:
$ sudo easy_install pip
安装成功:
Installed /Library/Python/2.7/site-packages/pip-7.1.0-py2.7.egg
Processing dependencies for pip
Finished processing dependencies for pip
安装第三方库python imaging library,使用命令pip install PIL又出问题了,
1、Could not find a version that satisfies the requirement PIL (from versions: )
Some externally hosted files were ignored as access to them may be unreliable (use –allow-external PIL to allow).
No matching distribution found for PIL
2、 Could not find a version that satisfies the requirement PIL (from versions: )
Some insecure and unverifiable files were ignored (use –allow-unverified PIL to allow).
No matching distribution found for PIL
于是乎,跟着错误提示,输入命令
$ sudo pip install PIL –allow-external PIL –allow-unverified PIL
噔噔噔噔~
Installing collected packages: PIL
Running setup.py install for PIL
Successfully installed PIL
大功告成,继续学习~~~