This had me stumped for a bit, so I've written it down. If you have a 64 bit version of Ubuntu and want to install a 32-bit package, you simply add :i386 to the end of the package name like this:
$ sudo apt-get install libstdc++6:i386
However, this didn't initially work for me as apt-get couldn't find the package:
$ sudo apt-get install libstdc++6:i386 Reading package lists... Done Building dependency tree Reading state information... Done E: Unable to locate package libstdc++6 E: Couldn't find any package by regex 'libstdc++6'
It turned out that my installation only had the 64 bit architecture configured which you can tell by running:
$ sudo dpkg --print-architecture amd64 $ sudo dpkg --print-foreign-architectures
Note that there are no foreign architectures, which is the problem.
The solution is to add the i386 architecture first:
$ sudo dpkg --add-architecture i386 $ sudo dpkg --print-foreign-architectures i386
That's better! Now we need to run an update:
$ sudo apt-get update
Don't forget this update! I did and wondered why I still had the problem…
Now the installation of the 32-bit package works: