Adapt to multiple OS versions

On Trusty, the default Python 3.x is now 3.4.0.