cpython/Mac
Jack Jansen 5f884c05d1 Refer to the sourceforge site for gusi downloads. 2000-12-12 22:14:14 +00:00
..
Build Drag moved to core toolbox modules (Win uses it). 2000-12-12 21:53:14 +00:00
Compat Test for TARGET_API_MAC_CARBON with #if in stead of #ifdef. 2000-07-14 22:37:27 +00:00
Contrib Put all AE constants into AppleEvents.py 2000-12-12 22:13:36 +00:00
Demo Refer to the sourceforge site for gusi downloads. 2000-12-12 22:14:14 +00:00
Distributions Removed, no longer pertinent. 2000-10-22 21:55:03 +00:00
IDE scripts Initial checkin of IDE scripts. (jvr) 1999-09-26 12:25:06 +00:00
Include Qdoffs now exports the GWorldObj_{New,Convert} functions. 2000-12-12 22:13:03 +00:00
Lib Regenerated from Universal Headers 3.3.2 2000-12-12 22:08:00 +00:00
MPW moved bgen to Tools 1995-03-10 15:12:23 +00:00
Modules More toolbox modules adapted to Universal Headers 3.3.2. 2000-12-12 22:10:21 +00:00
PlugIns Starting on the new project/plugin structure. Far from complete... 1999-01-28 13:42:55 +00:00
Python Added a c2pstrcpy() function. 2000-12-12 22:12:14 +00:00
Resources Add Numerical:Lib:Packages to sys.path. A workaround for distutils not working. 2000-10-19 22:00:01 +00:00
Tools more edits to make the text fit (jvr) 2000-10-20 07:49:00 +00:00
Unsupported Moved to Unsupported. 2000-09-12 20:24:50 +00:00
mwerks Added USE_IC and USE_PYEXPAT 2000-09-14 13:33:01 +00:00
scripts Qdoffs now exports GWorld new/convert, and Qt uses them. 2000-12-12 21:53:48 +00:00
tclmods Put in an earlier include of sys/signal.h (within ifdef USE_GUSI) to forestal a multiple define. 2000-07-24 19:42:53 +00:00
HISTORY Changed release note structure: 1997-05-28 12:01:14 +00:00
ReadMe Added a note about removing preferences and .pyc files when you move the Python installation. 2000-11-14 20:37:37 +00:00
ReadMe-dev Updated because developer option isn't distributed separately anymore. 2000-10-22 21:57:12 +00:00
ReadMe-src Updated for 1.5.2b1 (better late than never:-) 1999-01-21 12:50:47 +00:00
Relnotes Ready for 2.0 2000-10-19 21:58:27 +00:00
_checkversion.py Final version used for 2.0 distribution. 2000-10-22 21:54:33 +00:00
errno_unix.h Unix functionality expected by python but missing from CodeWarrior 1994-12-14 14:04:55 +00:00
fopenRF.c Think 6.0 version 1995-01-02 19:13:30 +00:00
mkapplet.py In interactive mode ask for output file 1995-02-27 16:19:07 +00:00
mwerksglue.c Unix functionality expected by python but missing from CodeWarrior 1994-12-14 14:04:55 +00:00

ReadMe

How to install Python 2.0 on your Macintosh
-------------------------------------------

If this is your first encounter with Python: you definitely need the
common user documentation (common to all platforms). You can find this
(in various forms) on www.pythonlabs.com, www.python.org and
ftp.python.org. Through there, or via
http://www.cwi.nl/~jack/macpython.html you can also find the most recent
MacPython distribution.

Mac-specific documentation is included in this distribution in folder
Mac:Demo. The documentation is sparse, but it will have to serve for
now. The documentation is in HTML format, start with index.html.

Caveats
-------
This is a final candidate version, so use with caution, and please report
problems as soon as possible, to pythonmac-sig@python.org.

Aside from the general new Python 2.0 features (compared to 1.5.2, there
was no 1.6 for the macintosh) like unicode support the main new features
of this MacPython release is support for multithreading. This has had
some preliminary testing, but please report any success or failure on
the mailing list.

This installer installs MacPython for PowerPC only, if you really want
68k support you will have to stay with 1.5.2. Or, if you are willing to
invest the time and have access to CodeWarrior you are welcome to try
and build a 68k distribution, most of the projects and sources are
reasonably up to date (May 2000). Contact me for details.

This version of Python expects a recent version of Appearance, so it may
be that users with pre MacOS 8.5 systems have trouble running it. If
that is the case try getting CarbonLib from Apple, I am told this
includes Appearance and NavServices. You may also have to disable the
"Use navservices" preference for best results.

What to install
---------------

