Fred Drake | 56221a7 | 2000-08-15 18:52:33 +0000 | [diff] [blame] | 1 | Python for BeOS R5 |
Guido van Rossum | d8eb211 | 1998-08-04 17:57:28 +0000 | [diff] [blame] | 2 | |
| 3 | This directory contains several useful things to help you build your own |
| 4 | version of Python for BeOS. |
| 5 | |
Guido van Rossum | d8eb211 | 1998-08-04 17:57:28 +0000 | [diff] [blame] | 6 | What's Here? |
| 7 | |
Fred Drake | 60ad79f | 2000-10-06 16:17:21 +0000 | [diff] [blame] | 8 | ar-fake - A shell script that copies around .o files, for the as much |
| 9 | of the general effect of ar as we need but more fool-proof. |
| 10 | It also has an "so" command to build the shared library |
| 11 | that we actually install and use. |
Guido van Rossum | d8eb211 | 1998-08-04 17:57:28 +0000 | [diff] [blame] | 12 | |
| 13 | linkmodule - A shell script used by the build process to build the |
| 14 | shared library versions of the standard modules; you'll |
| 15 | probably need this if you want to build dynamically loaded |
| 16 | modules from the Python archives. |
| 17 | |
Guido van Rossum | d8eb211 | 1998-08-04 17:57:28 +0000 | [diff] [blame] | 18 | README - This file (obviously!). |
| 19 | |
| 20 | README.readline-2.2 - Instructions for compiling/installing GNU readline 2.2. |
Fred Drake | 60ad79f | 2000-10-06 16:17:21 +0000 | [diff] [blame] | 21 | You'll have to grab the GNU readline source code from |
Guido van Rossum | d8eb211 | 1998-08-04 17:57:28 +0000 | [diff] [blame] | 22 | prep.ai.mit.edu:/pub/GNU or any other GNU mirror. |
| 23 | |
| 24 | The Python interpreter is much nicer to work with |
| 25 | interactively if you've got readline installed. Highly |
| 26 | recommended. |
| 27 | |
Fred Drake | 60ad79f | 2000-10-06 16:17:21 +0000 | [diff] [blame] | 28 | To build, |
Guido van Rossum | d8eb211 | 1998-08-04 17:57:28 +0000 | [diff] [blame] | 29 | |
Fred Drake | 60ad79f | 2000-10-06 16:17:21 +0000 | [diff] [blame] | 30 | 1) ./configure --prefix=/boot/home/config |
Guido van Rossum | d8eb211 | 1998-08-04 17:57:28 +0000 | [diff] [blame] | 31 | |
Fred Drake | cf3bc8c | 2000-10-26 17:07:40 +0000 | [diff] [blame] | 32 | 2) edit Modules/Setup |
Fred Drake | 60ad79f | 2000-10-06 16:17:21 +0000 | [diff] [blame] | 33 | comment out grp and mmap, and pwd on 4.5 or earlier |
| 34 | uncomment any modules you want to include in python |
| 35 | (you can also add them later as shared libraries.) |
| 36 | 3) make |
Guido van Rossum | d8eb211 | 1998-08-04 17:57:28 +0000 | [diff] [blame] | 37 | |
Fred Drake | 60ad79f | 2000-10-06 16:17:21 +0000 | [diff] [blame] | 38 | Test: |
Guido van Rossum | fc4966b | 1998-12-17 18:00:33 +0000 | [diff] [blame] | 39 | |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 40 | make test |
Guido van Rossum | d8eb211 | 1998-08-04 17:57:28 +0000 | [diff] [blame] | 41 | |
Fred Drake | 60ad79f | 2000-10-06 16:17:21 +0000 | [diff] [blame] | 42 | [Chris Herborth writes:] |
Fred Drake | 56221a7 | 2000-08-15 18:52:33 +0000 | [diff] [blame] | 43 | test_popen2 will probably hang; it's deadlocked on a semaphore. I should |
| 44 | probably disable popen2 support... it uses fork(), and fork() doesn't mix |
| 45 | with threads on BeOS. In *THEORY* you could use it in a single-threaded |
| 46 | program, but I haven't tried. |
Fred Drake | 60ad79f | 2000-10-06 16:17:21 +0000 | [diff] [blame] | 47 | |
Fred Drake | 56221a7 | 2000-08-15 18:52:33 +0000 | [diff] [blame] | 48 | If test_popen2 does hang, you can find the semaphore it's hung on via the |
| 49 | "ps" command. Look for python and you'll find something like this: |
Fred Drake | 60ad79f | 2000-10-06 16:17:21 +0000 | [diff] [blame] | 50 | |
Fred Drake | 56221a7 | 2000-08-15 18:52:33 +0000 | [diff] [blame] | 51 | ./python -tt ../src/Lib/test/regrtest.py (team 26922) (uid 0) (gid 0) |
| 52 | 39472 python sem 10 3785 1500 piperd(360526) |
| 53 | ./python -tt ../src/Lib/test/regrtest.py (team 26923) (uid 0) (gid 0) |
| 54 | 39477 python sem 10 25 4 python lock (1)(360022) |
| 55 | ^^^^^^ |
| 56 | That last number is the semaphore the fork()'d python is stuck on |
| 57 | (see how it's helpfully called "python lock (1)"? :-). You can unblock |
| 58 | that semaphore to let the tests continue using the "release" command |
| 59 | with that semaphore number. Be _very_ careful with "release" though, |
| 60 | releasing the wrong semaphore can be hazardous. |
| 61 | |
Guido van Rossum | d8eb211 | 1998-08-04 17:57:28 +0000 | [diff] [blame] | 62 | Expect the following errors: |
| 63 | |
Fred Drake | 56221a7 | 2000-08-15 18:52:33 +0000 | [diff] [blame] | 64 | test * skipped -- an optional feature could not be imported (you'll see |
| 65 | quite a few of these, based on what optional modules |
| 66 | you've included) |
| 67 | |
| 68 | test test_fork1 skipped -- can't mix os.fork with threads on BeOS |
| 69 | |
Fred Drake | 60ad79f | 2000-10-06 16:17:21 +0000 | [diff] [blame] | 70 | test test_select crashed -- select.error : (-2147459072, 'Bad file |
Fred Drake | 56221a7 | 2000-08-15 18:52:33 +0000 | [diff] [blame] | 71 | descriptor') |
| 72 | |
| 73 | test test_socket crashed -- exceptions.AttributeError : SOCK_RAW |
Guido van Rossum | d8eb211 | 1998-08-04 17:57:28 +0000 | [diff] [blame] | 74 | |
| 75 | These are all due to either partial support for certain things (like |
Guido van Rossum | fc4966b | 1998-12-17 18:00:33 +0000 | [diff] [blame] | 76 | sockets), or valid differences between systems. |
Guido van Rossum | d8eb211 | 1998-08-04 17:57:28 +0000 | [diff] [blame] | 77 | |
Fred Drake | 60ad79f | 2000-10-06 16:17:21 +0000 | [diff] [blame] | 78 | test test_pickle crashed. This is apparently a serious problem, |
| 79 | "complex" number objects reconstructed from a |
| 80 | pickle don't compare equal to their ancestors. |
| 81 | But it happens on BeOS PPC only, not Intel. |
Guido van Rossum | d8eb211 | 1998-08-04 17:57:28 +0000 | [diff] [blame] | 82 | |
Fred Drake | 60ad79f | 2000-10-06 16:17:21 +0000 | [diff] [blame] | 83 | Install: |
Guido van Rossum | d8eb211 | 1998-08-04 17:57:28 +0000 | [diff] [blame] | 84 | |
Guido van Rossum | 7a5f420 | 1999-01-12 20:30:23 +0000 | [diff] [blame] | 85 | make install |
Guido van Rossum | d8eb211 | 1998-08-04 17:57:28 +0000 | [diff] [blame] | 86 | |
Fred Drake | 60ad79f | 2000-10-06 16:17:21 +0000 | [diff] [blame] | 87 | Enjoy! |
Guido van Rossum | eb45232 | 1998-12-18 22:00:58 +0000 | [diff] [blame] | 88 | |
Fred Drake | 56221a7 | 2000-08-15 18:52:33 +0000 | [diff] [blame] | 89 | - Chris Herborth (chrish@pobox.com) |
| 90 | July 21, 2000 |
Fred Drake | 60ad79f | 2000-10-06 16:17:21 +0000 | [diff] [blame] | 91 | |
| 92 | - Donn Cave (donn@oz.net) |
| 93 | October 4, 2000 |