Updates for 3.1 + travis-ci

I collected fixes in other forks and added travis-ci build.

There seems to be an issue with system not set to eastern time :

https://travis-ci.org/hooktstudios/trackoid/builds/6805809