Public bug reported:

I'm trying to load a 32bit application (Firefox 3 from mozilla.org) on
amd64 Hardy, and I'm getting the error:

Gtk-WARNING **: Error loading theme icon 'gtk-ok' for stock: Unable to
load image-loading module: /usr/lib/gtk-2.0/2.10.0/loaders
/libpixbufloader-png.so: /usr/lib/gtk-2.0/2.10.0/loaders
/libpixbufloader-png.so: wrong ELF class: ELFCLASS64

This has been reported in
https://bugs.launchpad.net/ubuntu/+source/ia32-libs/+bug/177869 for
instance.

This worked on gutsy, the regression seems to be related to this Debian bug:
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=439004

   [ Josselin Mouette ]
   * 020_immodules-files-d.patch, 021_loader-files-d.patch: read the
     GDK_PIXBUF_MODULE_FILE and GTK_IM_MODULE_FILE variables before the
     Debian directories. Thanks Thadeu Lima de Souza Cascardo.
     Closes: #439004.

The issue is that the GtkPixbuf modules loading order changed, so that
the 64bit loaders are loaded after the 32bit ones, so it fails.

Here's a strace from Gutsy (kept only meaningful calls):

7773  open("/usr/lib/gtk-2.0/2.10.0/loaders/../loader-files.d", 
O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY) = 21
7773  
open("/usr/lib/gtk-2.0/2.10.0/loaders/../loader-files.d/libgtk2.0-0.loaders", 
O_RDONLY|O_LARGEFILE) = 22
7773  
open("/usr/lib/gtk-2.0/2.10.0/loaders/../loader-files.d/librsvg2-common.loaders",
 O_RDONLY|O_LARGEFILE) = 22
7773  open("/etc/gtk-2.0/gdk-pixbuf.loaders.32", O_RDONLY|O_LARGEFILE) = 21
7773  stat64(0x835e328, 0xffe83a2c)     = 0
7773  open("/usr/lib32/gtk-2.0/2.10.0/loaders/libpixbufloader-png.so", 
O_RDONLY) = 21 <-- OK: we're loading the 32bit module

Strace from Hardy:

19698 open("/etc/gtk-2.0/gdk-pixbuf.loaders.32", O_RDONLY|O_LARGEFILE) = 21
19698 open("/usr/lib/gtk-2.0/2.10.0/loaders/../loader-files.d", 
O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY|0x80000) = 21
19698 
open("/usr/lib/gtk-2.0/2.10.0/loaders/../loader-files.d/libwmf0.2-7.loaders", 
O_RDONLY|O_LARGEFILE) = 22
19698 
open("/usr/lib/gtk-2.0/2.10.0/loaders/../loader-files.d/libgtk2.0-0.loaders", 
O_RDONLY|O_LARGEFILE) = 22
19698 
open("/usr/lib/gtk-2.0/2.10.0/loaders/../loader-files.d/librsvg2-common.loaders",
 O_RDONLY|O_LARGEFILE) = 22
19698 open("/usr/lib/gtk-2.0/2.10.0/loaders/libpixbufloader-png.so", O_RDONLY) 
= 21  <-- ISSUE HERE: the 64bit module is read, which will fail to load with a 
32bit binary.


I think one good way to solve this issue may be to first look if directory 
/usr/lib32/gtk-2.0/2.10.0/loaders exists, and use that instead of PIXBUF_LIBDIR 
for the gdkpixbuf_module_files_d_str variable (021_loader-files-d.patch).

(The other quick and dirty way would be to revert the Debian patch.
Unfortunately this also reverts the issue that the reporter was having,
but this issue here may be more important for Hardy users of 32bit
software on amd64).

** Affects: gtk+2.0 (Ubuntu)
     Importance: Undecided
         Status: New

-- 
32bit GdkPixbuf modules not loaded when using ia32-libs
https://bugs.launchpad.net/bugs/205223
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to