Windows95: initializing Python env on start-up

Michael Dyck MichaelDyck at home.com
Sat Aug 19 21:58:54 EDT 2000


I downloaded PIL for Windows95, and the README says:

    Before you can run the Python interpreter, you must set a number of
    environment variables.  This can be done automatically by running the
    \py152\setup file.
    To get a permanent setup, you can call the setup file from
    autoexec.bat (Windows 95/98), ...

Unfortunately, they don't give the exact syntax for doing this. After some
experimentation in an "MS-DOS Prompt" window, I found that the command

    call C:\Downloaded\py152\setup.bat

had the desired effect, so I added the same line to my C:\AUTOEXEC.BAT
file and restarted Windows. But Windows seems to completely ignore the
line. Specifically, when I start an "MS-DOS Prompt" window, the variables
PYROOT, PYTHONPATH, etc have not been defined, and PATH has not been
modified to include PYROOT.  However, the commands in autoexec.bat before
and after the "call" command *have* been executed.

And yes, I've checked numerous times that the command in the autoexec.bat
file is the same as the one that works at the MS-DOS prompt.

So: is there a different syntax I need to use in order to execute
py152\setup.bat from autoexec.bat?

And if there *were* something wrong with a command in autoexec.bat, would
error messages get written somewhere?

Far-more-at-home-in-Unix-ly y'rs,
-Michael Dyck



More information about the Python-list mailing list