Support multiarch names.

- follows the FHS compliant
- getLookupPrefixes improvement

Related to #329