Linux – How to add repositories to ia32-apt-get

64-bitaptlinuxUbuntu

I need to install a few third-party binary packages that are only available in the i386 architecture on 64-bit (amd64) Ubuntu. How do I add the new 32-bit repository so ia32-apt-get will automatically install and convert the i386-only binary packages and their dependencies?

Best Answer

Unfortunately you can't install an i386 package on an AMD64 machine; dpkg just won't let you. You can do a couple of things to get around this. Probably the easiest is to set up an i386 chroot using debootstrap:

# /usr/sbin/debootstrap --arch i386 jaunty /mnt/ubuntu http://archive.ubuntu.com/ubuntu

You can then chroot into /mnt/ubuntu and install your packages.