wayneeseguin/rvm — pull request #1727 by theschoolmaster (2013-03-26 22:55:28+00:00)
Title: debian/ubuntu multiarch dependency checking.  fixes #1726

Currently RVM uses "dpkg -s" to check if a required library is installed. When using multiarch, this simple check will fail when you have multiple arch versions of a package installed.

In my case it was zlib1g.

# dpkg -s zlib1g
dpkg-query: error: --status needs a valid package name but 'zlib1g' is not: ambiguous package name 'zlib1g' with more than one installed instance

In order for dpkg -s to report correctly, the machine arch needs to be appended.

# dpkg -s zlib1g:amd64
Package: zlib1g
Status: install ok installed
.... etc

# dpkg -s zlib1g:i386
Package: zlib1g
Status: install ok installed
.... etc