[Numpy-discussion] Which Python to use for Mac binaries

Chris Barker - NOAA Federal chris.barker at noaa.gov
Mon Jan 7 13:35:28 EST 2013


On Mon, Jan 7, 2013 at 10:19 AM, Robert Lupton the Good
<rhl at astro.princeton.edu> wrote:
> I am sympathetic with this attitude ("Avoid using system Python for anything"), but I don't think it's the right one.  For example, the project I'm working on (HSC/LSST for astrofolk) is using python/C++ for astronomical imaging, and we expect to have the code running on a significant number of end-user laptops.   If the instructions start out with:
>         0. Install a new version of python
> it's a significant barrier.  What if they've already involved other packages into the system python?

What if they've already installed other packages into the python.org
python? or fink? macports? or homebrew? or build-your own?

Unfortunately, python on the Mac is a bit of a mess--there are WAY too
many ways to get Python working. It's great that Apple provides python
as part of the system, but unfortunately:

* Apple has NEVER upgraded python within a OS-X version.
* Apple includes proprietary code with their build, so you are not
allowed to re-distribute it (i.e. py2app).

As a result, the MacPython community can not declare that Apple's
build is the primary one we want to support.

This has been hashed out a bunch on the PythonMac list, and there was
more or less consensus that the python.org builds would be the ones
that we as a community try to support with binaries, etc.

All that being said, for the most part, the Apple builds and
python.org builds are compatible. Robin Dunn has worked out a way to
build installers for wxPython that work with both the python.org and
Apple builds -- putting everything in /usr/local, and *.pth files in
both of the python builds -- it's a hack, but it works, that may be an
approach worth taking.

It also wouldn't be that hard to build a duplicate set of binaries,
but it does get to be a lot for users to figure out what they need.

> Yes, I know that you can have more than one python/compiler suite installed simultaneously, but that's not something for casual users to have to get involved in.

Installing a binary from python.org is not much of a challenge for
anyone that is installing anything, actually.

It's true that it's a pain for users to get a system all set up, then
find out that to use the numpy binaries (or anything else...) they
need to start over with a new python -- that's why we in the MacPython
community encourage everyone to build binaries for the python.org
builds -- standards are good, but standardizing on the Apple builds
isn't viable.

(NOTE: the "decision" was made a few years back -- it may be worth
re-visiting, but I'm pretty sure that Apple's build is still not
suitable as the default choice)

-Chris


-- 

Christopher Barker, Ph.D.
Oceanographer

Emergency Response Division
NOAA/NOS/OR&R            (206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115       (206) 526-6317   main reception

Chris.Barker at noaa.gov



More information about the NumPy-Discussion mailing list