On Fri, 22 Jun 2001, James Henstridge wrote:
> On Thu, 21 Jun 2001, Frank Miles wrote:
>
> > On Thu, 21 Jun 2001, Alexandre Fayolle wrote:
> >
> > > Frank Miles wrote:
> > >
> > > > I'm trying to install pygtk and libglade on a Win9x system. The local
> > > > Windows guy advises me that it is necessary to edit the Windows registry
> > > > to install DLLs. Is this truly the case with the DLLs associated with
> > > > these?
> > >
> > > Well, AFAIK, this is simply not true. The DLLs just have to be in your
> > > PATH, so what is generally done on windows is putting them in c:\windows
> >
> > That's good news. I'll try that. Using regsvr32.exe (per another person's
> > recommendation) didn't work -- the program emits an error code with (AFAIK)
>
> AFAIK, regsvr is used to register COM servers with the OS. Python
> extensions are not COM objects, so they don't need registering (not every
> DLL is a COM object).
>
> > no table of meanings available. I eventually installed the whole of Gimp;
> > that's _way_ more than I need! Not only that, (this is the weird part),
> > doing an 'import gtk' fails on the first try (complaining of missing _gtk),
> > but succeeds on the second try, even after gimp was installed. If I restart
> > idle, the same pattern occurs.
>
> You will probably need to make sure the _gtk module (I don't know what the
> filename would be under win32 -- probably _gtk.dll, _gtk.pyd,
> _gtkmodule.dll or _gtkmodule.pyd) is in your python path, and the gtk dlls
> are in the executable path (current directory or in windows system
> directory, usually).
I have a _gtk.pyd in c:\windows\system. It still only imports on the 2nd try.
If that was the only thing wrong, it would be easy to live with, simply use
a try: import .. , except: import .. There's something more seriously wrong,
though. When I try the simple script (based on a tutorial):
#!/usr/bin/env python
try:
from gtk import *
except:
from gtk import *
window = GtkWindow()
window.connect('destroy', mainquit)
window.show_all()
mainloop()
the following error message is returned:
NameError: There is no variable named 'GtkWindow'
It would appear that gtk is still not fully accessible. This is with
Python2.0, and gtk from the gimp20001226.exe installer. Similarly, libglade
appears to import (again, on the second try), but when I try to load a simple
glade file:
self.widgets = libglade.GladeXML('simple.glade')
...python returns an attribute error regarding GladeXML. I tried substituting
the full path name for 'simple.glade' but this did nothing. {This same simple
app and glade file work fine in Linux}.
Not all is sick. I have installed PyGreSQL (which has a DLL: libpq.dll).
It installed via distutils, and it works _fine_. Peculiarly enough,
libpq.dll is not, AFAICT, in any part of the Python path, nor in a Windows
directory, nor does it appear in the Windows registry.
Any further help, or suggestions on how I might diagnose the real problem
would be appreciated.
-frank
_______________________________________________
pygtk mailing list [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk