[Numpy-discussion] Which Python to Use on OSX, Was: 1.1.0 OSX Installer Fails Under 10.5.3?

Vincent Noel vincent.noel@gmail....
Wed Jun 4 05:02:30 CDT 2008


Another way to do things which might be useful, if you're not afraid
to modify the system python install, (more-or-less suggested at
http://wiki.python.org/moin/MacPython/Leopard), is to create a
symbolic link to make everything look as if you had installed
macpython, ie

sudo ln -s /System/Library/Frameworks/Python.framework/
/Library/Frameworks/Python.framework

Since, according to the MacPython page, the Leopard python is the same
as the MacPython (2.5.1),
all the packages you'll find on the web that suppose you have
MacPython installed should be happy (easy_installing eggs works fine
as well). HOWEVER you gotta add

export PATH=/Library/Frameworks/Python.framework/Versions/Current/bin:$PATH
export PYTHONPATH=/Library/Frameworks/Python.framework/Versions/Current/lib/python2.5/site-packages

in your ~/.bash_profile, otherwise the (older) system numpy will get
used. This is because the system python adds /System/.../2.5/Extras in
front of the /site-packages directory (weird, but hey).

Following this road, I was able to install NumPy 1.1, matplotlib 0.98
and ipython without any problem -- the best thing is that the system
wxPython is used, when it can be a PITA to setup correctly through
other ways. As was said by others, I guess there might be unforeseen
consequences, but everything seems to work fine for now.

Cheers
Vincent


On Wed, Jun 4, 2008 at 10:25 AM, J. Stark <j.stark@imperial.ac.uk> wrote:
> Robert,
>
> I see your point, but why not just install a separate NumPy to run
> with the system Python? That is what I have always done in the past
> without problems.
>
> I guess I always feel a sense of uncertainty with having two separate
> Python installations as to which actually gets used in any particular
> situation. I appreciate that for experts who use Python daily, this
> isn't an issue, but for someone like myself who may have gaps of
> several months between projects that use Python, this is a real issue
> as I forget those kinds of subtleties.
>
> J.
>
>>On Wed, Jun 4, 2008 at 1:48 AM, J. Stark <j.stark@imperial.ac.uk> wrote:
>>>  On this topic, I would be interested to hear people's advice on using
>>>  the system provided Python v an independent install. In 25 years of
>>>  using Macs I have learned through several painful lessons that its
>>>  wise to customize the system as little as possible: this minimizes
>>>  both conflicts and reduces problems when doing system upgrades. I
>>>  have therefore always used the default Python provided by OSX, so far
>>>  with no obvious disadvantages for the types of scripts I use
>>>  (primarily home written SciPy scientific code). However, I note that
>>>  many people run either the pythomac.org distribution, or the
>>>  ActiveState. What are the advantages to this?
>>
>>By installing a separate Python, you are actually customizing the
>>system *less* than if you used the system Python and installed a bunch
>>of extra packages. Parts of Apple's software uses the system Python.
>>If you upgrade packages inside there (like numpy!) you might run into
>>problems.
>>
>>--
>>Robert Kern
>>
>>"I have come to believe that the whole world is an enigma, a harmless
>>enigma that is made terrible by our own mad attempt to interpret it as
>>though it had an underlying truth."
>>  -- Umberto Eco
> _______________________________________________
> Numpy-discussion mailing list
> Numpy-discussion@scipy.org
> http://projects.scipy.org/mailman/listinfo/numpy-discussion
>


More information about the Numpy-discussion mailing list