Install Python on OSX based on XCode - 通達人驛站
2014/12/9

Install Python on OSX based on XCode

From the reference, XCode may great for learning but it's not good for development. Since the Python version shipped with XCode may be out of date from the official current Python release.

從參考資料得知,利用 XCode 的方式學習 Python 是不錯的選擇,但因為 XCode 不一定會使用最新版的 Python,所以不利於開發。

You might use Eclipse to learn Python, but I'm a beginner. Finally I choose XCode 6 + Command Line Tool to learn Python.

我找到的另一種方案是使用 Eclipse,但我只是想學習 Python,最後我仍然選擇 XCode 6 + Command Line Tool 做為我學習 Python 的平台。


Step 1: Install XCode + Command Line Tools for XCode


You could get XCode and Command Line Tools from Apple Developer.

你可以從 Apple Developer 取得 XCode 和 Command Line Tools。

GCC can be obtained by XCode. If you already have XCode installed, do not install OSX-GCC-Installer. This combination might cause software issues that are difficult to debug.

GCC 可以從 XCode內取得,如果你已經安裝 XCode,就不需要安裝 OSX-GCC-Installer,這個組合可能導致難以 debug 的軟體問題。

Step 2: Install Homebrew


概略說明請參考Homebrew,簡單地說就是:
OS X 缺少的套件管理工具...Homebrew 互補了 OS X,...使用 Homebrew 安裝 Apple 沒有預裝但是你需要的東西。

From Homebrew
Homebrew installs the stuff you need that Apple didn’t. ... Homebrew complements OS X. ...

Install Homebrew 命令如下:
$ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

Log:
nb001022:~ sunjose$ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
==> This script will install:
/usr/local/bin/brew
/usr/local/Library/...
/usr/local/share/man/man1/brew.1
==> The following directories will be made group writable:
/usr/local/.
/usr/local/share
==> The following directories will have their group set to admin:
/usr/local/.
/usr/local/share

Press RETURN to continue or any other key to abort
==> /usr/bin/sudo /bin/chmod g+rwx /usr/local/. /usr/local/share

WARNING: Improper use of the sudo command could lead to data loss
or the deletion of important system files. Please double-check your
typing when using sudo. Type "man sudo" for more information.

To proceed, enter your password, or type Ctrl-C to abort.

Password:
==> /usr/bin/sudo /usr/bin/chgrp admin /usr/local/. /usr/local/share
==> /usr/bin/sudo /bin/mkdir /Library/Caches/Homebrew
==> /usr/bin/sudo /bin/chmod g+rwx /Library/Caches/Homebrew
==> Downloading and installing Homebrew...
remote: Counting objects: 215815, done.
remote: Compressing objects: 100% (56994/56994), done.
remote: Total 215815 (delta 157597), reused 215815 (delta 157597)
Receiving objects: 100% (215815/215815), 47.50 MiB | 311.00 KiB/s, done.
Resolving deltas: 100% (157597/157597), done.
From https://github.com/Homebrew/homebrew
* [new branch] master -> origin/master
HEAD is now at 56b57d5 zshdb: modernize autotools deps
==> Installation successful!
==> Next steps
Run `brew doctor` before you install anything
Run `brew help` to get started


Step 3: Install Python


Install Python 命令如下:
nb001022:~ sunjose$ brew install python

Log:
nb001022:~ sunjose$ brew install python
==> Installing dependencies for python: readline, sqlite, gdbm, openssl
==> Installing python dependency: readline
==> Downloading https://downloads.sf.net/project/machomebrew/Bottles/readline-6.
######################################################################## 100.0%
==> Pouring readline-6.3.8.yosemite.bottle.tar.gz
==> Caveats
This formula is keg-only, which means it was not symlinked into /usr/local.

Mac OS X provides similar software, and installing this software in
parallel can cause all kinds of trouble.

OS X provides the BSD libedit library, which shadows libreadline.
In order to prevent conflicts when programs look for libreadline we are
defaulting this GNU Readline installation to keg-only.

Generally there are no consequences of this for you. If you build your
own software and it requires this formula, you'll need to add to your
build variables:

LDFLAGS: -L/usr/local/opt/readline/lib
CPPFLAGS: -I/usr/local/opt/readline/include

