<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hello,<div><br></div><div>We utilize the C# library,&nbsp;<a href="http://zoneinfo.codeplex.com/Thread/View.aspx?ThreadId=50756">http://zoneinfo.codeplex.com/Thread/View.aspx?ThreadId=50756</a></div><div><br></div><div>This Loads the library into the application's cache as a global static variable and gives you direct access to zone conversions using the utc time and a zone name.</div><div><br></div><div>There are other solutions similar to this avaialble; but, I'm not sure from a C or C++ perspective.</div><div><br></div><div>Hope this helps</div><div><br></div><div><div>
<span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Arial; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Arial; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Arial; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><div>-Isaac</div><div><div apple-content-edited="true"><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Arial; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Arial; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Arial; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Arial; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Arial; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Arial; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Arial; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Arial; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Arial; font-size: 11px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><br></div><div><br></div><div>Iformata Communications LLC</div><div><div>130 West Second St, Suite 1111,&nbsp;</div><div>Dayton, Ohio 45402</div><div>Main: +1-937-832-6900</div><div>Direct: +1-937-832-6961</div><div><br></div></div><div><div><b><span class="Apple-style-span" style="font-weight: normal; font-family: Helvetica; font-size: 12px; "><div style="margin-top: 0in; margin-right: 0in; margin-left: 0in; margin-bottom: 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><span style="font-size: 8pt; font-family: Verdana, sans-serif; color: green; ">Please consider the environment before printing.</span><span style="color: rgb(31, 73, 125); "><o:p></o:p></span></div><div style="margin-top: 0in; margin-right: 0in; margin-left: 0in; margin-bottom: 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><i><span style="font-size: 5pt; font-family: Arial, sans-serif; color: red; "><o:p>&nbsp;</o:p></span></i></div><div style="margin-top: 0in; margin-right: 0in; margin-left: 0in; margin-bottom: 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><i><span style="font-size: 8pt; font-family: Arial, sans-serif; color: gray; ">This communication (including any attachments) may contain privileged or confidential information of Iformata LLC and is intended for a specific individual.&nbsp; If you are not the intended recipient, you should delete this communication, including any attachments without reading or saving them in any manner, and you are hereby notified that any disclosure, copying, or distribution of this communication, or the taking of any action based on it, is strictly prohibited; if you received this in error please notify me immediately by replying to this message stating you received it in error.</span></i><span style="font-size: 10pt; font-family: Helvetica, sans-serif; color: rgb(255, 255, 204); "><o:p></o:p></span></div><div style="margin-top: 0in; margin-right: 0in; margin-left: 0in; margin-bottom: 0.0001pt; font-size: 11pt; font-family: Calibri, sans-serif; "><o:p>&nbsp;</o:p></div></span></b></div></div></div></span></div></span><br class="Apple-interchange-newline"></span><br class="Apple-interchange-newline"></div></span></div></span></div></span></div></span></div></span></div></span></div></div></div></div></span></div></span></span>
</div>
<br><div><div>On Feb 9, 2011, at 11:23 AM, Olson, Arthur David (NIH/NCI) [E] wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div>I'm forwarding this message from Dario Teixeira, who is not on the time zone mailing list. Those of you who are on the list, please direct replies appropriately.<br><br><span class="Apple-tab-span" style="white-space:pre">        </span><span class="Apple-tab-span" style="white-space:pre">        </span><span class="Apple-tab-span" style="white-space:pre">        </span><span class="Apple-tab-span" style="white-space:pre">        </span>--ado<br><br>-----Original Message-----<br>From: Dario Teixeira [mailto:darioteixeira@yahoo.com] <br>Sent: Wednesday, February 09, 2011 11:03<br>To: <a href="mailto:tz@lecserver.nci.nih.gov">tz@lecserver.nci.nih.gov</a><br>Subject: C/C++ library that parses TZ data?<br><br>Hi,<br><br>I have a problem which is fairly common when one is running a web application<br>that wishes to display timestamps localised towards each user's time zone.<br>Basically, I need a function that takes as input a timestamp in UTC and <br>a time zone specified in the Zoneinfo convention (ex: "Europe/Lisbon"),<br>and returns the localised version of that timestamp, including a time zone<br>abbreviation aware of daylight savings. &nbsp;Example:<br><br>2010-01-01 15:30, "Europe/Lisbon" &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&gt; 2010-01-01 15:30 WET<br>2010-01-01 15:30, "Europe/Paris" &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&gt; 2010-01-01 16:30 CET<br><br>2010-07-01 15:30, "Europe/Lisbon" &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&gt; 2010-07-01 16:30 WEST<br>2010-07-01 15:30, "Europe/Paris" &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-&gt; 2010-07-01 17:30 CEST<br><br>Since the zoneinfo data is present in every Unix system and glibc includes<br>routines for parsing it, interfacing with glibc seemed the obvious solution.<br>Unfortunately, glibc was not designed with this use case in mind. &nbsp;In fact,<br>the glibc interface to zoneinfo can be described as "sui generis" if one<br>is feeling charitable, or "insane" if truth must be told. &nbsp;Specifically, to<br>obtain the localised version of a given timestamp, one must first set the 'TZ'<br>environment variable with the target timezone, and then invoke 'localtime'.<br>The abbreviated name of the timezone can be found in the global 'tzname'<br>array: at position 'tzname[0]' if daylight savings are not in effect and at<br>position 'tzname[1]' if they are. &nbsp;A quick search through glibc's bugzilla<br>shows I'm not the only one to find this interface anachronistic [1], but it<br>also reveals that it is unlikely to change.<br><br>So, my question is if someone is aware of some alternative library in C <br>or C++ that provides this same functionality, but is friendlier towards<br>concurrent applications.<br><br>Best regards,<br>Dario Teixeira<br><br>[1] <a href="http://sources.redhat.com/bugzilla/show_bug.cgi?id=11620">http://sources.redhat.com/bugzilla/show_bug.cgi?id=11620</a><br><br><br><br><br><br><br></div></blockquote></div><br></div></body></html>