Running a 32-bit application in Debian Wheezy 64 bits: Missing libraries

21,024

It seems you're missing the 32-bit libraries (/usr/lib/x86_64-linux-gnu contains 64-bit libraries). Now, let's figure out which packages you need for your libraries:

$ dpkg -S /usr/lib/x86_64-linux-gnu/alsa-lib/libasound_module_conf_pulse.so
libasound2-plugins:amd64: /usr/lib/x86_64-linux-gnu/alsa-lib/libasound_module_conf_pulse.so
$ dpkg -S /usr/lib/x86_64-linux-gnu/libGL.so.1
libgl1-mesa-glx:amd64: /usr/lib/x86_64-linux-gnu/libGL.so.1

So you need 32-bit versions of these packages:

# apt-get install libasound2-plugins:i386 libgl1-mesa-glx:i386

In general, before you can install any 32-bit libraries, you must add the i386 architecture to dpkg:

# dpkg --add-architecture i386
# apt-get update

Update

Since the above didn't solve the libGL.so.1 issue and it seems from your ldd output that Aquaria can see all its required libraries, I googled the libGL.so.1 error message and two things came up. Please try the following 2 solutions in order:

  1. As explained here try symlinking libGL.so.1:

    ln -sv /usr/lib/i386-linux-gnu/libGL.so.1.2 /usr/lib/libGL.so.1
    

    Note that I modified the paths from the answer I linked to so that they're relevant to Debian instead.

  2. The answer here suggests that you need to install libgl1-mesa-glx:i386 (which you've already done) plus libgl1-mesa-dri:i386 (which is what I'm suggesting you try next).

Update: What finally worked

apt-get purge libgl1-mesa-glx:i386 
apt-get install libgl1-mesa-glx:i386 
ln -s /usr/lib/mesa-diverted/i386-linux-gnu/libGL.so.1 /usr/lib/i386-linux-gnu/
Share:
21,024

Related videos on Youtube

Гончаренко Александр
Author by

Гончаренко Александр

Updated on September 18, 2022