==> Summary
🍺 /usr/local/Cellar/readline/6.3.8: 40 files, 2.1M
==> Installing python dependency: sqlite
==> Downloading https://downloads.sf.net/project/machomebrew/Bottles/sqlite-3.8.
######################################################################## 100.0%
==> Pouring sqlite-3.8.7.1.yosemite.bottle.tar.gz
==> Caveats
This formula is keg-only, which means it was not symlinked into /usr/local.

Mac OS X already provides this software and installing another version in
parallel can cause all kinds of trouble.

OS X provides an older sqlite3.

Generally there are no consequences of this for you. If you build your
own software and it requires this formula, you'll need to add to your
build variables:

LDFLAGS: -L/usr/local/opt/sqlite/lib
CPPFLAGS: -I/usr/local/opt/sqlite/include

==> Summary
🍺 /usr/local/Cellar/sqlite/3.8.7.1: 9 files, 2.1M
==> Installing python dependency: gdbm
==> Downloading https://downloads.sf.net/project/machomebrew/Bottles/gdbm-1.11.y
######################################################################## 100.0%
==> Pouring gdbm-1.11.yosemite.bottle.1.tar.gz
🍺 /usr/local/Cellar/gdbm/1.11: 17 files, 532K
==> Installing python dependency: openssl
==> Downloading https://downloads.sf.net/project/machomebrew/Bottles/openssl-1.0
######################################################################## 100.0%
==> Pouring openssl-1.0.1j.yosemite.bottle.tar.gz
==> Caveats
A CA file has been bootstrapped using certificates from the system
keychain. To add additional certificates, place .pem files in
/usr/local/etc/openssl/certs

and run
/usr/local/opt/openssl/bin/c_rehash

This formula is keg-only, which means it was not symlinked into /usr/local.

Mac OS X already provides this software and installing another version in
parallel can cause all kinds of trouble.

Apple has deprecated use of OpenSSL in favor of its own TLS and crypto libraries

Generally there are no consequences of this for you. If you build your
own software and it requires this formula, you'll need to add to your
build variables:

LDFLAGS: -L/usr/local/opt/openssl/lib
CPPFLAGS: -I/usr/local/opt/openssl/include

==> Summary
🍺 /usr/local/Cellar/openssl/1.0.1j: 431 files, 15M
==> Installing python
==> Downloading https://downloads.sf.net/project/machomebrew/Bottles/python-2.7.
######################################################################## 100.0%
==> Pouring python-2.7.8_2.yosemite.bottle.3.tar.gz
==> Caveats
Setuptools and Pip have been installed. To update them
pip install --upgrade setuptools
pip install --upgrade pip

You can install Python packages with
pip install

They will install into the site-package directory
/usr/local/lib/python2.7/site-packages

See: https://github.com/Homebrew/homebrew/blob/master/share/doc/homebrew/Homebrew-and-Python.md

.app bundles were installed.
Run `brew linkapps` to symlink these to /Applications.
==> /usr/local/Cellar/python/2.7.8_2/bin/python -s setup.py --no-user-cfg instal
==> /usr/local/Cellar/python/2.7.8_2/bin/python -s setup.py --no-user-cfg instal
==> Summary
🍺 /usr/local/Cellar/python/2.7.8_2: 4776 files, 76M


Step 4: Install setuptools


I installed 2 setuptools, easy_install and pip. Although pip improvde the easy_install, but pip still can not replace easy_install. Since lots of package need easy_install to install, include pip.

我安裝了 2 個 setuptools:easy_install 和 pip。pip 雖然改善了不少 easy_install 的缺點,不過 pip 還不能夠完全取代 easy_install,因為目前有很多套件還是得用 easy_install 安裝,包括 pip。

Install easy_install 命令如下:
$ curl https://bootstrap.pypa.io/ez_setup.py -o - | python

