| 1 | This is Python version 2.5
|
|---|
| 2 | ==========================
|
|---|
| 3 |
|
|---|
| 4 | Copyright (c) 2001, 2002, 2003, 2004, 2005, 2006 Python Software Foundation.
|
|---|
| 5 | All rights reserved.
|
|---|
| 6 |
|
|---|
| 7 | Copyright (c) 2000 BeOpen.com.
|
|---|
| 8 | All rights reserved.
|
|---|
| 9 |
|
|---|
| 10 | Copyright (c) 1995-2001 Corporation for National Research Initiatives.
|
|---|
| 11 | All rights reserved.
|
|---|
| 12 |
|
|---|
| 13 | Copyright (c) 1991-1995 Stichting Mathematisch Centrum.
|
|---|
| 14 | All rights reserved.
|
|---|
| 15 |
|
|---|
| 16 |
|
|---|
| 17 | License information
|
|---|
| 18 | -------------------
|
|---|
| 19 |
|
|---|
| 20 | See the file "LICENSE" for information on the history of this
|
|---|
| 21 | software, terms & conditions for usage, and a DISCLAIMER OF ALL
|
|---|
| 22 | WARRANTIES.
|
|---|
| 23 |
|
|---|
| 24 | This Python distribution contains no GNU General Public Licensed
|
|---|
| 25 | (GPLed) code so it may be used in proprietary projects just like prior
|
|---|
| 26 | Python distributions. There are interfaces to some GNU code but these
|
|---|
| 27 | are entirely optional.
|
|---|
| 28 |
|
|---|
| 29 | All trademarks referenced herein are property of their respective
|
|---|
| 30 | holders.
|
|---|
| 31 |
|
|---|
| 32 |
|
|---|
| 33 | What's new in this release?
|
|---|
| 34 | ---------------------------
|
|---|
| 35 |
|
|---|
| 36 | See the file "Misc/NEWS".
|
|---|
| 37 |
|
|---|
| 38 |
|
|---|
| 39 | If you don't read instructions
|
|---|
| 40 | ------------------------------
|
|---|
| 41 |
|
|---|
| 42 | Congratulations on getting this far. :-)
|
|---|
| 43 |
|
|---|
| 44 | To start building right away (on UNIX): type "./configure" in the
|
|---|
| 45 | current directory and when it finishes, type "make". This creates an
|
|---|
| 46 | executable "./python"; to install in /usr/local, first do "su root"
|
|---|
| 47 | and then "make install".
|
|---|
| 48 |
|
|---|
| 49 | The section `Build instructions' below is still recommended reading.
|
|---|
| 50 |
|
|---|
| 51 |
|
|---|
| 52 | What is Python anyway?
|
|---|
| 53 | ----------------------
|
|---|
| 54 |
|
|---|
| 55 | Python is an interpreted, interactive object-oriented programming
|
|---|
| 56 | language suitable (amongst other uses) for distributed application
|
|---|
| 57 | development, scripting, numeric computing and system testing. Python
|
|---|
| 58 | is often compared to Tcl, Perl, Java, JavaScript, Visual Basic or
|
|---|
| 59 | Scheme. To find out more about what Python can do for you, point your
|
|---|
| 60 | browser to http://www.python.org/.
|
|---|
| 61 |
|
|---|
| 62 |
|
|---|
| 63 | How do I learn Python?
|
|---|
| 64 | ----------------------
|
|---|
| 65 |
|
|---|
| 66 | The official tutorial is still a good place to start; see
|
|---|
| 67 | http://docs.python.org/ for online and downloadable versions, as well
|
|---|
| 68 | as a list of other introductions, and reference documentation.
|
|---|
| 69 |
|
|---|
| 70 | There's a quickly growing set of books on Python. See
|
|---|
| 71 | http://wiki.python.org/moin/PythonBooks for a list.
|
|---|
| 72 |
|
|---|
| 73 |
|
|---|
| 74 | Documentation
|
|---|
| 75 | -------------
|
|---|
| 76 |
|
|---|
| 77 | All documentation is provided online in a variety of formats. In
|
|---|
| 78 | order of importance for new users: Tutorial, Library Reference,
|
|---|
| 79 | Language Reference, Extending & Embedding, and the Python/C API. The
|
|---|
| 80 | Library Reference is especially of immense value since much of
|
|---|
| 81 | Python's power is described there, including the built-in data types
|
|---|
| 82 | and functions!
|
|---|
| 83 |
|
|---|
| 84 | All documentation is also available online at the Python web site
|
|---|
| 85 | (http://docs.python.org/, see below). It is available online for
|
|---|
| 86 | occasional reference, or can be downloaded in many formats for faster
|
|---|
| 87 | access. The documentation is available in HTML, PostScript, PDF, and
|
|---|
| 88 | LaTeX formats; the LaTeX version is primarily for documentation
|
|---|
| 89 | authors, translators, and people with special formatting requirements.
|
|---|
| 90 |
|
|---|
| 91 | Unfortunately, new-style classes (new in Python 2.2) have not yet been
|
|---|
| 92 | integrated into Python's standard documentation. A collection of
|
|---|
| 93 | pointers to what has been written is at:
|
|---|
| 94 |
|
|---|
| 95 | http://www.python.org/doc/newstyle.html
|
|---|
| 96 |
|
|---|
| 97 |
|
|---|
| 98 | Web sites
|
|---|
| 99 | ---------
|
|---|
| 100 |
|
|---|
| 101 | New Python releases and related technologies are published at
|
|---|
| 102 | http://www.python.org/. Come visit us!
|
|---|
| 103 |
|
|---|
| 104 | There's also a Python community web site at
|
|---|
| 105 | http://starship.python.net/.
|
|---|
| 106 |
|
|---|
| 107 |
|
|---|
| 108 | Newsgroups and Mailing Lists
|
|---|
| 109 | ----------------------------
|
|---|
| 110 |
|
|---|
| 111 | Read comp.lang.python, a high-volume discussion newsgroup about
|
|---|
| 112 | Python, or comp.lang.python.announce, a low-volume moderated newsgroup
|
|---|
| 113 | for Python-related announcements. These are also accessible as
|
|---|
| 114 | mailing lists: see http://www.python.org/community/lists.html for an
|
|---|
| 115 | overview of these and many other Python-related mailing lists.
|
|---|
| 116 |
|
|---|
| 117 | Archives are accessible via the Google Groups Usenet archive; see
|
|---|
| 118 | http://groups.google.com/. The mailing lists are also archived, see
|
|---|
| 119 | http://www.python.org/community/lists.html for details.
|
|---|
| 120 |
|
|---|
| 121 |
|
|---|
| 122 | Bug reports
|
|---|
| 123 | -----------
|
|---|
| 124 |
|
|---|
| 125 | To report or search for bugs, please use the Python Bug
|
|---|
| 126 | Tracker at http://sourceforge.net/bugs/?group_id=5470.
|
|---|
| 127 |
|
|---|
| 128 |
|
|---|
| 129 | Patches and contributions
|
|---|
| 130 | -------------------------
|
|---|
| 131 |
|
|---|
| 132 | To submit a patch or other contribution, please use the Python Patch
|
|---|
| 133 | Manager at http://sourceforge.net/patch/?group_id=5470. Guidelines
|
|---|
| 134 | for patch submission may be found at http://www.python.org/patches/.
|
|---|
| 135 |
|
|---|
| 136 | If you have a proposal to change Python, it's best to submit a Python
|
|---|
| 137 | Enhancement Proposal (PEP) first. All current PEPs, as well as
|
|---|
| 138 | guidelines for submitting a new PEP, are listed at
|
|---|
| 139 | http://www.python.org/peps/.
|
|---|
| 140 |
|
|---|
| 141 |
|
|---|
| 142 | Questions
|
|---|
| 143 | ---------
|
|---|
| 144 |
|
|---|
| 145 | For help, if you can't find it in the manuals or on the web site, it's
|
|---|
| 146 | best to post to the comp.lang.python or the Python mailing list (see
|
|---|
| 147 | above). If you specifically don't want to involve the newsgroup or
|
|---|
| 148 | mailing list, send questions to [email protected] (a group of volunteers
|
|---|
| 149 | who answer questions as they can). The newsgroup is the most
|
|---|
| 150 | efficient way to ask public questions.
|
|---|
| 151 |
|
|---|
| 152 |
|
|---|
| 153 | Build instructions
|
|---|
| 154 | ==================
|
|---|
| 155 |
|
|---|
| 156 | Before you can build Python, you must first configure it.
|
|---|
| 157 | Fortunately, the configuration and build process has been automated
|
|---|
| 158 | for Unix and Linux installations, so all you usually have to do is
|
|---|
| 159 | type a few commands and sit back. There are some platforms where
|
|---|
| 160 | things are not quite as smooth; see the platform specific notes below.
|
|---|
| 161 | If you want to build for multiple platforms sharing the same source
|
|---|
| 162 | tree, see the section on VPATH below.
|
|---|
| 163 |
|
|---|
| 164 | Start by running the script "./configure", which determines your
|
|---|
| 165 | system configuration and creates the Makefile. (It takes a minute or
|
|---|
| 166 | two -- please be patient!) You may want to pass options to the
|
|---|
| 167 | configure script -- see the section below on configuration options and
|
|---|
| 168 | variables. When it's done, you are ready to run make.
|
|---|
| 169 |
|
|---|
| 170 | To build Python, you normally type "make" in the toplevel directory.
|
|---|
| 171 | If you have changed the configuration, the Makefile may have to be
|
|---|
| 172 | rebuilt. In this case you may have to run make again to correctly
|
|---|
| 173 | build your desired target. The interpreter executable is built in the
|
|---|
| 174 | top level directory.
|
|---|
| 175 |
|
|---|
| 176 | Once you have built a Python interpreter, see the subsections below on
|
|---|
| 177 | testing and installation. If you run into trouble, see the next
|
|---|
| 178 | section.
|
|---|
| 179 |
|
|---|
| 180 | Previous versions of Python used a manual configuration process that
|
|---|
| 181 | involved editing the file Modules/Setup. While this file still exists
|
|---|
| 182 | and manual configuration is still supported, it is rarely needed any
|
|---|
| 183 | more: almost all modules are automatically built as appropriate under
|
|---|
| 184 | guidance of the setup.py script, which is run by Make after the
|
|---|
| 185 | interpreter has been built.
|
|---|
| 186 |
|
|---|
| 187 |
|
|---|
| 188 | Troubleshooting
|
|---|
| 189 | ---------------
|
|---|
| 190 |
|
|---|
| 191 | See also the platform specific notes in the next section.
|
|---|
| 192 |
|
|---|
| 193 | If you run into other trouble, see the FAQ
|
|---|
| 194 | (http://www.python.org/doc/faq) for hints on what can go wrong, and
|
|---|
| 195 | how to fix it.
|
|---|
| 196 |
|
|---|
| 197 | If you rerun the configure script with different options, remove all
|
|---|
| 198 | object files by running "make clean" before rebuilding. Believe it or
|
|---|
| 199 | not, "make clean" sometimes helps to clean up other inexplicable
|
|---|
| 200 | problems as well. Try it before sending in a bug report!
|
|---|
| 201 |
|
|---|
| 202 | If the configure script fails or doesn't seem to find things that
|
|---|
| 203 | should be there, inspect the config.log file.
|
|---|
| 204 |
|
|---|
| 205 | If you get a warning for every file about the -Olimit option being no
|
|---|
| 206 | longer supported, you can ignore it. There's no foolproof way to know
|
|---|
| 207 | whether this option is needed; all we can do is test whether it is
|
|---|
| 208 | accepted without error. On some systems, e.g. older SGI compilers, it
|
|---|
| 209 | is essential for performance (specifically when compiling ceval.c,
|
|---|
| 210 | which has more basic blocks than the default limit of 1000). If the
|
|---|
| 211 | warning bothers you, edit the Makefile to remove "-Olimit 1500" from
|
|---|
| 212 | the OPT variable.
|
|---|
| 213 |
|
|---|
| 214 | If you get failures in test_long, or sys.maxint gets set to -1, you
|
|---|
| 215 | are probably experiencing compiler bugs, usually related to
|
|---|
| 216 | optimization. This is a common problem with some versions of gcc, and
|
|---|
| 217 | some vendor-supplied compilers, which can sometimes be worked around
|
|---|
| 218 | by turning off optimization. Consider switching to stable versions
|
|---|
| 219 | (gcc 2.95.2, gcc 3.x, or contact your vendor.)
|
|---|
| 220 |
|
|---|
| 221 | From Python 2.0 onward, all Python C code is ANSI C. Compiling using
|
|---|
| 222 | old K&R-C-only compilers is no longer possible. ANSI C compilers are
|
|---|
| 223 | available for all modern systems, either in the form of updated
|
|---|
| 224 | compilers from the vendor, or one of the free compilers (gcc).
|
|---|
| 225 |
|
|---|
| 226 | Unsupported systems
|
|---|
| 227 | -------------------
|
|---|
| 228 |
|
|---|
| 229 | A number of features are not supported in Python 2.5 anymore. Some
|
|---|
| 230 | support code is still present, but will be removed in Python 2.6.
|
|---|
| 231 | If you still need to use current Python versions on these systems,
|
|---|
| 232 | please send a message to [email protected] indicating that you
|
|---|
| 233 | volunteer to support this system. For a more detailed discussion
|
|---|
| 234 | regarding no-longer-supported and resupporting platforms, as well
|
|---|
| 235 | as a list of platforms that became or will be unsupported, see PEP 11.
|
|---|
| 236 |
|
|---|
| 237 | More specifically, the following systems are not supported any
|
|---|
| 238 | longer:
|
|---|
| 239 | - SunOS 4
|
|---|
| 240 | - DYNIX
|
|---|
| 241 | - dgux
|
|---|
| 242 | - Minix
|
|---|
| 243 | - NeXT
|
|---|
| 244 | - Irix 4 and --with-sgi-dl
|
|---|
| 245 | - Linux 1
|
|---|
| 246 | - Systems defining __d6_pthread_create (configure.in)
|
|---|
| 247 | - Systems defining PY_PTHREAD_D4, PY_PTHREAD_D6,
|
|---|
| 248 | or PY_PTHREAD_D7 in thread_pthread.h
|
|---|
| 249 | - Systems using --with-dl-dld
|
|---|
| 250 | - Systems using --without-universal-newlines
|
|---|
| 251 | - MacOS 9
|
|---|
| 252 |
|
|---|
| 253 | The following systems are still supported in Python 2.5, but
|
|---|
| 254 | support will be dropped in 2.6:
|
|---|
| 255 | - Systems using --with-wctype-functions
|
|---|
| 256 | - Win9x, WinME
|
|---|
| 257 |
|
|---|
| 258 | Warning on install in Windows 98 and Windows Me
|
|---|
| 259 | -----------------------------------------------
|
|---|
| 260 |
|
|---|
| 261 | Following Microsoft's closing of Extended Support for
|
|---|
| 262 | Windows 98/ME (July 11, 2006), Python 2.6 will stop
|
|---|
| 263 | supporting these platforms. Python development and
|
|---|
| 264 | maintainability becomes easier (and more reliable) when
|
|---|
| 265 | platform specific code targeting OSes with few users
|
|---|
| 266 | and no dedicated expert developers is taken out. The
|
|---|
| 267 | vendor also warns that the OS versions listed above
|
|---|
| 268 | "can expose customers to security risks" and recommends
|
|---|
| 269 | upgrade.
|
|---|
| 270 |
|
|---|
| 271 | Platform specific notes
|
|---|
| 272 | -----------------------
|
|---|
| 273 |
|
|---|
| 274 | (Some of these may no longer apply. If you find you can build Python
|
|---|
| 275 | on these platforms without the special directions mentioned here,
|
|---|
| 276 | submit a documentation bug report to SourceForge (see Bug Reports
|
|---|
| 277 | above) so we can remove them!)
|
|---|
| 278 |
|
|---|
| 279 | GCC 4.1,
|
|---|
| 280 | GCC 4.2: There is a known incompatibility between Python and GCC,
|
|---|
| 281 | where GCC 4.1 and later uses an interpretation of C
|
|---|
| 282 | different to earlier GCC releases in an area where the C
|
|---|
| 283 | specification has undefined behaviour (namely, integer arithmetic
|
|---|
| 284 | involving -sys.maxint-1).
|
|---|
| 285 |
|
|---|
| 286 | As a consequence, compiling Python with GCC 4.1/4.2 is not
|
|---|
| 287 | recommended. It is likely that this problem will be resolved
|
|---|
| 288 | in future Python releases. As a work-around, it seems that
|
|---|
| 289 | adding -fwrapv to the compiler options restores the earlier
|
|---|
| 290 | GCC behaviour.
|
|---|
| 291 |
|
|---|
| 292 | Unix platforms: If your vendor still ships (and you still use) Berkeley DB
|
|---|
| 293 | 1.85 you will need to edit Modules/Setup to build the bsddb185
|
|---|
| 294 | module and add a line to sitecustomize.py which makes it the
|
|---|
| 295 | default. In Modules/Setup a line like
|
|---|
| 296 |
|
|---|
| 297 | bsddb185 bsddbmodule.c
|
|---|
| 298 |
|
|---|
| 299 | should work. (You may need to add -I, -L or -l flags to direct the
|
|---|
| 300 | compiler and linker to your include files and libraries.)
|
|---|
| 301 |
|
|---|
| 302 | XXX I think this next bit is out of date:
|
|---|
| 303 |
|
|---|
| 304 | 64-bit platforms: The modules audioop, imageop and rgbimg don't work.
|
|---|
| 305 | The setup.py script disables them on 64-bit installations.
|
|---|
| 306 | Don't try to enable them in the Modules/Setup file. They
|
|---|
| 307 | contain code that is quite wordsize sensitive. (If you have a
|
|---|
| 308 | fix, let us know!)
|
|---|
| 309 |
|
|---|
| 310 | Solaris: When using Sun's C compiler with threads, at least on Solaris
|
|---|
| 311 | 2.5.1, you need to add the "-mt" compiler option (the simplest
|
|---|
| 312 | way is probably to specify the compiler with this option as
|
|---|
| 313 | the "CC" environment variable when running the configure
|
|---|
| 314 | script).
|
|---|
| 315 |
|
|---|
| 316 | When using GCC on Solaris, beware of binutils 2.13 or GCC
|
|---|
| 317 | versions built using it. This mistakenly enables the
|
|---|
| 318 | -zcombreloc option which creates broken shared libraries on
|
|---|
| 319 | Solaris. binutils 2.12 works, and the binutils maintainers
|
|---|
| 320 | are aware of the problem. Binutils 2.13.1 only partially
|
|---|
| 321 | fixed things. It appears that 2.13.2 solves the problem
|
|---|
| 322 | completely. This problem is known to occur with Solaris 2.7
|
|---|
| 323 | and 2.8, but may also affect earlier and later versions of the
|
|---|
| 324 | OS.
|
|---|
| 325 |
|
|---|
| 326 | When the dynamic loader complains about errors finding shared
|
|---|
| 327 | libraries, such as
|
|---|
| 328 |
|
|---|
| 329 | ld.so.1: ./python: fatal: libstdc++.so.5: open failed:
|
|---|
| 330 | No such file or directory
|
|---|
| 331 |
|
|---|
| 332 | you need to first make sure that the library is available on
|
|---|
| 333 | your system. Then, you need to instruct the dynamic loader how
|
|---|
| 334 | to find it. You can choose any of the following strategies:
|
|---|
| 335 |
|
|---|
| 336 | 1. When compiling Python, set LD_RUN_PATH to the directories
|
|---|
| 337 | containing missing libraries.
|
|---|
| 338 | 2. When running Python, set LD_LIBRARY_PATH to these directories.
|
|---|
| 339 | 3. Use crle(8) to extend the search path of the loader.
|
|---|
| 340 | 4. Modify the installed GCC specs file, adding -R options into the
|
|---|
| 341 | *link: section.
|
|---|
| 342 |
|
|---|
| 343 | The complex object fails to compile on Solaris 10 with gcc 3.4 (at
|
|---|
| 344 | least up to 3.4.3). To work around it, define Py_HUGE_VAL as
|
|---|
| 345 | HUGE_VAL(), e.g.:
|
|---|
| 346 |
|
|---|
| 347 | make CPPFLAGS='-D"Py_HUGE_VAL=HUGE_VAL()" -I. -I$(srcdir)/Include'
|
|---|
| 348 | ./python setup.py CPPFLAGS='-D"Py_HUGE_VAL=HUGE_VAL()"'
|
|---|
| 349 |
|
|---|
| 350 | Linux: A problem with threads and fork() was tracked down to a bug in
|
|---|
| 351 | the pthreads code in glibc version 2.0.5; glibc version 2.0.7
|
|---|
| 352 | solves the problem. This causes the popen2 test to fail;
|
|---|
| 353 | problem and solution reported by Pablo Bleyer.
|
|---|
| 354 |
|
|---|
| 355 | Red Hat Linux: Red Hat 9 built Python2.2 in UCS-4 mode and hacked
|
|---|
| 356 | Tcl to support it. To compile Python2.3 with Tkinter, you will
|
|---|
| 357 | need to pass --enable-unicode=ucs4 flag to ./configure.
|
|---|
| 358 |
|
|---|
| 359 | There's an executable /usr/bin/python which is Python
|
|---|
| 360 | 1.5.2 on most older Red Hat installations; several key Red Hat tools
|
|---|
| 361 | require this version. Python 2.1.x may be installed as
|
|---|
| 362 | /usr/bin/python2. The Makefile installs Python as
|
|---|
| 363 | /usr/local/bin/python, which may or may not take precedence
|
|---|
| 364 | over /usr/bin/python, depending on how you have set up $PATH.
|
|---|
| 365 |
|
|---|
| 366 | FreeBSD 3.x and probably platforms with NCurses that use libmytinfo or
|
|---|
| 367 | similar: When using cursesmodule, the linking is not done in
|
|---|
| 368 | the correct order with the defaults. Remove "-ltermcap" from
|
|---|
| 369 | the readline entry in Setup, and use as curses entry: "curses
|
|---|
| 370 | cursesmodule.c -lmytinfo -lncurses -ltermcap" - "mytinfo" (so
|
|---|
| 371 | called on FreeBSD) should be the name of the auxiliary library
|
|---|
| 372 | required on your platform. Normally, it would be linked
|
|---|
| 373 | automatically, but not necessarily in the correct order.
|
|---|
| 374 |
|
|---|
| 375 | BSDI: BSDI versions before 4.1 have known problems with threads,
|
|---|
| 376 | which can cause strange errors in a number of modules (for
|
|---|
| 377 | instance, the 'test_signal' test script will hang forever.)
|
|---|
| 378 | Turning off threads (with --with-threads=no) or upgrading to
|
|---|
| 379 | BSDI 4.1 solves this problem.
|
|---|
| 380 |
|
|---|
| 381 | DEC Unix: Run configure with --with-dec-threads, or with
|
|---|
| 382 | --with-threads=no if no threads are desired (threads are on by
|
|---|
| 383 | default). When using GCC, it is possible to get an internal
|
|---|
| 384 | compiler error if optimization is used. This was reported for
|
|---|
| 385 | GCC 2.7.2.3 on selectmodule.c. Manually compile the affected
|
|---|
| 386 | file without optimization to solve the problem.
|
|---|
| 387 |
|
|---|
| 388 | DEC Ultrix: compile with GCC to avoid bugs in the native compiler,
|
|---|
| 389 | and pass SHELL=/bin/sh5 to Make when installing.
|
|---|
| 390 |
|
|---|
| 391 | AIX: A complete overhaul of the shared library support is now in
|
|---|
| 392 | place. See Misc/AIX-NOTES for some notes on how it's done.
|
|---|
| 393 | (The optimizer bug reported at this place in previous releases
|
|---|
| 394 | has been worked around by a minimal code change.) If you get
|
|---|
| 395 | errors about pthread_* functions, during compile or during
|
|---|
| 396 | testing, try setting CC to a thread-safe (reentrant) compiler,
|
|---|
| 397 | like "cc_r". For full C++ module support, set CC="xlC_r" (or
|
|---|
| 398 | CC="xlC" without thread support).
|
|---|
| 399 |
|
|---|
| 400 | AIX 5.3: To build a 64-bit version with IBM's compiler, I used the
|
|---|
| 401 | following:
|
|---|
| 402 |
|
|---|
| 403 | export PATH=/usr/bin:/usr/vacpp/bin
|
|---|
| 404 | ./configure --with-gcc="xlc_r -q64" --with-cxx="xlC_r -q64" \
|
|---|
| 405 | --disable-ipv6 AR="ar -X64"
|
|---|
| 406 | make
|
|---|
| 407 |
|
|---|
| 408 | HP-UX: When using threading, you may have to add -D_REENTRANT to the
|
|---|
| 409 | OPT variable in the top-level Makefile; reported by Pat Knight,
|
|---|
| 410 | this seems to make a difference (at least for HP-UX 10.20)
|
|---|
| 411 | even though pyconfig.h defines it. This seems unnecessary when
|
|---|
| 412 | using HP/UX 11 and later - threading seems to work "out of the
|
|---|
| 413 | box".
|
|---|
| 414 |
|
|---|
| 415 | HP-UX ia64: When building on the ia64 (Itanium) platform using HP's
|
|---|
| 416 | compiler, some experience has shown that the compiler's
|
|---|
| 417 | optimiser produces a completely broken version of python
|
|---|
| 418 | (see http://www.python.org/sf/814976). To work around this,
|
|---|
| 419 | edit the Makefile and remove -O from the OPT line.
|
|---|
| 420 |
|
|---|
| 421 | To build a 64-bit executable on an Itanium 2 system using HP's
|
|---|
| 422 | compiler, use these environment variables:
|
|---|
| 423 |
|
|---|
| 424 | CC=cc
|
|---|
| 425 | CXX=aCC
|
|---|
| 426 | BASECFLAGS="+DD64"
|
|---|
| 427 | LDFLAGS="+DD64 -lxnet"
|
|---|
| 428 |
|
|---|
| 429 | and call configure as:
|
|---|
| 430 |
|
|---|
| 431 | ./configure --without-gcc
|
|---|
| 432 |
|
|---|
| 433 | then *unset* the environment variables again before running
|
|---|
| 434 | make. (At least one of these flags causes the build to fail
|
|---|
| 435 | if it remains set.) You still have to edit the Makefile and
|
|---|
| 436 | remove -O from the OPT line.
|
|---|
| 437 |
|
|---|
| 438 | HP PA-RISC 2.0: A recent bug report (http://www.python.org/sf/546117)
|
|---|
| 439 | suggests that the C compiler in this 64-bit system has bugs
|
|---|
| 440 | in the optimizer that break Python. Compiling without
|
|---|
| 441 | optimization solves the problems.
|
|---|
| 442 |
|
|---|
| 443 | SCO: The following apply to SCO 3 only; Python builds out of the box
|
|---|
| 444 | on SCO 5 (or so we've heard).
|
|---|
| 445 |
|
|---|
| 446 | 1) Everything works much better if you add -U__STDC__ to the
|
|---|
| 447 | defs. This is because all the SCO header files are broken.
|
|---|
| 448 | Anything that isn't mentioned in the C standard is
|
|---|
| 449 | conditionally excluded when __STDC__ is defined.
|
|---|
| 450 |
|
|---|
| 451 | 2) Due to the U.S. export restrictions, SCO broke the crypt
|
|---|
| 452 | stuff out into a separate library, libcrypt_i.a so the LIBS
|
|---|
| 453 | needed be set to:
|
|---|
| 454 |
|
|---|
| 455 | LIBS=' -lsocket -lcrypt_i'
|
|---|
| 456 |
|
|---|
| 457 | UnixWare: There are known bugs in the math library of the system, as well as
|
|---|
| 458 | problems in the handling of threads (calling fork in one
|
|---|
| 459 | thread may interrupt system calls in others). Therefore, test_math and
|
|---|
| 460 | tests involving threads will fail until those problems are fixed.
|
|---|
| 461 |
|
|---|
| 462 | QNX: Chris Herborth ([email protected]) writes:
|
|---|
| 463 | configure works best if you use GNU bash; a port is available on
|
|---|
| 464 | ftp.qnx.com in /usr/free. I used the following process to build,
|
|---|
| 465 | test and install Python 1.5.x under QNX:
|
|---|
| 466 |
|
|---|
| 467 | 1) CONFIG_SHELL=/usr/local/bin/bash CC=cc RANLIB=: \
|
|---|
| 468 | ./configure --verbose --without-gcc --with-libm=""
|
|---|
| 469 |
|
|---|
| 470 | 2) edit Modules/Setup to activate everything that makes sense for
|
|---|
| 471 | your system... tested here at QNX with the following modules:
|
|---|
| 472 |
|
|---|
| 473 | array, audioop, binascii, cPickle, cStringIO, cmath,
|
|---|
|
|---|