Windows 3.11

James C. Ahlstrom jim at interet.com
Thu May 6 10:11:16 EDT 1999


Zacharias Pigadas wrote:
> 
> Hello,
> I am trying to install python in a windows 3.11 machine but I run accross
> some problems. I may be a bit thick but I could not import string not import
> os but can import time. The machine was clean, no python installed to it
> previously, nothing.  When editing the autoexec.bat file I found out that it
> was referencing one other directory called lib15 that does not exist on my
> machine. I tried looking for the libraries only distribution of python but
> everything came with the equivalent pytohn distribution(win32,linus, etc). I
> have python in WinNT I just need it on 3.11 as well. If I copy my lib
> directory from NT will it work then??

It sounds like your Windows 3.1 machine lacks a copy of the Python
library
files.  Just copy the whole library tree including the subdirectory
structure
from your NT machine.  If you use pkzip, be sure to unzip with the "-d"
option
so you preserve the subdirectories.

When you start the Python binary, import sys, and then enter "print
sys.path".
This shows you what your PYTHONPATH is, and your library directory must
be on
this list.  Otherwise, you can set the environment variable PYTHONPATH
to change
this list.  It may be easier to just choose to use the default
PYTHONPATH.

You should now be able to import "string", but may have problems
importing
long names such as "regex_syntax".  If so, add /lib/dos-8x3 to your
PYTHONPATH.

Jim Ahlstrom




More information about the Python-list mailing list