[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] BUG: mac OSX can only install into python.org python.



The rationale for not installing into the system python that I recall was because apple had been using the system python as a required OS component for correct system functionality (some os scripts use python), and "messing" with the system python could potentially mess up people's systems. I don't think there is any known case of where installing pygame specifically into the system python actually does result in such a situation, cause pygame doesn't touch anything outside of the pygame package, but it was one of those "better safe than sorry" things.

As far as having installers that work with the system python, the only way I know of that bdist_mpkg easily lets you do that, is by running setup.py from the system python itself, and then what you get is an installer that installs to system python, but won't install anywhere else. Basically bdist_mpkg seems to be set up to install to the same config you ran it with. I'm not sure the original intent of that behavior, but it seems to make some sense from a testing perspective.

If there's a setup,py option to make an installer that can go to either the system python or the framework one, I'm not sure what it is, but if a numpy installer is doing what we want, we should take a look at it's setup,py

As far as multiple versions of a system python existing, I hadn't heard of apple adding a 2.6 or 3.0 to the mix of system pythons- the machines I have access to just have the leopard 2.5 (and the tiger 2.3 if they were upgraded), what situation adds those newer pythons to the /System/Library/Frameworks/Python.framework/Versions dirs?

Finally, as far as detecting other pythons we might be compatible, when it comes to OS X installs, I'm not aware of any other install locations other than /System/Library/Frameworks and /Library/Frameworks or any other python source trees other than apple's fork or the official python.org one. Did you have an example in mind of another python install on Mac OS X that pygame doesn't target now that we'd want to add detection for?

On Mon, Jun 1, 2009 at 5:20 AM, René Dudfield <renesd@xxxxxxxxx> wrote:
Hi,

the mac OSX installer should be able to install into the apple python
site-packages directory.

Currently it won't let you.  Since we won't be overwriting anything of
apples, and also Apple have proved that they don't touch their system
python very much at all, I think this is ok to do.  The original
rational for it was that apple could possible remove older pythons.
However over a number of releases they have shown that they keep the
old version of python around (eg 2.5), and install a new version (2.6
and 3.0 I believe).

This will also fix one of the longest running issues people have on
OSX installing pygame... since most people assume they already have
python, so why should they install another copy from python.org.

So... how do we make allow the user to select which python they
install into?   I know numpy does it somehow... but not sure how
exactly.

Our use of bdist_mpkg is what we need to change to allow it... I think.
   looks like bdist_mpkg has had some new releases recently too...
http://pypi.python.org/pypi/bdist_mpkg/

Looks like it has fixed the bug where it was calling the python.org
python "System" python... which people assumed was the Apple python.


Anyone have any ideas how this can be done?

Is it ok to do, do you think?  What do you reckon Brian?


Would be nice if we could detect other mac pythons that we are
compatible with too.


cheers,