use strftime instead of put_time since gcc 4.9 does not implement it yet