Install libraries only without the program itself

Gregor Horvath g.horvath at gmx.at
Thu May 11 19:08:45 CEST 2006


Serge Orlov schrieb:

> I believe it's better to keep *everything* on the file server. Suppose

Certainly!

> your OS is windows and suppose you want to keep everything in s:/tools.
> The actions are:
> 3. Create little dispatcher s:/tools/win32/client.py:
> #!s:/tools/python24-win32/python.exe
> import sys
> sys.path[0] = "s:/tools/client-1.0.0"
> import client

I also had to set the paths for the imports and current directory
manually (why?). This worked for me:

#!y:/python24-win32/python24.dll
import sys
import os
sys.path =
["","y:\\","y:\\python24-win32\\lib\\site-packages","y:\\python24-win32\\DLLs","y:\\python24-win32\\lib","y:\\python24-win32\\lib\\plat-win","y:\\python24-win32\\lib\\lib-tk","y:\\python24-win32",
"y:\\python24-win32\\lib\\site-packages\\win32",
"y:\\python24-win32\\lib\\site-packages\\win32\\lib",
"y:\\python24-win32\\lib\\site-packages\\Pythonwin",
"Y:\\python24-win32\\python24.zip","y:\\python24-win32"]
os.chdir("y:\\")

import hobel300


5. I also had to copy all required dlls from the c:\winnt directory (for
example pywintypes24.dll) into the current directory.

Thanks for this solution, works great, did not know that you can run
python programs even without a python installation on the local machine!
Nice!

-- 
  Servus, Gregor
  http://www.gregor-horvath.com



More information about the Python-list mailing list