You are not logged in.

#1 2010-11-07 16:01:14

Midnight Sun
Member
Registered: 2008-06-23
Posts: 47

[SOLVED] ImportError - undefined symbol: gdk_image_get_height

Hello all, thanks for looking.

I'm trying to run Rednotebook from the AUR     http://aur.archlinux.org/packages.php?ID=21984

I have got the two listed dependencies installed - pygtk 2.22.0-3, python-yaml 3.09-2 - and I've got the up to date python 3.1.2-2 installed.

PROBLEM:

When I type "rednotebook" into an xterm window, either as user or as root, I get the following error message:

Traceback (most recent call last):
  File "/usr/bin/rednotebook", line 11, in <module>
    import rednotebook.journal
  File "/usr/lib/python2.7/site-packages/rednotebook/journal.py", line 43, in <module>
    from rednotebook.util import utils
  File "/usr/lib/python2.7/site-packages/rednotebook/util/utils.py", line 37, in <module>
    import gtk
  File "/usr/lib/python2.7/site-packages/gtk-2.0/gtk/__init__.py", line 40, in <module>
    from gtk import _gtk
ImportError: /usr/lib/python2.7/site-packages/gtk-2.0/gtk/_gtk.so: undefined symbol: gdk_image_get_height

I notice the error refers to python2.7, but i've got python 3.1.2-2. I thought that would be fine though, cos there is a post about that being updated to 3.x by the Maintainer.

The last line of the error refers to getting information about an image. I wondered if it might be an image that rednotebook was looking for on my machine that I don't have installed. For example, I don't have many icons installed yet. Could that be a problem?

I Googled the error message, but either couldn't really understand the stuff it pointed to, or it seemed not to relate to what I'm trying to do.

Can anybody give me any ideas?

Thanks

Last edited by Midnight Sun (2010-11-09 22:19:59)

Offline

#2 2010-11-07 17:01:48

Midnight Sun
Member
Registered: 2008-06-23
Posts: 47

Re: [SOLVED] ImportError - undefined symbol: gdk_image_get_height

P.S.

I'm running X, and Openbox 3.4.11.2-1

Offline

#3 2010-11-07 17:44:50

hexanol
Member
From: Canaduh
Registered: 2009-08-04
Posts: 95

Re: [SOLVED] ImportError - undefined symbol: gdk_image_get_height

Launch an interactive python 2.7 interpreter, type 'import gtk' and see it it raise an exception.

$ python2.7
Python 2.7 (r27:82500, Oct 20 2010, 03:28:42) 
[GCC 4.5.1] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import gtk
>>> 

If it does not, than I'm confused. It if does, I'm also confused, but less.

Offline

#4 2010-11-07 23:32:52

Midnight Sun
Member
Registered: 2008-06-23
Posts: 47

Re: [SOLVED] ImportError - undefined symbol: gdk_image_get_height

Thanks for your help.

I did what you suggested:

[rich@myhost ~]$ python2.7

Python 2.7 (r27:82500, Oct 20 2010, 03:21:03) 
[GCC 4.5.1] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import gtk
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python2.7/site-packages/gtk-2.0/gtk/__init__.py", line 40, in <module>
    from gtk import _gtk
ImportError: /usr/lib/python2.7/site-packages/gtk-2.0/gtk/_gtk.so: undefined symbol: gdk_image_get_height

>>> 

So that's the same error. That's a good start.

I'll look into what gtk packages I have got installed, and see if anything might be missing.

Any ideas?

Didn't know you could type python like that... is it like entering a 'python shell', a bit like a bash shell?

Cheers,
rich.

Offline

#5 2010-11-08 00:19:19

wonder
Developer
From: Bucharest, Romania
Registered: 2006-07-05
Posts: 5,941
Website

Re: [SOLVED] ImportError - undefined symbol: gdk_image_get_height

try reinstall pygtk, gdk-pixbuf2 and gtk2


Give what you have. To someone, it may be better than you dare to think.

Offline

#6 2010-11-08 00:31:14

Midnight Sun
Member
Registered: 2008-06-23
Posts: 47

Re: [SOLVED] ImportError - undefined symbol: gdk_image_get_height

When you say RE-installing...

[rich@myhost ~]$ pacman -Q pygtk
pygtk 2.22.0-3

[rich@myhost ~]$ pacman -Q gdk-pixbuf2
error: package "gdk-pixbuf2" not found

