40

I am trying to run Chamsys MagicQ on Ubuntu 12.10 with 64bit AMD processor.
This is what it tells me when I try to run the program.

./magicq: error while loading shared libraries: libGLU.so.1: cannot open shared object >file: No such file or directory

Here is the list of library dependencies for MagicQ:

austin@ubuntu:~/magicq$ ldd ./magicq
linux-gate.so.1 => (0xf7799000)
libGLU.so.1 => not found
libusb-0.1.so.4 => not found
libQt5PrintSupport.so.5 => not found
libQt5OpenGL.so.5 => not found
libQt5Widgets.so.5 => not found
libQt5Network.so.5 => not found
libQt5Gui.so.5 => not found
libQt5Core.so.5 => not found
libGL.so.1 => /usr/lib32/fglrx/libGL.so.1 (0xf7694000)
libpthread.so.0 => /lib/i386-linux-gnu/libpthread.so.0 (0xf7679000)
libstdc++.so.6 => not found
libm.so.6 => /lib/i386-linux-gnu/libm.so.6 (0xf764d000)
libgcc_s.so.1 => /lib/i386-linux-gnu/libgcc_s.so.1 (0xf762e000)
libc.so.6 => /lib/i386-linux-gnu/libc.so.6 (0xf7483000)
libXext.so.6 => not found
libatiuki.so.1 => /usr/lib32/fglrx/libatiuki.so.1 (0xf746c000)
libdl.so.2 => /lib/i386-linux-gnu/libdl.so.2 (0xf7467000)
/lib/ld-linux.so.2 (0xf779a000)

I know libGLU.so.1 is in /usr/lib/x86_64-linux-gnu as a "link to shared library (application/x-sharedlib)" Link target: "libGLU.so.1.3.1" How do I fix this?

7 Answers 7

46

Actually I couldn't find libglu package itself. What helped is:

sudo apt-get install libglu1-mesa:i386

Ubuntu 14.04 x64

4
  • 2
    Also worked on Ubuntu 17.04. Cheers! Oct 23, 2017 at 3:10
  • 1
    Glad to hear that!
    – Daniel
    Oct 25, 2017 at 11:27
  • 2
    How did you get it working in 18.04? Mine says Unable to locate package libglu1-mesa:i386 after apt-get update
    – Geordie
    Oct 30, 2019 at 0:05
  • 1
    for 18.04 this worked for me: sudo apt-get install libglu1-mesa
    – j314erre
    Mar 27, 2021 at 14:32
21

I just needed to install this, without any 32-bit or 64-bit reference.

sudo apt-get install libglu1
2
  • This worked for me on Ubuntu 17.10 (64-bit). Thanks!
    – sunyata
    Jan 18, 2018 at 19:04
  • This also worked for Sublime text in WSLg (Windows 10). Thanks! Jul 4, 2023 at 5:50
13

I figured it out. I had to install the 32-bit versions.

For anyone else who may have the same problem and is running a 64-bit operating system. Find the packages that include the missing files and use:

sudo apt-get install package:i386

Change "package" to the name of the package. Without the ":i386" it will install the 64 bit version only.

4

In case anyone is reading this using Ubuntu 18.04, here's one way to search for the package to install. I got this error when trying to run Blender on a new Ubuntu 18.04 machine from a cloud computing instance. Here was the error, where I try to check if Blender 2.82a is installed correctly by printing out the version:

user@init-blender-test:~/blender-2.82a-linux64$ ./blender --version
./blender: error while loading shared libraries: libGL.so.1: cannot open shared object file: No such file or directory

To find the package to install, I did an apt-file search:

user@init-blender-test:~/blender-2.82a-linux64$ apt-file search libGL.so.1
libgl1: /usr/lib/x86_64-linux-gnu/libGL.so.1
libgl1: /usr/lib/x86_64-linux-gnu/libGL.so.1.0.0
nvidia-340: /usr/lib/i386-linux-gnu/libGL.so.1
nvidia-340: /usr/lib/x86_64-linux-gnu/libGL.so.1
primus-libs: /usr/lib/x86_64-linux-gnu/primus/libGL.so.1
virtualbox-guest-x11: /usr/lib/virtualbox/additions/libGL.so.1
virtualbox-guest-x11-hwe: /usr/lib/virtualbox/additions/libGL.so.1

See this StackOverflow answer for more details. If apt-file isn't found, you may need to install it with sudo apt install apt-file.

Therefore, from the above, I see that sudo apt install libgl1 can be used, and it fixed my error. Note that there are multiple packages that reference the missing file (nvidia-340, etc.) so you'll have to judge and test for yourself on a case-by-case basis.

1
  • this worked well, in my case libgl1 didn't work and it showed i needed to do sudo apt install libglu1-mesa
    – j314erre
    Mar 27, 2021 at 14:31
2

i needed libGLU.so.1 for a game i wanted to play (The Fall) and got this error:

error while loading shared libraries: libGLU.so.1: cannot open shared
object file: No such file or directory

after a search i found a bug page where someone mentioned ia32-libs, and after installing that im up and runnig.

page i found:

https://bugs.launchpad.net/linuxmint/+bug/891578

Command i ran:

sudo apt-get install ia32-libs
1
  • 1
    That's the solution for older Ubuntu Distros ia32-lib is deprecated now. Daniel in previous comment is correct for newer Distros. Well at least as an answer to the first error posted in OP.
    – JohnRB
    Sep 25, 2014 at 19:14
1

I had same kind of problem when i had deleted some of the files, i got them back using this command

sudo apt-get install libglew-dev libcheese7 libcheese-gtk23 libclutter-gst-2.0-0 libcogl15 libclutter-gtk-1.0-0 libclutter-1.0-0

Hope it would work.

1

This would help

sudo apt-get install libgl1-mesa-dri:i386 libglapi-mesa:i386  libglx-mesa0:i386  libglx0:i386  libgl1:i386 libgl1-mesa-glx:i386 libglu1-mesa:i386 
1
  • 4
    Why would this help?
    – Pilot6
    Sep 2, 2019 at 11:30

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .