Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x/sys/unix: SYS_CLOCK_GETTIME undefined on darwin/amd64 with Go 1.11 #31203

Closed
gleichda opened this issue Apr 2, 2019 · 4 comments
Closed

x/sys/unix: SYS_CLOCK_GETTIME undefined on darwin/amd64 with Go 1.11 #31203

gleichda opened this issue Apr 2, 2019 · 4 comments

Comments

@gleichda
Copy link

gleichda commented Apr 2, 2019

What version of Go are you using (go version)?

$ go version
go version go1.11.6 darwin/amd64

Does this issue reproduce with the latest release?

Yes its new in the latest release of golang.org/x/sys

What operating system and processor architecture are you using (go env)?

go env Output
$ go env
GOARCH="amd64"
GOBIN=""
GOCACHE="/Users/gleichd/Library/Caches/go-build"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GOOS="darwin"
GOPATH="/Users/gleichd/go"
GOPROXY=""
GORACE=""
GOROOT="/usr/local/Cellar/go@1.11/1.11.6/libexec"
GOTMPDIR=""
GOTOOLDIR="/usr/local/Cellar/go@1.11/1.11.6/libexec/pkg/tool/darwin_amd64"
GCCGO="gccgo"
CC="clang"
CXX="clang++"
CGO_ENABLED="1"
GOMOD=""
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/bs/n6sgl2cs1nn4wn__fcy9t4q80000gn/T/go-build282528659=/tmp/go-build -gno-record-gcc-switches -fno-common"

What did you do?

Trying to run a programm including https://github.com/sirupsen/logrus

What did you expect to see?

The program works

What did you see instead?

With the latest release of golang.org/x/sys/unix I'm getting an error:
`$ go run src/main/main.go

golang.org/x/sys/unix

../../../golang.org/x/sys/unix/zsyscall_darwin_amd64.1_11.go:687:22: undefined: SYS_CLOCK_GETTIME`

Checking out the previous commit (9eb1bfa) of golang.org/x/sys/ makes it work again

@AlexRouSg
Copy link
Contributor

AlexRouSg commented Apr 2, 2019

https://go-review.googlesource.com/c/sys/+/170297/ added some code that mistakenly reference it and will be removed in https://go-review.googlesource.com/c/sys/+/170299

@ikhsanfaruqi
Copy link

get same err

@kashifmin
Copy link

Getting the same error here. Waiting for the fix to be merged. 🤘🏻

@gopherbot
Copy link

Change https://golang.org/cl/170299 mentions this issue: unix: remove ClockGettime for darwin/amd64 on Go 1.11

@tklauser tklauser changed the title undefined: SYS_CLOCK_GETTIME for golang.org/x/sys/unix x/sys/unix: SYS_CLOCK_GETTIME undefined on darwin/amd64 with Go 1.11 Apr 2, 2019
@gopherbot gopherbot added this to the Unreleased milestone Apr 2, 2019
@golang golang locked and limited conversation to collaborators Apr 1, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

6 participants