blob: 7709fb807b23e51333e1088ce7d7f8a632a642a3 [file] [log] [blame]
Guido van Rossumebd87061996-09-06 21:45:27 +00001Python 1.4beta3 for Windows NT 3.5 and Windows 95
2=================================================
Guido van Rossumf71f6131996-09-03 15:08:36 +00003
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
Guido van Rossumd8b4dd61996-10-21 14:54:59 +000014Unzip the archive on a file system with enough space. It will create
15a directory Python1.4b3 containing subdirectories Bin and Lib and some
16files, including setup.bat, setup.py, uninstall.bat, and uninstall.py.
17(If you don't have a zip program that supports long filenames, get the
18file winzip95.exe and install it -- this is WinZip 6.1 for 32-bit
19Windows 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
Guido van Rossumd8b4dd61996-10-21 14:54:59 +000047"C:\TCL\lib\tcl7.5" and set TK_LIBRARY to "C:\TCL\lib\tk4.1". Also
48add the directory "C:\TCL\bin" (or whereever the Tcl bin directory
49ended up) to the PATH environment variable.
Guido van Rossumf71f6131996-09-03 15:08:36 +000050
Guido van Rossum2b880611996-09-03 21:20:52 +000051On Windows '95, you need to edit AUTOEXEC.BAT for this, e.g. by adding
52the lines
53
54 SET TCL_LIBRARY=C:\Program Files\TCL\lib\tcl7.5
55 SET TK_LIBRARY=C:\Program Files\TCL\lib\tk4.1
Guido van Rossum2b880611996-09-03 21:20:52 +000056 SET PATH="%PATH%";"C:\Program Files\TCL\bin"
57
58(substituting the actual location of the TCL installation directory).
Guido van Rossum03dea6d1996-09-03 18:19:12 +000059
Guido van Rossumf71f6131996-09-03 15:08:36 +000060Once Tcl/Tk is installed, you should be able to type the following
61commands in Python:
62
63 >>> import Tkinter
64 >>> Tkinter._test()
65
66This creates a simple test dialog box (you may have to move the Python
67window a bit to see it). Click on OK to get the Python prompt back.
68
Guido van Rossum2b880611996-09-03 21:20:52 +000069
70Troubleshooting
71---------------
72
73The following procedure will test successive components required for
74successful use of Python and Tkinter. The steps before "import
75_tkinter" can be used to verify the proper installation of the Python
76core.
77
78- First, run the Python interpreter (python.exe). This should give
79you a ">>>" prompt in a "MS-DOS console" window. This may fail with a
80complaint about being unable to find the file MSVC40RT.DLL. This file
81(along with several other files) is included in the MSOFTDLL.EXE
82self-extracting archive available in the /pub/python/wpy directory on
83ftp.python.org. After extraction, move MSVCRT40.NT to
84\Windows\System\MSVCRT40.DLL (note the change of extension).
85
86- If you can't get a ">>>" prompt, your core Python installation may
87be botched. Reinstall from the ZIP file (see above) and run
88SETUP.BAT.
89
90- At the ">>>" prompt, type a few commands. Each command should
91succeed without complaints. Remember that Python is a case sensitive
92language, so type the commands exactly as shown ("tkinter" and
93"Tkinter" are two very different things).
94
95>>> import sys
96
97 If this fails, you can't type :-) (Explanation: this is a
98 built-in module that is pre-initialized before the first ">>>"
99 prompt is printed. There is no way that this import can fail
100 except by a typo.)
101
102>>> import string
103
104 If this fails, the Python library cannot be found. Reinstall
105 Python. (Explanation: the registry entry for PythonPath is
106 botched. Inspect sys.path to see what it is. If it is
107 something like ['.', '.\\lib', '.\\lib\\win'], the setup.py
108 script has not run successfully and you may get away with
109 rerunning the SETUP.BAT file.)
110
111>>> import _tkinter
112
113 This can fail in a number of ways:
114
115 ImportError: No module named _tkinter
116 The Python module file _tkinter.dll can't be found.
117 Since it is installed by default, the installation is
118 probably botched. Reinstall Python.
119
120 ImportError: DLL load failed: The specified module could not
121 be found. (Possibly with a dialog box explaining that
122 TCL75.DLL or TK41.DLL could not be found.)
123 Probably a Tcl/Tk installation error. Reinstall Tcl/Tk.
124 Note that on Windows '95, you may need to add the Tcl
125 bin directory to the PATH environment variable.
126
127 Other failures:
128 It may be possible that you have an early prerelease
129 TCL75.DLL or TK41.DLL, which is incompatible with the
130 _tkinter module in the Python distribution. This will
131 most likely result in error messages that don't make a
132 lot of sense. Try installing Tcl/Tk from the
133 win41p1.exe self-extracting archive found in
134 /pub/python/nt on ftp.python.org.
135
136>>> import Tkinter
137
138 If this fails, your Python library or sys.path is botched.
139 Your best bet, again, is to reinstall Python.
140
141>>> Tkinter._test()
142
143 This should pop up a window with a label ("Proof-of-existence
144 test for TK") and two buttons ("Click me!" and "QUIT").
145 If you get nothing at all (not even a ">>>" prompt), the
146 window is probably hiding behind the Python console window.
147 Move the console window around to reveal the test window.
148
149 If you get an exception instead, it is most likely a verbose
150 complaint from Tcl/Tk about improper installation. This is
151 usually caused by bad or missing values for the environment
152 variables TK_LIBRARY or TCL_LIBRARY. See the installation
153 instructions above.
154
155
156To uninstall
157------------
Guido van Rossum03dea6d1996-09-03 18:19:12 +0000158
159Run the batch file UNINSTALL.BAT. This will run the Python script
160uninstall.py, which undoes the registry additions and removes most
161installed files. The batch file then proceed to remove some files
162that the Python script can't remove (because it's using them). The
163batch file ends with an error because it deletes itself. Hints on how
164to avoid this (and also on how to remove the installation directory
165itself) are gracefully accepted.
166
Guido van Rossum2b880611996-09-03 21:20:52 +0000167
Guido van Rossum03dea6d1996-09-03 18:19:12 +0000168September 3, 1996
Guido van Rossumf71f6131996-09-03 15:08:36 +0000169
170--Guido van Rossum (home page: http://www.python.org/~guido/)