"libstdc++.so.6: cannot open shared object file: No such file or directory"
I wrastled with the program according to the info in this question. Now it is installed but I can't figure out how to run it. A friend running the same version of Ubuntu had no problems getting it to start after installing it the same way.
This is what I've done:
$ ./Psychonauts
./Psychonauts: error while loading shared libraries: libstdc++.so.6: cannot open shared object file: No such file or directory
So I went ahead and:
$ sudo apt-get install libstdc++.so.6
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package libstdc++.so.6
E: Couldn't find any package by regex 'libstdc++.so.6'
It should be noted that I only started using Linux a few days ago.
Okay, so I did manage to install apt-file and apt-file update.
However then we hit another snag.
usagiyojimbo@Usagi:~$ sudo apt-file find libstdc++.so.6
[sudo] password for usagiyojimbo:
E: The cache is empty. You need to run 'apt-file update' first.
I have done that, when I do it says:
File is up-to-date.
Ignoring source without Contents File:
a link they won't let me post
Or
File is up-to-date.
Downloading Index a link
No Index available.
Downloading complete file a link
I am still getting the same error when I try to run Psychonauts.
Solution 1:
You get the error message:
E: Unable to locate package libstdc++.so.6 E: Couldn't find any package by regex 'libstdc++.so.6'
because you tried to install a file libstdc++.so.6
that you can't install, because it is located in a debian package.
You can use apt-file
to search for the package that contains that file. To install it, type:
sudo apt-get install apt-file
Then you have to update the index.
sudo apt-file update
After that, you can search for the package which contains the file libstdc++.so.6
:
sudo apt-file find libstdc++.so.6
Then you find a lot packages that contains the searched file. In your case, the correct package is libstdc++6
:
libstdc++6: /usr/lib/x86_64-linux-gnu/libstdc++.so.6
Then you can install the needed package:
sudo apt-get install libstdc++6
Solution 2:
I think Psychonauts is a 32bit application. You will need to install:
apt-get install lib32stdc++6