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

Ondřej Čertík ondrej.certik@gmail....
Wed Jan 9 20:55:39 CST 2013


On Tue, Jan 8, 2013 at 8:45 AM, Chris Barker - NOAA Federal
<chris.barker@noaa.gov> wrote:
> On Mon, Jan 7, 2013 at 10:23 PM, Ondřej Čertík <ondrej.certik@gmail.com> wrote:
>>> http://www.commandlinefu.com/commands/view/2031/install-an-mpkg-from-the-command-line-on-osx
>>
>> This requires root access. Without sudo, I get:
>>
>> $ installer -pkg /Volumes/Python\ 2.7.3/Python.mpkg/ -target ondrej
>> installer: This package requires authentication to install.
>>
>> and since I don't have root access, it doesn't work.
>>
>> So one way around it would be to install python from source, that
>> shouldn't require root access.
>
> hmm -- this all may be a trick -- both the *.mpkg and the standard
> build put everything in /Library/Frameworks/Python -- which is where
> it belongs. Bu tif you need root access to write there, then there is
> a problem. I'm sure a non-root build could put everything in the
> users' home directory, then packages built against that would have
> their paths messed up.

Right.

>
> What's odd is that I'm pretty sure I've been able to point+click
> install those without sudo...(I could recall incorrectly).
>
> This would be a good question for the pythonmac list -- low traffic,
> but there are some very smart and helpful folks there:
>
> http://mail.python.org/mailman/listinfo/pythonmac-sig
>
>
>>>> But I am not currently sure what to do with it. The Python.mpkg
>>>> directory seems to contain the sources.
>
> It should be possible to unpack a mpkg by hand, but it contains both
> the contents, and various instal scripts, so that seems like a really
> ugly solution.

Yep.

In the meantime, the hard drive on Vincent's box failed, so he
reinstalled the box completely.
Also he explained to me a lot of Mac things over the phone, so I think
I now understand what is going on with the dmg.

As such, I have updated my instructions in my release helper repo:

https://github.com/certik/numpy-vendor

by the following paragraph:

"""
First prepare the Mac build box as follows:

* Install Python 2.5, 2.6, 2.7 from python.org using the dmg disk image
* Install setuptools and bdist_mpkg into all these Pythons
* Install Paver into the default Python

Tip: Add the /Library/Frameworks/Python.framework directory into git
and commit after each installation of any package or Python. That way
you can easily remove temporary installations.
"""

And you need sudo access to do those. If your user is an admin, then
it can do it, otherwise it can't.
So one can only use a Mac, which has the above setup installed. With
that, my Fabfile can then do the rest.

So I just built the following binaries:

numpy-1.7.0rc1-py2.5-python.org-macosx10.3.dmg
numpy-1.7.0rc1-py2.6-python.org-macosx10.3.dmg
numpy-1.7.0rc1-py2.7-python.org-macosx10.3.dmg

and uploaded to:

https://sourceforge.net/projects/numpy/files/NumPy/1.7.0rc1/


So I think we are all set here. Ralf, would you be willing to build
the final binary on 10.6? I don't think you have to do it for this
rc1, but I am going to release rc2 now and for that it would be nice
to have it.

Ondrej


More information about the NumPy-Discussion mailing list