blob: 7ff01398b16dcade05986a8e0d3a5b6e27e110ab [file] [log] [blame]
Tim Peters4b5fb072000-07-01 00:03:43 +00001Building Python using VC++ 6.0 or 5.0
Guido van Rossuma29b3602000-03-29 01:51:37 +00002-------------------------------------
Tim Peters4b5fb072000-07-01 00:03:43 +00003This directory is used to build Python for Win32 platforms, e.g. Windows
495, 98 and NT. It requires Microsoft Visual C++ 6.x or 5.x.
Guido van Rossum15b239f1998-05-26 14:16:23 +00005(For other Windows platforms and compilers, see ../PC/readme.txt.)
Tim Peters4b5fb072000-07-01 00:03:43 +00006XXX There are still (Python 2.0b1) a few compiler warnings under VC6.
7XXX There are likely a few more under VC5.
Guido van Rossum15b239f1998-05-26 14:16:23 +00008
Tim Peters4b5fb072000-07-01 00:03:43 +00009Unlike older versions, there's no longer a need to copy the project files
10from a subdirectory of PC/ to the PCbuild directory -- they come in PCbuild.
Guido van Rossum15b239f1998-05-26 14:16:23 +000011
Tim Peters4b5fb072000-07-01 00:03:43 +000012All you need to do is open the workspace "pcbuild.dsw" in MSVC++, select
13the Debug or Release setting (using Build -> Set Active Configuration...),
14and build the projects.
Guido van Rossum15b239f1998-05-26 14:16:23 +000015
Tim Peters4b5fb072000-07-01 00:03:43 +000016The proper order to build subprojects is:
Guido van Rossum15b239f1998-05-26 14:16:23 +000017
Tim Peters4b5fb072000-07-01 00:03:43 +0000181) python20 (this builds the main Python DLL and library files,
19 python20.{dll, lib})
Guido van Rossum15b239f1998-05-26 14:16:23 +000020
Tim Peters4b5fb072000-07-01 00:03:43 +0000212) python (this builds the main Python executable, python.exe)
22
233) the other subprojects, as desired or needed (note: you probably don't
24 want to build most of the other subprojects, unless you're building an
25 entire Python distribution from scratch, or specifically making changes
26 to the subsystems they implement; see SUBPROJECTS below)
Guido van Rossum15b239f1998-05-26 14:16:23 +000027
28When using the Debug setting, the output files have a _d added to
Tim Peters4b5fb072000-07-01 00:03:43 +000029their name: python20_d.dll, python_d.exe, parser_d.pyd, and so on.
Guido van Rossume79cf321998-07-07 22:35:03 +000030
Tim Peters4b5fb072000-07-01 00:03:43 +000031SUBPROJECTS
32-----------
Tim Peters610a8272000-07-01 02:51:23 +000033These subprojects should build out of the box. Subprojects other than the
34main ones (python20, python, pythonw) generally build a DLL (renamed to
35.pyd) from a specific module so that users don't have to load the code
Tim Peters4b5fb072000-07-01 00:03:43 +000036supporting that module unless they import the module.
Guido van Rossume79cf321998-07-07 22:35:03 +000037
Tim Peters4b5fb072000-07-01 00:03:43 +000038python20
39 .dll and .lib
40python
41 .exe
42pythonw
43 pythonw.exe, a variant of python.exe that doesn't pop up a DOS box
44_socket
45 socketmodule.c
46_sre
47 Unicode-aware regular expression engine
48mmap
49 mmapmodule.c
50parser
51 the parser module
52select
53 selectmodule.c
Guido van Rossum74991fa2000-07-01 03:46:38 +000054ucnhash, unicodedata
Tim Peters4b5fb072000-07-01 00:03:43 +000055 large tables of Unicode data
56winreg
57 Windows registry API
58winsound
59 play sounds (typically .wav files) under Windows
60
61The following subprojects will generally NOT build out of the box. They
62wrap code Python doesn't control, and you'll need to download the base
Tim Petersaff12842000-08-25 06:52:44 +000063packages first and unpack them into siblings of PCbuilds's parent
64directory; for example, if your PCbuild is .......\dist\src\PCbuild\,
65unpack into new subdirectories of dist\.
Tim Peters4b5fb072000-07-01 00:03:43 +000066
67_tkinter
Tim Petersaff12842000-08-25 06:52:44 +000068 Python wrapper for the Tk windowing system. Requires tcl832.exe from
Tim Peters610a8272000-07-01 02:51:23 +000069 http://dev.scriptics.com/software/tcltk/downloadnow83.html
Tim Petersaff12842000-08-25 06:52:44 +000070 Run the installer, forcing installation into dist\Tcl.
71 Be sure to install everything, including the Tcl/Tk header files.
Tim Peters4b5fb072000-07-01 00:03:43 +000072
73zlib
74 Python wrapper for the zlib compression library. Requires
75 http://www.winimage.com/zLibDll/zlib133dll.zip
76 and
77 ftp://ftp.uu.net/graphics/png/src/zlib133.zip
Tim Petersaff12842000-08-25 06:52:44 +000078 Unpack the former into dist\zlib113dll.
79 Uppack the latter into dist\zlib113.
Tim Peters4b5fb072000-07-01 00:03:43 +000080
81bsddb
Tim Peters610a8272000-07-01 02:51:23 +000082 Python wrapper for the BSD database 1.85. Requires db.1.85.win32.zip,
83 from the "bsd db" link at
Tim Peters4b5fb072000-07-01 00:03:43 +000084 http://www.nightmare.com/software.html
Tim Petersaff12842000-08-25 06:52:44 +000085 Unpack into dist\bsddb.
86 You then need to compile it: cd to dist\bsddb\Port\win32, and run
87 nmake -f makefile_nt.msc
88 This builds bsddb\Port\win32\db.lib, which the MSVC project links in.
89 Note that if you're running Win9X, you'll need to run vcvars32.bat
90 before running nmake (this batch file is in your MSVC installation).
Tim Peters4b5fb072000-07-01 00:03:43 +000091
92pyexpat
93 Python wrapper for accelerated XML parsing. Requires
94 ftp://ftp.jclark.com/pub/xml/expat.zip
Tim Petersaff12842000-08-25 06:52:44 +000095 Unpack into dist\expat.
Tim Peters4b5fb072000-07-01 00:03:43 +000096
97
98NOTE ON CONFIGURATIONS
99----------------------
100Under Build -> Configuration ..., you'll find several Alpha configurations,
101such as "Win32 Alpha Release". These do not refer to alpha versions (as in
102alpha, beta, final), but to the DEC/COMPAQ Alpha processor. Ignore them if
103you're not building on an Alpha box.
104
105
Tim Petersf9a4a6e2000-07-01 20:38:27 +0000106YOUR OWN EXTENSION DLLs
Tim Peters4b5fb072000-07-01 00:03:43 +0000107-----------------------
108If you want to create your own extension module DLL, there's an example
109with easy-to-follow instructions in ../PC/example/; read the file
110readme.txt there first.