PyGTK Question

Tim Evans t.evans at paradise.net.nz
Fri Feb 28 05:47:42 EST 2003


"Adonis" <adonisv at earthlink.net> writes:

> I am trying to run PyGTK (Win32), and am encountering an error, but am
> stooped as in how to fix it, I complains that libglib2.0-0.dll is no
> present, but a search find it in:
> 
>  Directory of C:\Program Files\Common Files\GTK\2.0\lib
[snip]

Check that this directory is listed in your PATH environment variable:

>>> import os
>>> print '\n'.join(os.environ['PATH'].split(';'))

If your GTK directory is not one of the lines produced, that explains
the problem.  Try doing this *before* importing gtk:

>>> os.environ['PATH'] += r';C:\Program Files\Common Files\GTK\2.0\lib'

If this fixes your problem, you can modify the environment variable
permanently.  From memory, this is done by running the 'System'
control panel icon, going to the 'Advanced' tab and clicking on the
'Environment Variables' button.

-- 
Tim Evans




More information about the Python-list mailing list