travis: merge Linux and OS X install scripts

This way we can provide scalability for more OS variations and
avoid code duplication.
Merge pull request #174 from toxeus/develop

travis: merge Linux and OS X install scripts