Jack Jansen | 8a6cdcc | 2000-09-10 12:02:28 +0000 | [diff] [blame^] | 1 | How to install Python 2.0b1 on your Macintosh |
Jack Jansen | ffd61a6 | 2000-04-09 18:37:50 +0000 | [diff] [blame] | 2 | --------------------------------------------- |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 3 | |
| 4 | If this is your first encounter with Python: you definitely need the |
| 5 | common user documentation (common to all platforms). You can find this |
| 6 | (in various forms) on www.python.org and ftp.python.org. Through |
| 7 | there, or via http://www.cwi.nl/~jack/macpython.html you can also find |
| 8 | the most recent MacPython distribution. |
| 9 | |
| 10 | Mac-specific documentation is included in this distribution in folder |
| 11 | Mac:Demo. The documentation is sparse, but it will have to serve for |
| 12 | now. The documentation is in HTML format, start with index.html. |
| 13 | |
Jack Jansen | d0ddb66 | 1998-04-27 15:14:36 +0000 | [diff] [blame] | 14 | Caveats |
| 15 | ------- |
Jack Jansen | 8a6cdcc | 2000-09-10 12:02:28 +0000 | [diff] [blame^] | 16 | This is a beta version, so use with caution. |
Jack Jansen | ffd61a6 | 2000-04-09 18:37:50 +0000 | [diff] [blame] | 17 | |
Jack Jansen | 8a6cdcc | 2000-09-10 12:02:28 +0000 | [diff] [blame^] | 18 | Aside from the general new Python 2.0 features (compared to 1.5.2, there |
| 19 | was no 1.6 for the macintosh) like unicode support the main new features |
| 20 | of this MacPython release is support for multithreading. This has had |
| 21 | some preliminary testing, but please report any success or failure on |
| 22 | the mailing list. |
Jack Jansen | ffd61a6 | 2000-04-09 18:37:50 +0000 | [diff] [blame] | 23 | |
Jack Jansen | 8a6cdcc | 2000-09-10 12:02:28 +0000 | [diff] [blame^] | 24 | This installer installs MacPython for PowerPC only, if you really want |
| 25 | 68k support you will have to stay with 1.5.2. Or, if you are willing to |
| 26 | invest the time and have access to CodeWarrior you are welcome to try |
| 27 | and build a 68k distribution, most of the projects and sources are |
| 28 | reasonably up to date (May 2000). Contact me for details. |
Jack Jansen | ecbc1cc | 1998-01-06 12:13:16 +0000 | [diff] [blame] | 29 | |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 30 | What to install |
| 31 | --------------- |
| 32 | |
Jack Jansen | 8a6cdcc | 2000-09-10 12:02:28 +0000 | [diff] [blame^] | 33 | This installer is PPC only: too many new MacOS features are not |
| 34 | available on 68K, and doing workarounds, even just #ifdeffing in the |
| 35 | code, is too much work for me right now. If someone wants to revive |
| 36 | 68K-MacPython: please do so. The project files still contain the 68K |
| 37 | targets (they're simply skipped by the build process) so all that is |
| 38 | needed is CodeWarrior, a source distribution and commitment. |
Jack Jansen | 12a37b7 | 2000-05-06 23:01:07 +0000 | [diff] [blame] | 39 | |
| 40 | The optional parts in this distribution are |
| 41 | - TK+PIL: Tkinter and support modules, plus Imaging, the Python image manipulation |
| 42 | package (allows you to read, write and display images and do lots of operations on them). |
| 43 | - img: another imaging package. Has more file format support and is faster |
| 44 | than imaging, but has only limited operations on images. There is a bridge |
| 45 | between the packages. |
| 46 | - Numeric: the LLNL Numeric Python extension. All sorts of nifty operations |
Jack Jansen | 8a6cdcc | 2000-09-10 12:02:28 +0000 | [diff] [blame^] | 47 | on matrices and such. This is the most recent version from the sourceforge archive. |
Jack Jansen | 12a37b7 | 2000-05-06 23:01:07 +0000 | [diff] [blame] | 48 | - Developers kit: all header files and some tools and sample projects to get you started on |
| 49 | writing Python extensions if you have CodeWarrior. |
| 50 | All these except the DevKit are installed with Easy Install. |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 51 | |
Jack Jansen | 0b72695 | 1997-10-08 15:34:42 +0000 | [diff] [blame] | 52 | After the installer finishes it automatically launches the |
Jack Jansen | 12a37b7 | 2000-05-06 23:01:07 +0000 | [diff] [blame] | 53 | ConfigurePython applet, to finish configuration of your Python. |
Jack Jansen | 8a6cdcc | 2000-09-10 12:02:28 +0000 | [diff] [blame^] | 54 | If you have previously installed another copy of 2.0b1 you should manually |
| 55 | remove your preference file first (but no such action is needed for installing |
| 56 | beside older MacPythons, and they will live together happily). |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 57 | |
| 58 | If you don't have enough memory: the sizes choosen are somewhat |
| 59 | arbitrary. Try lowering the application sizes in the finder "get info" |
| 60 | window, and seeing whether the resulting python is still usable. Some |
| 61 | modules (Tkinter comes to mind) need a lot of memory, so it may also be |
| 62 | necessary to increase the application size. |
| 63 | |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 64 | After installing |
| 65 | ---------------- |
| 66 | |
Jack Jansen | 8a6cdcc | 2000-09-10 12:02:28 +0000 | [diff] [blame^] | 67 | It is probably a good idea to run the automatic tests. Start |
| 68 | Python and "import test.autotest". This should print only 2 or 3 errors, about some |
| 69 | AM/PM format not supported in strftime, about a MemoryError in test_longexp and |
| 70 | about a memory error in test_zlib. |
Jack Jansen | 12a37b7 | 2000-05-06 23:01:07 +0000 | [diff] [blame] | 71 | It will, however, print some messages about optional features |
Jack Jansen | d0ddb66 | 1998-04-27 15:14:36 +0000 | [diff] [blame] | 72 | not supported. Also, if you didn't run compileall before autotesting |
| 73 | you may run out of memory the first time you run the |
| 74 | tests. test_socket may also fail if you have no internet |
| 75 | connection. Please also read the Relnotes file for other minor |
| 76 | problems with this distribution. |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 77 | |
Jack Jansen | 12a37b7 | 2000-05-06 23:01:07 +0000 | [diff] [blame] | 78 | Using Python is most easily done from the IDE, which has a builtin editor, |
| 79 | debugger and other goodies. The alternative is to use PythonInterpreter, |
| 80 | which is the lowlevel interpreter with a console-window only (similar to Unix |
| 81 | Python). |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 82 | |
Jack Jansen | 8a6cdcc | 2000-09-10 12:02:28 +0000 | [diff] [blame^] | 83 | If your program uses Tkinter you MUST run it under PythonInterpreter, Tkinter |
| 84 | and IDE are incompatible and your program will fail in strange ways. |
| 85 | |
Jack Jansen | 0b72695 | 1997-10-08 15:34:42 +0000 | [diff] [blame] | 86 | Uninstalling |
| 87 | ------------ |
| 88 | |
| 89 | Two items are installed in the system folder: the interpreter shared |
Jack Jansen | 8a6cdcc | 2000-09-10 12:02:28 +0000 | [diff] [blame^] | 90 | library "PythonCore 2.0b1" lives in the Extensions folder and the |
| 91 | "Python 2.0b1 Preferences" file in the Python subfolder in the |
| 92 | Preferences folder. All the rest of Python lives in the folder you |
| 93 | installed in. |
Jack Jansen | 0b72695 | 1997-10-08 15:34:42 +0000 | [diff] [blame] | 94 | |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 95 | Things to see |
| 96 | ------------- |
| 97 | |
Jack Jansen | 12a37b7 | 2000-05-06 23:01:07 +0000 | [diff] [blame] | 98 | Start off at Mac:Demo:index.html. Read at least the first few sections. |
| 99 | |
Jack Jansen | 8a6cdcc | 2000-09-10 12:02:28 +0000 | [diff] [blame^] | 100 | There are also some interesting files in the "Relnotes" folder that may |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 101 | contain useful information. There is also a first stab at documentation |
| 102 | (plus examples) in the Mac:Demo folder. The toplevel Demo folder has |
Jack Jansen | 12a37b7 | 2000-05-06 23:01:07 +0000 | [diff] [blame] | 103 | machine-independent demos. |
| 104 | The Mac:Lib:test folder also has some programs that show simple |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 105 | capabilities of various modules. |
| 106 | |
Jack Jansen | 8a6cdcc | 2000-09-10 12:02:28 +0000 | [diff] [blame^] | 107 | The ":Mac:scripts" folder has some sample scripts. Some are useful, some are |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 108 | just interesting to look at to see how various things work. The MkDistr, |
| 109 | mkapplet and fullbuild scripts (plus the ones mentioned above) may help |
| 110 | you to understand how to use AppleEvents and various other toolboxes |
| 111 | from python. |
| 112 | |
Jack Jansen | 8a6cdcc | 2000-09-10 12:02:28 +0000 | [diff] [blame^] | 113 | Other mac-specific goodies can be found in :Mac:Tools, of which the IDE sources |
| 114 | and a CGI framework deserve special mention. |
| 115 | |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 116 | The 'img' group of modules, which handles I/O of many different image |
Jack Jansen | d0ddb66 | 1998-04-27 15:14:36 +0000 | [diff] [blame] | 117 | formats is included, but without documentation. You can find docs at |
| 118 | ftp://ftp.cwi.nl/pub/jack/python/img (or somewhere around there). |
| 119 | |
| 120 | Finally there is a Mac:Contrib folder which contains some contributed |
Jack Jansen | 12a37b7 | 2000-05-06 23:01:07 +0000 | [diff] [blame] | 121 | software. |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 122 | |
| 123 | Upgrading from older Python releases |
| 124 | ------------------------------------ |
| 125 | |
| 126 | Since release 1.4 Python releases are independent of each other, with |
| 127 | separate Preferences files, shared library names, etc. The good news is |
| 128 | that this means you can keep your older version around if you are unsure |
| 129 | whether to upgrade. The bad news is that your old preference settings |
| 130 | are lost and you have to set them again. |
| 131 | |
Jack Jansen | 8a6cdcc | 2000-09-10 12:02:28 +0000 | [diff] [blame^] | 132 | After you are satisfied that 2.0b1 works as expected you can trash |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 133 | anything in the system folder that has "python" in the name and not |
Jack Jansen | 12a37b7 | 2000-05-06 23:01:07 +0000 | [diff] [blame] | 134 | "1.6a2". |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 135 | |
| 136 | The installer |
| 137 | ------------- |
| 138 | |
Jack Jansen | 12a37b7 | 2000-05-06 23:01:07 +0000 | [diff] [blame] | 139 | The installer for this product was created using Installer VISE |
| 140 | from MindVision Software. For more information on Installer VISE, |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 141 | contact: |
| 142 | MindVision Software |
| 143 | 7201 North 7th Street |
| 144 | Lincoln, NE 68521-8913 |
| 145 | Voice: 402-477-3269 |
| 146 | Fax: 402-477-1395 |
| 147 | Internet: mindvision@mindvision.com |
| 148 | http://www.mindvision.com |
| 149 | |
Jack Jansen | 12a37b7 | 2000-05-06 23:01:07 +0000 | [diff] [blame] | 150 | Just van Rossum <just@letterror.nl> created the initial version of the |
| 151 | installer (with Installer Vise Lite), and Jack worked from there. |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 152 | |
Jack Jansen | 01ae9eb | 2000-04-22 22:57:25 +0000 | [diff] [blame] | 153 | Thanks! |
| 154 | ------- |
| 155 | |
| 156 | Thanks go to the whole Python community with Guido in the lead, of course. |
| 157 | Mac-specific thanks go to the pythonmac-sig, Just van Rossum, Corran Webster, |
Jack Jansen | 8a6cdcc | 2000-09-10 12:02:28 +0000 | [diff] [blame^] | 158 | Erik van Blokland, Bill Bedford, Chris Stern, Gordon Worley, Oliver Steele, M. Papillon, |
| 159 | Steven Majewski and all the other people who provided feedback, code or both! |
Jack Jansen | 01ae9eb | 2000-04-22 22:57:25 +0000 | [diff] [blame] | 160 | |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 161 | Feedback |
| 162 | -------- |
| 163 | |
| 164 | Send bug reports, suggestions, contributions and fanmail to |
Jack Jansen | ecbc1cc | 1998-01-06 12:13:16 +0000 | [diff] [blame] | 165 | <jack@cwi.nl>. However, a better way to discuss MacPython is to join the |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 166 | <pythonmac-sig@python.org> mailing list, which is explicitly meant for |
| 167 | this purpose. |
| 168 | |
| 169 | Alternatively, you can try sending to comp.lang.python or |
| 170 | python-list@cwi.nl, but since I read the newsgroup, not the mailinglist, |
| 171 | I may miss it there (but other people may know quite a bit more than me |
| 172 | anyway:-). |
| 173 | |
| 174 | Jack Jansen |
Jack Jansen | 12a37b7 | 2000-05-06 23:01:07 +0000 | [diff] [blame] | 175 | Oratrix Development BV |
| 176 | Valeriusplein 30 |
| 177 | Amsterdam |
Jack Jansen | 83cab72 | 1997-08-26 13:25:06 +0000 | [diff] [blame] | 178 | the Netherlands |
| 179 | |
| 180 | <jack@cwi.nl>, http://www.cwi.nl/~jack |