[rich@myhost ~]$ pacman -Q gtk2
gtk2 2.20.1-2

... I might try installing gdk-pixbuf2, then.

Thanks for that.

Last edited by Midnight Sun (2010-11-08 00:31:35)

Offline

#7 2010-11-08 00:46:23

Midnight Sun
Member
Registered: 2008-06-23
Posts: 47

Re: [SOLVED] ImportError - undefined symbol: gdk_image_get_height

Tried to install gdk-pixbuf2 but:

[root@myhost rich]#  pacman -S gdk-pixbuf2
resolving dependencies...
looking for inter-conflicts...

Targets (1): gdk-pixbuf2-2.22.0-2

Total Download Size:    0.53 MB
Total Installed Size:   4.38 MB

Proceed with installation? [Y/n] y
:: Retrieving packages from extra...

 gdk-pixbuf2-2.22.0...   545.7K  196.1K/s 00:00:03 [######################] 100%
checking package integrity...
(1/1) checking for file conflicts                  [######################] 100%

error: failed to commit transaction (conflicting files)
gdk-pixbuf2: /usr/bin/gdk-pixbuf-csource exists in filesystem
gdk-pixbuf2: /usr/bin/gdk-pixbuf-query-loaders exists in filesystem
gdk-pixbuf2: /usr/lib/girepository-1.0/GdkPixbuf-2.0.typelib exists in filesystem
gdk-pixbuf2: /usr/lib/libgdk_pixbuf-2.0.so exists in filesystem
gdk-pixbuf2: /usr/lib/libgdk_pixbuf-2.0.so.0 exists in filesystem
gdk-pixbuf2: /usr/lib/libgdk_pixbuf_xlib-2.0.so exists in filesystem
gdk-pixbuf2: /usr/lib/libgdk_pixbuf_xlib-2.0.so.0 exists in filesystem
gdk-pixbuf2: /usr/lib/pkgconfig/gdk-pixbuf-2.0.pc exists in filesystem
gdk-pixbuf2: /usr/lib/pkgconfig/gdk-pixbuf-xlib-2.0.pc exists in filesystem
gdk-pixbuf2: /usr/share/gir-1.0/GdkPixbuf-2.0.gir exists in filesystem
Errors occurred, no packages were upgraded.

Can I just delete those files? Will they be created again by the new install of gdk-pixbuf2 ? or is there a cleaner way to sort it out?


Unfortunately I have to go to work now, so I'll try more tomorrow.

But Thank You both very much for all you help. It is much appreciated.

Offline

#8 2010-11-08 00:49:35

Allan
Pacman
From: Brisbane, AU
Registered: 2007-06-09
Posts: 11,383
Website

Re: [SOLVED] ImportError - undefined symbol: gdk_image_get_height

pacman -Qo those files.  If no package owns them, then delete away.

Offline

#9 2010-11-08 00:51:21

hexanol
Member
From: Canaduh
Registered: 2009-08-04
Posts: 95

Re: [SOLVED] ImportError - undefined symbol: gdk_image_get_height

Midnight Sun wrote:

Didn't know you could type python like that... is it like entering a 'python shell', a bit like a bash shell?

Indeed, there is some similarities between the two, but they don't quite play the same role (although you can do programming in bash and you can do command execution in python).

Check this if you want more info.

Offline

#10 2010-11-08 00:53:56

wonder
Developer
From: Bucharest, Romania
Registered: 2006-07-05
Posts: 5,941
Website

Re: [SOLVED] ImportError - undefined symbol: gdk_image_get_height

no wonder (yeah) doesn't work. you have a partial upgraded system. maybe you have gtk2 to ignore, i don't know.

just do a pacman -Syu


Give what you have. To someone, it may be better than you dare to think.

Offline

#11 2010-11-09 21:45:54

Midnight Sun
Member
Registered: 2008-06-23
Posts: 47

Re: [SOLVED] ImportError - undefined symbol: gdk_image_get_height

Hi all,

I did a 'pacman -Qo' on those files, and they were all owned by gtk2.

So I copied them to one side, and did a pacman -Syu

Now everything is working fine.


Lesson learned! -  keep on top of your package management. Keep things up to date.

Thanks to everybody for your help and advice, and to hexanol for the python link.
Really appreciate your help. Without it I would have struggled for ages, and then probably reinstalled the whole Arch, or given up on rednotebook!

Offline

Board footer

Powered by FluxBB