add workaround for OSX's lack of clock_gettime (grrrrr)