]> Cypherpunks repositories - gostls13.git/commitdiff
time: look for zoneinfo.zip in GOROOT
authorElias Naur <mail@eliasnaur.com>
Tue, 30 Apr 2019 18:36:20 +0000 (20:36 +0200)
committerElias Naur <mail@eliasnaur.com>
Tue, 30 Apr 2019 19:13:43 +0000 (19:13 +0000)
The zoneinfo.zip file will be in the $GOROOT in self-hsoted builds
on iOS.

Updates #31722

Change-Id: I991fae92e3dc50581b099a2d8901aed36ecc7cef
Reviewed-on: https://go-review.googlesource.com/c/go/+/174310
Run-TryBot: Elias Naur <mail@eliasnaur.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
src/time/zoneinfo_ios.go

index 6d7f975a11443060b6f83ea99afce81fd76c6d29..09383a5b30f0f3bccefbe53779c59c56650a700e 100644 (file)
@@ -7,10 +7,14 @@
 
 package time
 
-import "syscall"
+import (
+       "runtime"
+       "syscall"
+)
 
 var zoneSources = []string{
        getZipParent() + "/zoneinfo.zip",
+       runtime.GOROOT() + "/lib/time/zoneinfo.zip",
 }
 
 func getZipParent() string {