[Pythonmac-SIG] Python for MPW?

Jack Jansen Jack.Jansen@cwi.nl
Wed, 19 Aug 1998 10:25:01 +0200


> Hello,
> 
> Does anyone know where I might be able to download a version of python that
> will run in the MPW environment (as an MPW tool)?  I don't need the latest
> version of python or loads of extensions.  Just the basic interpreter and
> things like the os and string modules would be sufficient.
> 
> I may attempt to produce an MPW version of python myself if there isn't one
> already available.

Python ran under MPW many many years ago, but it hasn't been tried in ages. I 
you do try to build it I would be interested in the results. There are #ifdef 
MPW sprinkled through the code, but (1) definitely not in all places they're 
needed, (2) they're both for compiler dependencies (and I assume you'll be 
using the MW compilers, not the old Apple compilers) and for runtime 
dependencies and (3) the code inside the MPW ifdefs hasn't been looked at for 
ages.

I think the best starting place would be the PythonStandSmall project, which 
builds a "minimal useful" Python. You may have to get rid of GUSI (not sure 
whether that works under MPW) and you'll probably have to compile with MPW 
newlines. It would probably also be a good idea to immedeately change the 
version string (an STR in one of the resource files, I think pythonpath.rsrc), 
as you want a different preferences file for sys.path initialisation  because 
you can't share dynamic modules (and, if you use MPW newlines, not even .py 
files either).

I think the project would definitely be doable, but not trivial.
--
Jack Jansen             | ++++ stop the execution of Mumia Abu-Jamal ++++
Jack.Jansen@cwi.nl      | ++++ if you agree copy these lines to your sig ++++
http://www.cwi.nl/~jack | see http://www.xs4all.nl/~tank/spg-l/sigaction.htm