[vtkusers] I'm stupid - (Python 2.0 question)

Jonathan M. Gilligan jonathan.gilligan at vanderbilt.edu
Fri Dec 15 16:53:47 EST 2000


I don't put anything in WINNT/System (that's a godawful practice! 
Thankfully, MS has forbidden this in Win 2K). I put them in their own 
directory, let's call it "/bin/vtkdlls". I add "/bin/vtkdlls" to my PATH 
and add the following key to my registry:

HKLM/Software/Python/PythonCore/2.0/PythonPath/vtk

and give this key a default value of type REG_SZ and value "\bin\vtkdlls".

Now everything works like a charm!

You don't have to do anything with the .lib files to use Python. You only 
need the .dll files.

If you want to build binary Python extensions, then you will need to link 
with the vtk*.lib files, but since you may want to link other things than 
Python extensions (MFC or wxWindows programs, perhaps) to the vtk 
libraries, I prefer to leave them in the /vtk directory hierarchy.

At 11:52 AM 12/15/2000, Justin Vose wrote:
>The answer to the question:
>
>Place vtk.dll in WINNT/System
>Place all other DLLs in Python20/DLLs
>Place all .lib's (except vtk.lib) in Python20/libs
>Rename the 'python' directory to vtk (or whatever) and copy into Python20
>Create a file in Python20 called 'vtkpython.pth' - contents: whatever you
>renamed the 'python' directory to above.
>
>Fire up python.  Import vtkpython - and go nuts.

Jonathan





More information about the vtkusers mailing list