Log:
nb001022:~ sunjose$ curl https://bootstrap.pypa.io/ez_setup.py -o - | python
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 10476 100 10476 0 0 18928 0 --:--:-- --:--:-- --:--:-- 18943
Downloading https://pypi.python.org/packages/source/s/setuptools/setuptools-7.0.zip
Extracting in /var/folders/ww/01w_t4y93pdf_5z87brc3kc40000gn/T/tmpPycoM3
Now working in /var/folders/ww/01w_t4y93pdf_5z87brc3kc40000gn/T/tmpPycoM3/setuptools-7.0
Installing Setuptools
running install
running bdist_egg
running egg_info
writing requirements to setuptools.egg-info/requires.txt
writing setuptools.egg-info/PKG-INFO
writing top-level names to setuptools.egg-info/top_level.txt
writing dependency_links to setuptools.egg-info/dependency_links.txt
writing entry points to setuptools.egg-info/entry_points.txt
reading manifest file 'setuptools.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'setuptools.egg-info/SOURCES.txt'
installing library code to build/bdist.macosx-10.10-x86_64/egg
running install_lib
running build_py
creating build
creating build/lib
copying pkg_resources.py -> build/lib
copying easy_install.py -> build/lib
creating build/lib/_markerlib
copying _markerlib/__init__.py -> build/lib/_markerlib
copying _markerlib/markers.py -> build/lib/_markerlib
creating build/lib/setuptools
copying setuptools/__init__.py -> build/lib/setuptools
copying setuptools/archive_util.py -> build/lib/setuptools
copying setuptools/compat.py -> build/lib/setuptools
copying setuptools/depends.py -> build/lib/setuptools
copying setuptools/dist.py -> build/lib/setuptools
copying setuptools/extension.py -> build/lib/setuptools
copying setuptools/lib2to3_ex.py -> build/lib/setuptools
copying setuptools/msvc9_support.py -> build/lib/setuptools
copying setuptools/package_index.py -> build/lib/setuptools
copying setuptools/py26compat.py -> build/lib/setuptools
copying setuptools/py27compat.py -> build/lib/setuptools
copying setuptools/py31compat.py -> build/lib/setuptools
copying setuptools/sandbox.py -> build/lib/setuptools
copying setuptools/site-patch.py -> build/lib/setuptools
copying setuptools/ssl_support.py -> build/lib/setuptools
copying setuptools/svn_utils.py -> build/lib/setuptools
copying setuptools/unicode_utils.py -> build/lib/setuptools
copying setuptools/utils.py -> build/lib/setuptools
copying setuptools/version.py -> build/lib/setuptools
copying setuptools/windows_support.py -> build/lib/setuptools
creating build/lib/setuptools/command
copying setuptools/command/__init__.py -> build/lib/setuptools/command
copying setuptools/command/alias.py -> build/lib/setuptools/command
copying setuptools/command/bdist_egg.py -> build/lib/setuptools/command
copying setuptools/command/bdist_rpm.py -> build/lib/setuptools/command
copying setuptools/command/bdist_wininst.py -> build/lib/setuptools/command
copying setuptools/command/build_ext.py -> build/lib/setuptools/command
copying setuptools/command/build_py.py -> build/lib/setuptools/command
copying setuptools/command/develop.py -> build/lib/setuptools/command
copying setuptools/command/easy_install.py -> build/lib/setuptools/command
copying setuptools/command/egg_info.py -> build/lib/setuptools/command
copying setuptools/command/install.py -> build/lib/setuptools/command
copying setuptools/command/install_egg_info.py -> build/lib/setuptools/command
copying setuptools/command/install_lib.py -> build/lib/setuptools/command
copying setuptools/command/install_scripts.py -> build/lib/setuptools/command
copying setuptools/command/register.py -> build/lib/setuptools/command
copying setuptools/command/rotate.py -> build/lib/setuptools/command
copying setuptools/command/saveopts.py -> build/lib/setuptools/command
copying setuptools/command/sdist.py -> build/lib/setuptools/command
copying setuptools/command/setopt.py -> build/lib/setuptools/command
copying setuptools/command/test.py -> build/lib/setuptools/command
copying setuptools/command/upload_docs.py -> build/lib/setuptools/command
creating build/lib/setuptools/tests
copying setuptools/tests/__init__.py -> build/lib/setuptools/tests
copying setuptools/tests/environment.py -> build/lib/setuptools/tests
copying setuptools/tests/py26compat.py -> build/lib/setuptools/tests
copying setuptools/tests/script-with-bom.py -> build/lib/setuptools/tests
copying setuptools/tests/server.py -> build/lib/setuptools/tests
copying setuptools/tests/test_bdist_egg.py -> build/lib/setuptools/tests
copying setuptools/tests/test_build_ext.py -> build/lib/setuptools/tests
copying setuptools/tests/test_develop.py -> build/lib/setuptools/tests
copying setuptools/tests/test_dist_info.py -> build/lib/setuptools/tests
copying setuptools/tests/test_easy_install.py -> build/lib/setuptools/tests
copying setuptools/tests/test_egg_info.py -> build/lib/setuptools/tests
copying setuptools/tests/test_find_packages.py -> build/lib/setuptools/tests
copying setuptools/tests/test_integration.py -> build/lib/setuptools/tests
copying setuptools/tests/test_markerlib.py -> build/lib/setuptools/tests
copying setuptools/tests/test_msvc9compiler.py -> build/lib/setuptools/tests
copying setuptools/tests/test_packageindex.py -> build/lib/setuptools/tests
copying setuptools/tests/test_resources.py -> build/lib/setuptools/tests
copying setuptools/tests/test_sandbox.py -> build/lib/setuptools/tests
copying setuptools/tests/test_sdist.py -> build/lib/setuptools/tests
copying setuptools/tests/test_svn.py -> build/lib/setuptools/tests
copying setuptools/tests/test_test.py -> build/lib/setuptools/tests
copying setuptools/tests/test_upload_docs.py -> build/lib/setuptools/tests
copying setuptools/script (dev).tmpl -> build/lib/setuptools
copying setuptools/script.tmpl -> build/lib/setuptools
creating build/bdist.macosx-10.10-x86_64
creating build/bdist.macosx-10.10-x86_64/egg
creating build/bdist.macosx-10.10-x86_64/egg/_markerlib
copying build/lib/_markerlib/__init__.py -> build/bdist.macosx-10.10-x86_64/egg/_markerlib
copying build/lib/_markerlib/markers.py -> build/bdist.macosx-10.10-x86_64/egg/_markerlib
copying build/lib/easy_install.py -> build/bdist.macosx-10.10-x86_64/egg
copying build/lib/pkg_resources.py -> build/bdist.macosx-10.10-x86_64/egg
creating build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/__init__.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/archive_util.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
creating build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/__init__.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/alias.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/bdist_egg.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/bdist_rpm.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/bdist_wininst.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/build_ext.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/build_py.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/develop.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/easy_install.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/egg_info.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/install.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/install_egg_info.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/install_lib.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/install_scripts.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/register.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/rotate.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/saveopts.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/sdist.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/setopt.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/test.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/command/upload_docs.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/command
copying build/lib/setuptools/compat.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/depends.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/dist.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/extension.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/lib2to3_ex.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/msvc9_support.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/package_index.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/py26compat.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/py27compat.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/py31compat.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/sandbox.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/script (dev).tmpl -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/script.tmpl -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/site-patch.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/ssl_support.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/svn_utils.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
creating build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/__init__.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/environment.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/py26compat.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/script-with-bom.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/server.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_bdist_egg.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_build_ext.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_develop.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_dist_info.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_easy_install.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_egg_info.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_find_packages.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_integration.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_markerlib.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_msvc9compiler.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_packageindex.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_resources.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_sandbox.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_sdist.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_svn.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_test.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/tests/test_upload_docs.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools/tests
copying build/lib/setuptools/unicode_utils.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/utils.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/version.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
copying build/lib/setuptools/windows_support.py -> build/bdist.macosx-10.10-x86_64/egg/setuptools
byte-compiling build/bdist.macosx-10.10-x86_64/egg/_markerlib/__init__.py to __init__.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/_markerlib/markers.py to markers.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/easy_install.py to easy_install.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/pkg_resources.py to pkg_resources.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/__init__.py to __init__.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/archive_util.py to archive_util.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/__init__.py to __init__.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/alias.py to alias.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/bdist_egg.py to bdist_egg.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/bdist_rpm.py to bdist_rpm.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/bdist_wininst.py to bdist_wininst.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/build_ext.py to build_ext.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/build_py.py to build_py.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/develop.py to develop.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/easy_install.py to easy_install.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/egg_info.py to egg_info.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/install.py to install.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/install_egg_info.py to install_egg_info.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/install_lib.py to install_lib.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/install_scripts.py to install_scripts.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/register.py to register.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/rotate.py to rotate.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/saveopts.py to saveopts.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/sdist.py to sdist.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/setopt.py to setopt.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/test.py to test.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/command/upload_docs.py to upload_docs.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/compat.py to compat.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/depends.py to depends.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/dist.py to dist.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/extension.py to extension.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/lib2to3_ex.py to lib2to3_ex.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/msvc9_support.py to msvc9_support.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/package_index.py to package_index.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/py26compat.py to py26compat.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/py27compat.py to py27compat.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/py31compat.py to py31compat.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/sandbox.py to sandbox.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/site-patch.py to site-patch.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/ssl_support.py to ssl_support.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/svn_utils.py to svn_utils.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/__init__.py to __init__.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/environment.py to environment.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/py26compat.py to py26compat.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/script-with-bom.py to script-with-bom.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/server.py to server.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_bdist_egg.py to test_bdist_egg.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_build_ext.py to test_build_ext.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_develop.py to test_develop.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_dist_info.py to test_dist_info.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_easy_install.py to test_easy_install.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_egg_info.py to test_egg_info.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_find_packages.py to test_find_packages.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_integration.py to test_integration.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_markerlib.py to test_markerlib.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_msvc9compiler.py to test_msvc9compiler.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_packageindex.py to test_packageindex.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_resources.py to test_resources.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_sandbox.py to test_sandbox.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_sdist.py to test_sdist.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_svn.py to test_svn.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_test.py to test_test.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/tests/test_upload_docs.py to test_upload_docs.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/unicode_utils.py to unicode_utils.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/utils.py to utils.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/version.py to version.pyc
byte-compiling build/bdist.macosx-10.10-x86_64/egg/setuptools/windows_support.py to windows_support.pyc
creating build/bdist.macosx-10.10-x86_64/egg/EGG-INFO
copying setuptools.egg-info/PKG-INFO -> build/bdist.macosx-10.10-x86_64/egg/EGG-INFO
copying setuptools.egg-info/SOURCES.txt -> build/bdist.macosx-10.10-x86_64/egg/EGG-INFO
copying setuptools.egg-info/dependency_links.txt -> build/bdist.macosx-10.10-x86_64/egg/EGG-INFO
copying setuptools.egg-info/entry_points.txt -> build/bdist.macosx-10.10-x86_64/egg/EGG-INFO
copying setuptools.egg-info/requires.txt -> build/bdist.macosx-10.10-x86_64/egg/EGG-INFO
copying setuptools.egg-info/top_level.txt -> build/bdist.macosx-10.10-x86_64/egg/EGG-INFO
copying setuptools.egg-info/zip-safe -> build/bdist.macosx-10.10-x86_64/egg/EGG-INFO
creating dist
creating 'dist/setuptools-7.0-py2.7.egg' and adding 'build/bdist.macosx-10.10-x86_64/egg' to it
removing 'build/bdist.macosx-10.10-x86_64/egg' (and everything under it)
Processing setuptools-7.0-py2.7.egg
Copying setuptools-7.0-py2.7.egg to /usr/local/lib/python2.7/site-packages
Removing setuptools 5.4.2 from easy-install.pth file
Adding setuptools 7.0 to easy-install.pth file
Installing easy_install script to /usr/local/bin
Installing easy_install-2.7 script to /usr/local/bin

Installed /usr/local/lib/python2.7/site-packages/setuptools-7.0-py2.7.egg
Processing dependencies for setuptools==7.0
Finished processing dependencies for setuptools==7.0


Install pip命令如下:
$ easy_install pip

Log:
nb001022:~ sunjose$ easy_install pip
Searching for pip
Best match: pip 1.5.6
Processing pip-1.5.6-py2.7.egg
pip 1.5.6 is already the active version in easy-install.pth
Installing pip script to /usr/local/bin
Installing pip2.7 script to /usr/local/bin
Installing pip2 script to /usr/local/bin

Using /usr/local/lib/python2.7/site-packages/pip-1.5.6-py2.7.egg
Processing dependencies for pip
Finished processing dependencies for pip


Step 5: Install Virtual Environments


命令如下:
$ pip install virtualenv

Log:
nb001022:~ sunjose$ pip install virtualenv
Downloading/unpacking virtualenv
Downloading virtualenv-1.11.6-py2.py3-none-any.whl (1.6MB): 1.6MB downloaded
Installing collected packages: virtualenv
Successfully installed virtualenv
Cleaning up...
nb001022:~ sunjose$


 Related Posts with Thumbnails 

0 意見 :

張貼留言