mirror of
https://github.com/kennethreitz/python-guide.git
synced 2026-06-05 14:50:19 +00:00
Merge pull request #749 from tdsmith/osx-install
Update OS X install guidance
This commit is contained in:
@@ -21,20 +21,18 @@ Doing it Right
|
||||
|
||||
Let's install a real version of Python.
|
||||
|
||||
Before installing Python, you'll need to install GCC. GCC can be obtained
|
||||
by downloading `Xcode <http://developer.apple.com/xcode/>`_, the smaller
|
||||
`Command Line Tools <https://developer.apple.com/downloads/>`_ (must have an
|
||||
Apple account) or the even smaller `OSX-GCC-Installer <https://github.com/kennethreitz/osx-gcc-installer#readme>`_
|
||||
Before installing Python, you'll need to install a C compiler. The fastest way
|
||||
is to install the Xcode Command Line Tools by running
|
||||
``xcode-select --install``. You can also download the full version of
|
||||
`Xcode <http://developer.apple.com/xcode/>`_ from the Mac App Store, or the
|
||||
minimal but unofficial
|
||||
`OSX-GCC-Installer <https://github.com/kennethreitz/osx-gcc-installer#readme>`_
|
||||
package.
|
||||
|
||||
.. note::
|
||||
If you already have Xcode installed, do not install OSX-GCC-Installer.
|
||||
In combination, the software can cause issues that are difficult to
|
||||
diagnose.
|
||||
|
||||
.. note::
|
||||
If you perform a fresh install of Xcode, you will also need to add the
|
||||
commandline tools by running ``xcode-select --install`` on the terminal.
|
||||
If you already have Xcode installed or plan to use Homebrew, do not install
|
||||
OSX-GCC-Installer. In combination, the software can cause issues that are
|
||||
difficult to diagnose.
|
||||
|
||||
While OS X comes with a large number of UNIX utilities, those familiar with
|
||||
Linux systems will notice one key component missing: a decent package manager.
|
||||
@@ -63,6 +61,12 @@ Now, we can install Python 2.7:
|
||||
|
||||
$ brew install python
|
||||
|
||||
or Python 3:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
$ brew install python3
|
||||
|
||||
This will take a minute or two.
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user