Updated for 2.1b2 distribution.
[python/dscho.git] / Mac / ReadMe
blobaa38579fea75288e56a1ea38c3e207f82456c65e
1 How to install Python 2.1b2 on your Macintosh
2 ---------------------------------------------
4 This is a beta MacPython that can run on classic MacOS (from 8.1
5 onwards) and natively on MacOSX. The installer tries to work out whether you can
6 use the Carbon version or not. This is also the first MacPython distribution
7 to be packaged as an active installer, which only downloads the parts you actually
8 need. Let me hear about problems in these areas.
10 You should definitely read the Relnotes file too.
12 A special note about the active installer: do not background it, it will hang
13 your machine. This is a general problem with Vise active installers, MindVision
14 are working on it.
16 ------
18 If this is your first encounter with Python: you definitely need the
19 common user documentation (common to all platforms). You can find this
20 (in various forms) on www.pythonlabs.com, www.python.org and
21 ftp.python.org. Through there, or via
22 http://www.cwi.nl/~jack/macpython.html you can also find the most recent
23 MacPython distribution.
25 Mac-specific documentation is included in this distribution in folder
26 Mac:Demo. The documentation is sparse, but it will have to serve for
27 now. The documentation is in HTML format, start with index.html.
29 Caveats
30 -------
31 Aside from the general new Python 2.1 features compared to 2.0 the main
32 feature of this release is Carbon support.
34 This installer installs MacPython for classic PPC MacOS, MacPython for Carbon
35 (OS X, OS 9 or OS8 with CarbonLib installed) or both, depending on your
36 configuration. By selecting custom install you can bypass these tests and
37 install what you want.
39 If you want 68k support you will have to stay with MacPython 1.5.2.
41 What to install
42 ---------------
44 The optional parts in this distribution are
45 - TK+PIL: Tkinter and support modules, plus Imaging, the Python image manipulation 
46   package (allows you to read, write and display images and do lots of operations on them).
47   For Carbon MacPython you only get PIL: there is no Tcl/Tk for Carbon yet.
48   This is the reason Classic MacPython is also installed on MacOSX: it allows you
49   to run Tkinter applications, albeit in the MacOS9 box.
50 - img: another imaging package. Has more file format support and is faster
51   than imaging, but has only limited operations on images. There is a bridge
52   between the packages.
53 - Numeric: the LLNL Numeric Python extension. All sorts of nifty operations
54   on matrices and such. This is the most recent version from the sourceforge archive.
55   Numeric has moved from Extensions to :Lib:site-python, by the way, see the release
56   notes.
57 - Developers kit: all header files and some tools and sample projects to get you started on
58   writing Python extensions if you have CodeWarrior.
59 All these except the DevKit are installed with Easy Install.
61 After the installer finishes it automatically launches the appropriate
62 ConfigurePython applet, to finish configuration of your Python. If you run MacOS9 or later
63 (or 8 with CarbonLib installed) you can switch back and forth between the classic and
64 Carbon versions of Python by running either ConfigurePythonClassic or ConfigurePythonCarbon.
66 Moving your Python installation after installing is generally not a good idea.
67 If you have to do this anyway you should remove your preference file, run
68 ConfigurePython and remove all .pyc files. (there's a script zappyc.py that does
69 the latter).
71 If you don't have enough memory: the sizes choosen are somewhat
72 arbitrary, and they are as high as they are so that test.autotest runs with fewer
73 problems. An average Python program can make do with much less memory.
74 Try lowering the application sizes in the finder "get info"
75 window, and seeing whether the resulting python is still usable.
77 After installing
78 ----------------
80 It is probably a good idea to run the automatic tests. Start
81 Python and "import test.autotest". 
83 Two tests will fail on MacOS9, both with MemoryErrors:
84 test_longexp and test_zlib (on MacOSX nothing should fail).
86 If you increase the PythonInterpreter memory
87 partition size they will pass (but for longexp you have to increase it by an
88 incredible amount). It will, however, print some messages
89 about optional features not supported. You should not worry about these,
90 they are modules that are supported by Python on other platforms. Also,
91 if you didn't run compileall before autotesting you may run out of
92 memory the first time you run the tests. test_socket may also fail if
93 you have no internet connection. Please also read the Relnotes file for
94 other minor problems with this distribution.
96 Using Python is most easily done from the IDE, which has a builtin editor,
97 debugger and other goodies. The alternative is to use PythonInterpreter,
98 which is the lowlevel interpreter with a console-window only (similar to Unix
99 Python).
101 If your program uses Tkinter you MUST run it under PythonInterpreter, Tkinter
102 and IDE are incompatible and your program will fail in strange ways.
104 Uninstalling
105 ------------
107 Two items are installed in the system folder: the interpreter shared
108 libraries PythonCore and PythonCoreCarbon lives in the Extensions folder and the
109 "Python 2.1b1 Preferences" file in the Python subfolder in the
110 Preferences folder. All the rest of Python lives in the folder you
111 installed in.
113 Things to see
114 -------------
116 Start off at Mac:Demo:index.html. Read at least the first few sections.
118 There are also some interesting files in the "Relnotes" folder that may
119 contain useful information. There is also a first stab at documentation
120 (plus examples) in the Mac:Demo folder. The toplevel Demo folder has
121 machine-independent demos. 
122 The Mac:Lib:test folder also has some programs that show simple
123 capabilities of various modules.
125 The ":Mac:scripts" folder has some sample scripts. Some are useful, some are
126 just interesting to look at to see how various things work. The MkDistr,
127 mkapplet and fullbuild scripts (plus the ones mentioned above) may help
128 you to understand how to use AppleEvents and various other toolboxes
129 from python.
131 Other mac-specific goodies can be found in :Mac:Tools, of which the IDE sources
132 and a CGI framework deserve special mention.
134 The 'img' group of modules, which handles I/O of many different image
135 formats is included, but without documentation.  You can find docs at
136 ftp://ftp.cwi.nl/pub/jack/python/img (or somewhere around there).
138 Finally there is a Mac:Contrib folder which contains some contributed
139 software.
141 Upgrading from older Python releases
142 ------------------------------------
144 Python releases are independent of each other, with
145 separate Preferences files, shared library names, etc. The good news is
146 that this means you can keep your older version around if you are unsure
147 whether to upgrade. The bad news is that your old preference settings
148 are lost and you have to set them again.
150 After you are satisfied that 2.1 works as expected you can trash
151 anything in the system folder that has "python" in the name and not
152 "2.1".
154 As of 2.1 the ConfigurePython applets will try to detect incompatible preferences
155 files and offer to remove them. This means that re-running ConfigurePython after
156 a second install of the same MacPython version (or after moving the Python folder)
157 should fix things up correctly.
159 The installer
160 -------------
162 The installer for this product was created using Installer VISE
163 from MindVision Software. For more information on Installer VISE,
164 contact:
165 MindVision Software
166 7201 North 7th Street
167 Lincoln, NE 68521-8913
168 Voice: 402-477-3269
169 Fax: 402-477-1395
170 Internet: mindvision@mindvision.com
171 http://www.mindvision.com
173 Just van Rossum <just@letterror.nl> created the initial version of the
174 installer (with Installer Vise Lite), and Jack worked from there.
176 Thanks!
177 -------
179 Thanks go to the whole Python community with Guido in the lead, of
180 course. Mac-specific thanks go to the pythonmac-sig, Just van Rossum,
181 Corran Webster, Tony Ingraldi, Erik van Blokland, Bill Bedford, Chris
182 Stern, Gordon Worley, Oliver Steele, M. Papillon, Steven Majewski, David
183 Goodger, Chris Barker, Luc Lefebvre, Tattoo Mabonzo K., Russell Finn,
184 Tom Bridgman Russel Owen and all the other people who provided feedback,
185 code or both!
187 MacPython includes waste, a TextEdit replacement which is (c) 1998 Marco Piovanelli.
189 A special mention is deserved by Matthias Neeracher, who has written the brilliant
190 unix-compatible GUSI I/O library, without which MacPython would not have sockets
191 or select, and to Alexandre Parenteau, who has ported this library to Carbon.
193 Feedback
194 --------
196 Send bug reports, suggestions, contributions and fanmail to
197 <jack@cwi.nl>. However, a better way to discuss MacPython is to join the
198 <pythonmac-sig@python.org> mailing list, which is explicitly meant for
199 this purpose.
202 Jack Jansen
203 Oratrix Development BV
204 Valeriusplein 30
205 Amsterdam
206 the Netherlands
208 <jack@cwi.nl>, http://www.cwi.nl/~jack