This installer is PPC only: too many new MacOS features are not
available on 68K, and doing workarounds, even just #ifdeffing in the
code, is too much work for me right now. If someone wants to revive
68K-MacPython: please do so. The project files still contain the 68K
targets (they're simply skipped by the build process) so all that is
needed is CodeWarrior, a source distribution and commitment.

The optional parts in this distribution are
- TK+PIL: Tkinter and support modules, plus Imaging, the Python image manipulation 
  package (allows you to read, write and display images and do lots of operations on them).
- img: another imaging package. Has more file format support and is faster
  than imaging, but has only limited operations on images. There is a bridge
  between the packages.
- Numeric: the LLNL Numeric Python extension. All sorts of nifty operations
  on matrices and such. This is the most recent version from the sourceforge archive.
- Developers kit: all header files and some tools and sample projects to get you started on
  writing Python extensions if you have CodeWarrior.
All these except the DevKit are installed with Easy Install.

After the installer finishes it automatically launches the
ConfigurePython applet, to finish configuration of your Python.
If you have previously installed another copy of 2.0 you should manually
remove your preference file first (but no such action is needed for installing
beside older MacPythons, and they will live together happily).

Moving your Python installation after installing is generally not a good idea.
If you have to do this anyway you should remove your preference file, run
ConfigurePython and remove all .pyc files.

If you don't have enough memory: the sizes choosen are somewhat
arbitrary. Try lowering the application sizes in the finder "get info"
window, and seeing whether the resulting python is still usable. Some
modules (Tkinter comes to mind) need a lot of memory, so it may also be
necessary to increase the application size.

After installing
----------------

It is probably a good idea to run the automatic tests. Start
Python and "import test.autotest". 

Three tests will fail on the mac, all with MemoryErrors: test_sha,
test_longexp and test_zlib. If you increase the PythonInterpreter memory
partition size they will pass. It will, however, print some messages
about optional features not supported. You should not worry about these,
they are modules that are supported by Python on other platforms. Also,
if you didn't run compileall before autotesting you may run out of
memory the first time you run the tests. test_socket may also fail if
you have no internet connection. Please also read the Relnotes file for
other minor problems with this distribution.

Using Python is most easily done from the IDE, which has a builtin editor,
debugger and other goodies. The alternative is to use PythonInterpreter,
which is the lowlevel interpreter with a console-window only (similar to Unix
Python).

If your program uses Tkinter you MUST run it under PythonInterpreter, Tkinter
and IDE are incompatible and your program will fail in strange ways.

Uninstalling
------------

Two items are installed in the system folder: the interpreter shared
library "PythonCore 2.0" lives in the Extensions folder and the
"Python 2.0 Preferences" file in the Python subfolder in the
Preferences folder. All the rest of Python lives in the folder you
installed in.

Things to see
-------------

Start off at Mac:Demo:index.html. Read at least the first few sections.

There are also some interesting files in the "Relnotes" folder that may
contain useful information. There is also a first stab at documentation
(plus examples) in the Mac:Demo folder. The toplevel Demo folder has
machine-independent demos. 
The Mac:Lib:test folder also has some programs that show simple
capabilities of various modules.

The ":Mac:scripts" folder has some sample scripts. Some are useful, some are
just interesting to look at to see how various things work. The MkDistr,
mkapplet and fullbuild scripts (plus the ones mentioned above) may help
you to understand how to use AppleEvents and various other toolboxes
from python.

Other mac-specific goodies can be found in :Mac:Tools, of which the IDE sources
and a CGI framework deserve special mention.

The 'img' group of modules, which handles I/O of many different image
formats is included, but without documentation.  You can find docs at
ftp://ftp.cwi.nl/pub/jack/python/img (or somewhere around there).

Finally there is a Mac:Contrib folder which contains some contributed
software.

Upgrading from older Python releases
------------------------------------

Since release 1.4 Python releases are independent of each other, with
separate Preferences files, shared library names, etc. The good news is
that this means you can keep your older version around if you are unsure
whether to upgrade. The bad news is that your old preference settings
are lost and you have to set them again.

After you are satisfied that 2.0 works as expected you can trash
anything in the system folder that has "python" in the name and not
"2.0".

The installer
-------------

The installer for this product was created using Installer VISE
from MindVision Software. For more information on Installer VISE,
contact:
MindVision Software
7201 North 7th Street
Lincoln, NE 68521-8913
Voice: 402-477-3269
Fax: 402-477-1395
Internet: mindvision@mindvision.com
http://www.mindvision.com

Just van Rossum <just@letterror.nl> created the initial version of the
installer (with Installer Vise Lite), and Jack worked from there.

Thanks!
-------

Thanks go to the whole Python community with Guido in the lead, of
course. Mac-specific thanks go to the pythonmac-sig, Just van Rossum,
Corran Webster, Tony Ingraldi, Erik van Blokland, Bill Bedford, Chris
Stern, Gordon Worley, Oliver Steele, M. Papillon, Steven Majewski, David
Goodger, Chris Barker, Luc Lefebvre, Tattoo Mabonzo K., Russell Finn,
Tom Bridgman and all the other people who provided feedback, code or both!

MacPython includes waste, a TextEdit replacement which is (c) 1998 Marco Piovanelli.

Feedback
--------

Send bug reports, suggestions, contributions and fanmail to
<jack@cwi.nl>. However, a better way to discuss MacPython is to join the
<pythonmac-sig@python.org> mailing list, which is explicitly meant for
this purpose.

Alternatively, you can try sending to comp.lang.python or
python-list@cwi.nl, but since I read the newsgroup, not the mailinglist,
I may miss it there (but other people may know quite a bit more than me
anyway:-).

Jack Jansen
Oratrix Development BV
Valeriusplein 30
Amsterdam
the Netherlands

<jack@cwi.nl>, http://www.cwi.nl/~jack