Fix amalgamated build. It seems to susceptible to inclusion order.
For Travis CI - switch CI build to use OS X build environment.