blob: 783fc1e6afbf44739665fd3c1433ecd65aa94279 [file] [log] [blame]
Guido van Rossumf71f6131996-09-03 15:08:36 +00001Python 1.4beta3 for Windows NT 3.5
2==================================
3
4The zip file pyth14b3.zip contains a preliminary binary release of
Guido van Rossum03dea6d1996-09-03 18:19:12 +00005Python 1.4beta3 for Windows NT 3.5 and Windows '95, with Tcl/Tk
6support. The installation has not been tested on Windows 3.1 with
7Win32s. For general information on Python, see
8http://www.python.org/.
Guido van Rossumf71f6131996-09-03 15:08:36 +00009
Guido van Rossum2b880611996-09-03 21:20:52 +000010
11To install
12----------
Guido van Rossumf71f6131996-09-03 15:08:36 +000013
14Unzip the archive in the root of a file system with enough space. It
15will create a directory \Python1.4b3 containing subdirectories Bin and
Guido van Rossum03dea6d1996-09-03 18:19:12 +000016Lib and some files, including setup.bat, setup.py, uninstall.bat, and
17uninstall.py. (If you don't have a zip program that supports long
18filenames, get the file winzip95.exe and install it -- this is WinZip
196.1 for 32-bit Windows systems.)
Guido van Rossumf71f6131996-09-03 15:08:36 +000020
21Run the SETUP.BAT file found in directory just created. When it is
22done, press Enter.
23
Guido van Rossum2b880611996-09-03 21:20:52 +000024Tcl/Tk support requires additional installation steps, see below.
25
26
27To use
28------
Guido van Rossumf71f6131996-09-03 15:08:36 +000029
30Python runs in a console (DOS) window. From the File Manager, run the
31file python.exe found in the Bin subdirectory. You can also drag it
32to a program group of your choice for easier access. Opening any file
33ending in .py from the file manager should run it.
34
Guido van Rossumf71f6131996-09-03 15:08:36 +000035
Guido van Rossum2b880611996-09-03 21:20:52 +000036To use with Tkinter
37-------------------
38
39Get the file win41p1.exe from /pub/python/nt/ on ftp.python.org or
40from ftp site ftp.sunlabs.com, directory /pub/tcl/. This is a
41self-extracting archive containing the Tcl/Tk distribution for Windows
42NT. Don't use an older version.
Guido van Rossumf71f6131996-09-03 15:08:36 +000043
44Using the control panel, set the TCL_LIBRARY and TK_LIBRARY
45environment variables. E.g. if you installed Tcl/Tk in C:\TCL (the
46default suggested by the installer), set TCL_LIBRARY to
47"C:\TCL\lib\tcl7.5" and set TK_LIBRARY to "C:\TCL\lib\tk4.1".
48
Guido van Rossum2b880611996-09-03 21:20:52 +000049On Windows '95, you need to edit AUTOEXEC.BAT for this, e.g. by adding
50the lines
51
52 SET TCL_LIBRARY=C:\Program Files\TCL\lib\tcl7.5
53 SET TK_LIBRARY=C:\Program Files\TCL\lib\tk4.1
54
55(substituting the actual location of the TCL installation directory).
56
Guido van Rossum03dea6d1996-09-03 18:19:12 +000057On Windows '95, you also need to add the directory "C:\TCL\bin" (or
58whereever the Tcl bin directory ended up) to the PATH environment
Guido van Rossum2b880611996-09-03 21:20:52 +000059variable in the AUTOEXEC.BAT file. Do this by editing the
60AUTOEXEC.BAT file, e.g. by adding this line to the end:
61
62 SET PATH="%PATH%";"C:\Program Files\TCL\bin"
63
64(substituting the actual location of the TCL installation directory).
Guido van Rossum03dea6d1996-09-03 18:19:12 +000065
Guido van Rossumf71f6131996-09-03 15:08:36 +000066Once Tcl/Tk is installed, you should be able to type the following
67commands in Python:
68
69 >>> import Tkinter
70 >>> Tkinter._test()
71
72This creates a simple test dialog box (you may have to move the Python
73window a bit to see it). Click on OK to get the Python prompt back.
74
Guido van Rossum2b880611996-09-03 21:20:52 +000075
76Troubleshooting
77---------------
78
79The following procedure will test successive components required for
80successful use of Python and Tkinter. The steps before "import
81_tkinter" can be used to verify the proper installation of the Python
82core.
83
84- First, run the Python interpreter (python.exe). This should give
85you a ">>>" prompt in a "MS-DOS console" window. This may fail with a
86complaint about being unable to find the file MSVC40RT.DLL. This file
87(along with several other files) is included in the MSOFTDLL.EXE
88self-extracting archive available in the /pub/python/wpy directory on
89ftp.python.org. After extraction, move MSVCRT40.NT to
90\Windows\System\MSVCRT40.DLL (note the change of extension).
91
92- If you can't get a ">>>" prompt, your core Python installation may
93be botched. Reinstall from the ZIP file (see above) and run
94SETUP.BAT.
95
96- At the ">>>" prompt, type a few commands. Each command should
97succeed without complaints. Remember that Python is a case sensitive
98language, so type the commands exactly as shown ("tkinter" and
99"Tkinter" are two very different things).
100
101>>> import sys
102
103 If this fails, you can't type :-) (Explanation: this is a
104 built-in module that is pre-initialized before the first ">>>"
105 prompt is printed. There is no way that this import can fail
106 except by a typo.)
107
108>>> import string
109
110 If this fails, the Python library cannot be found. Reinstall
111 Python. (Explanation: the registry entry for PythonPath is
112 botched. Inspect sys.path to see what it is. If it is
113 something like ['.', '.\\lib', '.\\lib\\win'], the setup.py
114 script has not run successfully and you may get away with
115 rerunning the SETUP.BAT file.)
116
117>>> import _tkinter
118
119 This can fail in a number of ways:
120
121 ImportError: No module named _tkinter
122 The Python module file _tkinter.dll can't be found.
123 Since it is installed by default, the installation is
124 probably botched. Reinstall Python.
125
126 ImportError: DLL load failed: The specified module could not
127 be found. (Possibly with a dialog box explaining that
128 TCL75.DLL or TK41.DLL could not be found.)
129 Probably a Tcl/Tk installation error. Reinstall Tcl/Tk.
130 Note that on Windows '95, you may need to add the Tcl
131 bin directory to the PATH environment variable.
132
133 Other failures:
134 It may be possible that you have an early prerelease
135 TCL75.DLL or TK41.DLL, which is incompatible with the
136 _tkinter module in the Python distribution. This will
137 most likely result in error messages that don't make a
138 lot of sense. Try installing Tcl/Tk from the
139 win41p1.exe self-extracting archive found in
140 /pub/python/nt on ftp.python.org.
141
142>>> import Tkinter
143
144 If this fails, your Python library or sys.path is botched.
145 Your best bet, again, is to reinstall Python.
146
147>>> Tkinter._test()
148
149 This should pop up a window with a label ("Proof-of-existence
150 test for TK") and two buttons ("Click me!" and "QUIT").
151 If you get nothing at all (not even a ">>>" prompt), the
152 window is probably hiding behind the Python console window.
153 Move the console window around to reveal the test window.
154
155 If you get an exception instead, it is most likely a verbose
156 complaint from Tcl/Tk about improper installation. This is
157 usually caused by bad or missing values for the environment
158 variables TK_LIBRARY or TCL_LIBRARY. See the installation
159 instructions above.
160
161
162To uninstall
163------------
Guido van Rossum03dea6d1996-09-03 18:19:12 +0000164
165Run the batch file UNINSTALL.BAT. This will run the Python script
166uninstall.py, which undoes the registry additions and removes most
167installed files. The batch file then proceed to remove some files
168that the Python script can't remove (because it's using them). The
169batch file ends with an error because it deletes itself. Hints on how
170to avoid this (and also on how to remove the installation directory
171itself) are gracefully accepted.
172
Guido van Rossum2b880611996-09-03 21:20:52 +0000173
Guido van Rossum03dea6d1996-09-03 18:19:12 +0000174September 3, 1996
Guido van Rossumf71f6131996-09-03 15:08:36 +0000175
176--Guido van Rossum (home page: http://www.python.org/~guido/)