Comments

  • Гончаренко Александр
    Гончаренко Александр over 1 year

    I want to play the game Aquaria in a Debian Wheezy 64 bits. The installation went ok, but when trying to play the game I get these errors:

    ALSA lib conf.c:3314:(snd_config_hooks_call) Cannot open shared library libasound_module_conf_pulse.so
    ALSA lib control.c:951:(snd_ctl_open_noupdate) Invalid CTL hw:0
    AL lib: alsa.c:1000: control open (0): No such file or directory
    Message: SDL_GL_LoadLibrary Error: Failed loading libGL.so.1
    

    I have added 32 bit compatibility with dpkg --add-architecture i386 and I think that the required libraries are present in the system since typing locate libasound_module_conf_pulse.so yields:

    /usr/lib/x86_64-linux-gnu/alsa-lib/libasound_module_conf_pulse.so

    and locate libGL.so.1:

    /etc/alternatives/glx--libGL.so.1-x86_64-linux-gnu
    /usr/lib/mesa-diverted/i386-linux-gnu/libGL.so.1
    /usr/lib/mesa-diverted/i386-linux-gnu/libGL.so.1.2
    /usr/lib/mesa-diverted/x86_64-linux-gnu/libGL.so.1
    /usr/lib/mesa-diverted/x86_64-linux-gnu/libGL.so.1.2
    /usr/lib/x86_64-linux-gnu/libGL.so.1
    /usr/lib/x86_64-linux-gnu/fglrx/fglrx-libGL.so.1.2
    /usr/lib/x86_64-linux-gnu/fglrx/libGL.so.1
    

    However, it seems that Debian is ignoring them. What can I do to play Aquaria?

    EDIT 1: ldd aquaria

    linux-gate.so.1 =>  (0xf77e1000)
    libSDL-1.2.so.0 => /opt/Aquaria/./libSDL-1.2.so.0 (0xf7748000)
    libopenal.so.1 => /opt/Aquaria/./libopenal.so.1 (0xf76fa000)
    libstdc++.so.6 => /opt/Aquaria/./libstdc++.so.6 (0xf760d000)
    libm.so.6 => /lib/i386-linux-gnu/i686/cmov/libm.so.6 (0xf75c3000)
    libgcc_s.so.1 => /opt/Aquaria/./libgcc_s.so.1 (0xf75b8000)
    libc.so.6 => /lib/i386-linux-gnu/i686/cmov/libc.so.6 (0xf7455000)
    libdl.so.2 => /lib/i386-linux-gnu/i686/cmov/libdl.so.2 (0xf7451000)
    libpthread.so.0 => /lib/i386-linux-gnu/i686/cmov/libpthread.so.0 (0xf7437000)
    librt.so.1 => /lib/i386-linux-gnu/i686/cmov/librt.so.1 (0xf742e000)
    /lib/ld-linux.so.2 (0xf77e2000)
    
  • jordanm
    jordanm almost 11 years
    Just a note for future readers, dpkg --add-architecture i386 needs to be ran before installing the 32bit packages, which OP has already done.
  • Гончаренко Александр
    Гончаренко Александр almost 11 years
    Hi! I did what you suggested and now the libasound error doesn't show up, however the libGL one still happens. In the package manager, the libgl1-mesa-glx:i386 appears as installed.
  • Jeff Hewitt
    Jeff Hewitt almost 11 years
    @KioMarv Please paste the output you get when you run ldd on the Aquaria executable.
  • Гончаренко Александр
    Гончаренко Александр almost 11 years
    @JosephR. Done!
  • Jeff Hewitt
    Jeff Hewitt almost 11 years
    @KioMarv Updating answer.
  • Гончаренко Александр
    Гончаренко Александр almost 11 years
    @JosephR. Did you mean /usr/lib/i386-linux-gnu instead of /usr/i386-linux? And this is strange. Synaptics says that libGL.so.1 is installed in /usr/lib/i386-linux-gnu, but if I do ls -la in that directory, libGL isn't there, only libGLU.
  • Гончаренко Александр
    Гончаренко Александр almost 11 years
    Also, libgl1-mesa-dri:i386 is already installed.
  • Jeff Hewitt
    Jeff Hewitt almost 11 years
    @KioMarv Yes, I meant /usr/lib/i386... Answer corrected. Are you sure you didn't just miss libGL.so.1 in the directory listing? On my system, it's listed in /usr/lib/i386-linux-gnu and dpkg -S shows it's from the libgl1-mesa-glx:i386 package.
  • Гончаренко Александр
    Гончаренко Александр almost 11 years
    @JosephR. I forgot to tell that my video card is an ATI Radeon HD 4500 and I had to install the fglrx-legacy driver. And yes, I'm sure that only libGLU is in that directory. dpkg -S libGL.so.1 prints (among other directories): libgl1-mesa-glx:i386: /usr/lib/i386-linux-gnu/libGL.so.1.2. But doing a ls /usr/lib/i386-linux-gnu/libGL.so.1.2 prints: ls: cannot access /usr/lib/i386-linux-gnu/libGL.so.1.2: No such file or directory
  • Jeff Hewitt
    Jeff Hewitt almost 11 years
  • Гончаренко Александр
    Гончаренко Александр over 10 years
    Hey! I don't know if you get a notification in the chat, but I tried what you suggested and still nothing. I put the locate libGL.so.1 list in the chat.
  • Jeff Hewitt
    Jeff Hewitt over 10 years
    @KioMarv Hi. Have you tried symlinking the existing libGL to the required location? Try ln -s /usr/lib/mesa-diverted/i386-linux-gnu/libGL.so.1 /usr/lib/i386-linux-gnu/libGL.so.1
  • Гончаренко Александр
    Гончаренко Александр over 10 years
    @JosephR. Hi!! Yes, that did it! I'll accept your answer, so can you edit it and add the link solution? Thanks a lot!
  • Jeff Hewitt
    Jeff Hewitt over 10 years
    @KioMarv Since you know better than me what finally worked, how about suggesting an edit to the answer to make it as you would like to see it?
  • Jeff Hewitt
    Jeff Hewitt over 10 years
    @KioMarv I took a shot at editing the answer, please correct me if I missed something.
  • Гончаренко Александр
    Гончаренко Александр over 10 years
    It's everything fine!