I've been trying to install Python on Windows 2000 SP4, and have run into
the traditional "DLL load failed" error.  The installer files are:

Size     Name
15970304 python-2.7.2.msi
33091012 pygtk-all-in-one-2.22.5.win32-py2.7.msi
  872816 WindowsXP-KB975337-x86-ENU.exe

PyGTK was installed with: TARGETDIR=C:\Python27 ALLUSERS=1 INSTALLLEVEL=2
and the updated gdiplus.dll file copied to
   C:\\Python2X\\Lib\\site-packages\\gtk-2.0\\runtime\\bin
in accordance with the installation instructions.

The result is that I can import pygtk, cairo and pango without problems.
However, importing gtk fails with the message
  "from gtk import _gtk
  ImportError: DLL load failed: The specified procedure could not be found."

I ran "python -v -c "import gtk" >import.log 2>&1 which showed that everything
was going well until:

# C:\Python27\lib\site-packages\gtk-2.0\gobject\propertyhelper.pyc matches
    C:\Python27\lib\site-packages\gtk-2.0\gobject\propertyhelper.py
import gobject.propertyhelper # precompiled from
    C:\Python27\lib\site-packages\gtk-2.0\gobject\propertyhelper.pyc
Traceback (most recent call last):
  File "<string>", line 1, in <module>
File "C:\Python27\lib\site-packages\gtk-2.0\gtk\__init__.py", line 40, in <module>
    from gtk import _gtk
ImportError: DLL load failed: The specified procedure could not be found.

I checked the site-packages/gtk-2.0/gtk directories for linux and windows
installations, and found that they matched apart from two subdirectories:

Directory of C:\Python27\Lib\site-packages\gtk-2.0\gtk
27/10/2010  09:00                5,017 __init__.py
09/11/2010  17:41            1,879,040 _gtk.pyd
27/10/2010  09:00                2,764 _lazyutils.py
27/10/2010  09:00                2,454 compat.py
27/10/2010  09:00                3,032 deprecation.py
09/11/2010  17:42               18,944 glade.pyd
27/10/2010  09:00               29,926 keysyms.py
04/11/2011  10:42                3,173 __init__.pyc

Directory of /usr/lib/python2.7/site-packages/gtk-2.0/gtk
-rw-r--r-- 1 root root    2454 Sep 20 00:15 compat.py
-rw-r--r-- 1 root root    3032 Sep 20 00:15 deprecation.py
drwxr-xr-x 2 root root    4096 Sep 20 00:23 gdkgl
-rwxr-xr-x 1 root root   18172 Sep 20 00:15 glade.so
drwxr-xr-x 2 root root    4096 Sep 20 00:23 gtkgl
-rwxr-xr-x 1 root root 2110444 Sep 20 00:15 _gtk.so
-rw-r--r-- 1 root root    5017 Sep 20 00:15 __init__.py
-rw-r--r-- 1 root root   29926 Sep 20 00:15 keysyms.py
-rw-r--r-- 1 root root    2764 Sep 20 00:15 _lazyutils.py
(.pyc and .pyo files have been removed)

Stephen George's test script simply can't find GTK+ at all, and complains
about ...\gtk-2.0\runtime\bin appearing before the GTK runtime directory,
and that the runtime directory is not on the enviroment path.  (The script
doesn't say what the runtime directory should be.)  However, all the GTK+
DLLs seem to be present in runtime/bin and runtime/lib

Does anyone have a working installation of PyGTK on Windows 2000?
Is there any way of patching the current setup to get it running?

Thanks for any help - Will




_______________________________________________
pygtk mailing list   pygtk@daa.com.au
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://faq.pygtk.org/

Reply via email to