<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">Hm, good question - we do have our ‘bootstrap’ directory which includes some time zone headers, but those are the ones from unicode and not tzfile.h.<div class=""><br class=""></div><div class="">- Tony<br class=""><div><br class=""><blockquote type="cite" class=""><div class="">On Jul 6, 2017, at 11:42 AM, Alex Blewitt &lt;<a href="mailto:alblue@apple.com" class="">alblue@apple.com</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html; charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">It looks like it's /usr/share/zoneinfo on all Ubuntu versions:<div class=""><br class=""></div><div class=""><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgb(255, 255, 255);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">alblue.local[~]$ docker run -it --rm ubuntu:14.04 find /usr -name zone.tab</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgb(255, 255, 255);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">/usr/share/zoneinfo/zone.tab</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgb(255, 255, 255);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">alblue.local[~]$ docker run -it --rm ubuntu:16.04 find /usr -name zone.tab</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgb(255, 255, 255);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">/usr/share/zoneinfo/zone.tab</span></div><div class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgb(255, 255, 255);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">alblue.local[~]$ docker run -it --rm ubuntu:16.10 find /usr -name zone.tab</span></div><div style="margin: 0px; font-stretch: normal; font-size: 11px; line-height: normal; font-family: Menlo; background-color: rgb(255, 255, 255);" class=""><span style="font-variant-ligatures: no-common-ligatures" class="">/usr/share/zoneinfo/zone.tab</span></div><div class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><br class=""></span></div><div class=""><span style="font-variant-ligatures: no-common-ligatures" class="">This is the same that's coming from CFTimeZone.c:</span></div><div class=""><span style="font-variant-ligatures: no-common-ligatures" class=""><br class=""></span></div></span></div><div class=""><a href="https://github.com/apple/swift-corelibs-foundation/blob/2611dcd0d9b91fecace537838294bd85f0220503/CoreFoundation/NumberDate.subproj/CFTimeZone.c#L36-L39" class="">https://github.com/apple/swift-corelibs-foundation/blob/2611dcd0d9b91fecace537838294bd85f0220503/CoreFoundation/NumberDate.subproj/CFTimeZone.c#L36-L39</a></div><div class=""><br class=""></div><div class="">Is it possible that the MacOS header is being included and defining TZDIR before the CFTimeZone.c file is compiled?</div><div class=""><br class=""></div><div class="">Alex</div><div class=""><br class=""><blockquote type="cite" class=""><div class="">On 6 Jul 2017, at 19:22, Tony Parker via swift-corelibs-dev &lt;<a href="mailto:swift-corelibs-dev@swift.org" class="">swift-corelibs-dev@swift.org</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><meta http-equiv="Content-Type" content="text/html charset=utf-8" class=""><div style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">Is the path to zoneinfo different on the Ubuntu docker image?<div class=""><br class=""></div><div class="">- Tony<br class=""><div class=""><br class=""><blockquote type="cite" class=""><div class="">On Jul 6, 2017, at 9:36 AM, Youming Lin &lt;<a href="mailto:ylin@us.ibm.com" class="">ylin@us.ibm.com</a>&gt; wrote:</div><br class="Apple-interchange-newline"><div class=""><div class=""><p class=""><font size="2" class="">We were seeing this on Travis too. Specifically, on a Travis matrix build using Swift 3.1.1 on a Ubuntu 16.04 docker image running inside a Travis 14.04 VM.<br class=""><br class="">The issue was specific to the Ubuntu 16.04 docker image; when I tested in Ubuntu 16.04 OS as a guest VM, the issue went away.<br class=""></font><br class=""><font size="2" class="">Thanks,<br class=""><br class="">Youming Lin<br class="">IBM Cloud, Swift@IBM, Kitura developer<br class="">Austin, TX<br class="">GitHub: @youming-lin</font><br class=""><br class=""><span id="cid:1__=8FBB0BC6DFC928908f9e8a93df938690918c8FB@" class="">&lt;graycol.gif&gt;</span><font size="2" color="#424282" class="">Tony Parker via swift-corelibs-dev ---07/06/2017 10:31:15 AM---Yes, we’re discussing this one internally too and trying to figure out what the right answer is. May</font><br class=""><br class=""><font size="2" color="#5F5F5F" class="">From:        </font><font size="2" class="">Tony Parker via swift-corelibs-dev &lt;<a href="mailto:swift-corelibs-dev@swift.org" class="">swift-corelibs-dev@swift.org</a>&gt;</font><br class=""><font size="2" color="#5F5F5F" class="">To:        </font><font size="2" class="">Ian Partridge &lt;<a href="mailto:ian@poncho.org.uk" class="">ian@poncho.org.uk</a>&gt;</font><br class=""><font size="2" color="#5F5F5F" class="">Cc:        </font><font size="2" class="">swift-corelibs-dev &lt;<a href="mailto:swift-corelibs-dev@swift.org" class="">swift-corelibs-dev@swift.org</a>&gt;</font><br class=""><font size="2" color="#5F5F5F" class="">Date:        </font><font size="2" class="">07/06/2017 10:31 AM</font><br class=""><font size="2" color="#5F5F5F" class="">Subject:        </font><font size="2" class="">Re: [swift-corelibs-dev] TimeZone database</font><br class=""><font size="2" color="#5F5F5F" class="">Sent by:        </font><font size="2" class=""><a href="mailto:swift-corelibs-dev-bounces@swift.org" class="">swift-corelibs-dev-bounces@swift.org</a></font><br class=""></p><hr width="100%" size="2" align="left" noshade="" style="color:#8091A5; " class=""><br class=""><br class=""><br class="">Yes, we’re discussing this one internally too and trying to figure out what the right answer is. Maybe the best solution for now is to find a good mechanism to check the underlying version of the OS and split it out into a function as you suggest.<br class=""><br class="">- Tony<br class="">
<ul class=""><ul class="">On Jul 6, 2017, at 7:37 AM, Ian Partridge via swift-corelibs-dev &lt;<a href="mailto:swift-corelibs-dev@swift.org" class=""><u class=""><font color="#0000FF" class="">swift-corelibs-dev@swift.org</font></u></a>&gt; wrote:<br class=""><br class=""><font size="2" face="Helvetica" class="">Good shout Simon, you are right.  I'm on Sierra.  Compare and contrast:</font><br class=""><font size="2" face="Helvetica" class=""><br class="">/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/tzfile.h<br class="">#define TZDIR   "/usr/share/zoneinfo"</font><br class=""><font size="2" face="Helvetica" class=""><br class="">/Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/usr/include/tzfile.h<br class="">#define TZDIR   "/var/db/timezone/zoneinfo"</font><br class=""><font size="2" face="Helvetica" class=""><br class="">so I guess if I installed the High Sierra beta it would work OK.</font><br class=""><font size="2" face="Helvetica" class=""><br class="">I hacked CF to force it to use /usr/share/zoneinfo and TestFoundation<br class="">is much happier, but that's not a solution.</font><br class=""><font size="2" face="Helvetica" class=""><br class="">On 6 July 2017 at 15:20, Simon Evans &lt;</font><a href="mailto:si@si.org" class=""><u class=""><font size="2" color="#0000FF" face="Helvetica" class="">si@si.org</font></u></a><font size="2" face="Helvetica" class="">&gt; wrote:</font><ul class=""><ul class=""><font size="2" face="Helvetica" class="">Ian<br class=""><br class="">I also saw this error, I think its because the TZDIR is different in the headers shipped with Xcode 9. Maybe the location of the timezone directory was moved between Sierra and High Sierra. What version of macOS are you testing on?<br class=""><br class="">If it has indeed moved between 10.12 and 10.13 it may require a runtime version check to dynamically return TZDIR.<br class=""><br class="">Simon<br class=""><br class=""></font><ul class=""><ul class=""><font size="2" face="Helvetica" class="">On 6 Jul 2017, at 15:09, Ian Partridge via swift-corelibs-dev &lt;</font><a href="mailto:swift-corelibs-dev@swift.org" class=""><u class=""><font size="2" color="#0000FF" face="Helvetica" class="">swift-corelibs-dev@swift.org</font></u></a><font size="2" face="Helvetica" class="">&gt; wrote:<br class=""><br class="">Hi,<br class=""><br class="">I'm seeing quite a lot of tests failing when running the<br class="">TestFoundation target in Xcode.  The failures are timezone related.<br class="">Most simply, the code<br class=""><br class="">let timeZone = TimeZone(abbreviation: "GMT")<br class=""><br class="">is returning nil.<br class=""><br class="">Walking through the CF code which sets things up, it seems to be<br class="">trying to read the timezone database from<br class="">/var/db/timezone/zoneinfo/zone.tab which doesn't exist on my macOS<br class="">system.<br class=""><br class="">/usr/share/zoneinfo/zone.tab is there and seems to be the right<br class="">location (?), but CF is picking up TZDIR from tzfile.h which says:<br class=""><br class="">#define TZDIR   "/var/db/timezone/zoneinfo"<br class=""><br class="">Any thoughts?  I feel like I'm missing something obvious and have gone<br class="">too far down the rabbit hole.<br class=""><br class="">--<br class="">Ian Partridge<br class="">_______________________________________________<br class="">swift-corelibs-dev mailing list</font><u class=""><font size="2" color="#0000FF" face="Helvetica" class=""><br class=""></font></u><a href="mailto:swift-corelibs-dev@swift.org" class=""><u class=""><font size="2" color="#0000FF" face="Helvetica" class="">swift-corelibs-dev@swift.org</font></u></a><font size="2" face="Helvetica" class=""><br class=""></font><font size="2" face="Helvetica" class=""><a href="https://lists.swift.org/mailman/listinfo/swift-corelibs-dev" class="">https://lists.swift.org/mailman/listinfo/swift-corelibs-dev</a></font></ul></ul></ul></ul><br class=""><br class=""><font size="2" face="Helvetica" class=""><br class="">-- <br class="">Ian Partridge<br class="">_______________________________________________<br class="">swift-corelibs-dev mailing list</font><u class=""><font size="2" color="#0000FF" face="Helvetica" class=""><br class=""></font></u><a href="mailto:swift-corelibs-dev@swift.org" class=""><u class=""><font size="2" color="#0000FF" face="Helvetica" class="">swift-corelibs-dev@swift.org</font></u></a><u class=""><font size="2" color="#0000FF" face="Helvetica" class=""><br class=""></font></u><a href="https://lists.swift.org/mailman/listinfo/swift-corelibs-dev" class=""><u class=""><font size="2" color="#0000FF" face="Helvetica" class="">https://lists.swift.org/mailman/listinfo/swift-corelibs-dev</font></u></a></ul></ul><tt class=""><font size="2" class="">_______________________________________________<br class="">swift-corelibs-dev mailing list<br class=""><a href="mailto:swift-corelibs-dev@swift.org" class="">swift-corelibs-dev@swift.org</a><br class=""></font></tt><tt class=""><font size="2" class=""><a href="https://lists.swift.org/mailman/listinfo/swift-corelibs-dev" class="">https://lists.swift.org/mailman/listinfo/swift-corelibs-dev</a></font></tt><tt class=""><font size="2" class=""><br class=""></font></tt><br class=""><br class=""><br class="">
</div>
</div></blockquote></div><br class=""></div></div>_______________________________________________<br class="">swift-corelibs-dev mailing list<br class=""><a href="mailto:swift-corelibs-dev@swift.org" class="">swift-corelibs-dev@swift.org</a><br class=""><a href="https://lists.swift.org/mailman/listinfo/swift-corelibs-dev" class="">https://lists.swift.org/mailman/listinfo/swift-corelibs-dev</a><br class=""></div></blockquote></div><br class=""></div></div></div></blockquote></div><br class=""></div></body></html>