[Pythonmac-SIG] Upgrading to Python 2.4 and handling packages (e.g. Numeric, wxPython, etc.)
Louis Pecora
pecora at anvil.nrl.navy.mil
Thu Mar 23 18:26:52 CET 2006
Info on converting over installed Python packages to non-Apple Python
for those who are newbies or are not gurus (includes me):
Bob Ippolito was right. When you upgrade to a non-Apple python you have
to re-install all the "add-on" packages like Numeric. You also have to
set your paths in the Environment.plist in ~/.MacOSX since any .pth
files you formerly used in the Apple distribution directories will not
be used in the upgrade. You can get new versions of packages to install
from Bob Ippolito's site: http://pythonmac.org/packages/. Just be sure
to choose the Framework builds for the system you have on your machine
(Panther or Tiger).
Many thanks to Bob Ippolito for supplying those packages.
If anyone upgrades and needs to use the kinds.py package (which gives
platform limits and sizes for floats, ints, etc.) see below for more
info on how to get this to work in Python 2.4.
Reinstalling the kinds package. I assume you already have the package
in your Python files directory. You need to reinstall it after you
upgrade to Python 2.4. Do this by opening the terminal, cd to the kinds
folder and type
sudo python setup.py install
give the admin password when prompted.
That puts the needed files in the right place down in the /Library
directory. But you have to set up a path down in that directory so when
you run Python it can find the files it needs for kinds (this is in
addition to adding the path to the original kinds source directory where
you ran the install script above). Create the file kinds.pth with the
single line in it,
kinds
Save and move this to the directory
Drive/Library/Framework/Python.framework/Version/2.4/lib/python2.4/site-packages.
That should do it.
--
Cheers,
Lou Pecora
Code 6362
Naval Research Lab
Washington, DC 20375
USA
Ph: +202-767-6002
email: pecora at anvil.nrl.navy.mil
More information about the Pythonmac-SIG
mailing list