fix for mult-arch enabled systems

this does not work for systems that are not multi-arch aware, just tested on a Debian Squeeze install, dpkg-query doesn't recognize 'binary:Package' so a test is needed to see if 'dpkg --print-foreign-architecture' is successful, retval 0

Debian has added multi-arch support so you can install packages for other
architectures, and when enabled, packages are differentiated by
'packagename:arch'

The dpkg-query format string '${Package}' displays a short-name, where
'${binary:Package}' displays the architecture 'tag'