I have a bit of old code that I wrote in RealBasic a few years back which performs a very critical function for our business at work. This particular chunk of code has been running without incident for several years on an Ubuntu server at work with no problems.
Yesterday I made the huge mistake of “upgrading” this particular server to Karmic – Ubuntu 9.10. I should have checked the changes more carefully as I did not realize that in this release the powers that be decided to yank out libstdc++5 and pop libstdc++6 in it’s place. This is likely seen as no big deal for most folks – a new version means progress, right?
Unfortunately, there are many, many apps that are a bit older that were compiled against libstdc++5, not 6… and they will only run if the 32bit version of the library is installed – even on a 64bit machine.
So…. I found myself in a bit of a pickle when I discovered that this had happened. Welcome to some icky error mesages:
error while loading shared libraries: libstdc++.so.5: cannot open shared object file: No such file or directory
I mucked about trying to fool my little app with various incantations of symlinks and forcing new packages to act like the old and such, but that only got me new and even more interesting errors:
/usr/lib32/libstdc++.so.5: version `GLIBCPP_3.2' not found
Luckily, I eventually found this:
cd /tmp
wget http://security.ubuntu.com/ubuntu/pool/universe/i/ia32-libs/ia32-libs_2.7ubuntu6.1_amd64.deb
dpkg-deb -x ia32-libs_2.7ubuntu6.1_amd64.deb ia32-libs
sudo cp ia32-libs/usr/lib32/libstdc++.so.5.0.7 /usr/lib32/
cd /usr/lib32
sudo ln -s libstdc++.so.5.0.7 libstdc++.so.5
This immediately took care of the problem for me.
Leave a Reply