I need to convert times from UTC to a timezone selected by the user. I also have to convert from user input in that time zone to store in UTC.
Currently timezones are defined in Olson format ("America/Los Angeles").
A solution was easy on Linux with gmtime, but I can not find a cross platform solution (or any solution) that does the exact same thing on Windows.
I can not use Boost.Date_Time (http://ift.tt/10TwYGs) because it does not support historical timezone changes such as varying DST periods over the years. Someone apparently submitted a patch years ago but it does not appear to have been accepted.
The only other solution that seems plausible is to use data and code from: http://ift.tt/11IzbG0
Has anyone tried this, or do you have a better idea?
Aucun commentaire:
Enregistrer un commentaire