Better platform detection

These changes are reflected in:

https://github.com/npm/npme-ansible-module/pull/7