-
Notifications
You must be signed in to change notification settings - Fork 18.5k
Description
Hi. I was building internals of linkerd and caught a bug, during the build phase, for a protobuf/grpc related package.
What version of Go are you using (go version)?
$ go version
go version go1.15rc2 gollvm LLVM 12.0.0git linux/amd64
Does this issue reproduce with the latest release?
What operating system and processor architecture are you using (go env)?
go env Output
$ go env
GO111MODULE=""
GOARCH="amd64"
GOBIN=""
GOCACHE="/home/oceanfish81/.cache/go-build"
GOENV="/home/oceanfish81/.config/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOINSECURE=""
GOMODCACHE="/home/oceanfish81/go/pkg/mod"
GONOPROXY=""
GONOSUMDB=""
GOOS="linux"
GOPATH="/home/oceanfish81/go"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/local"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/local/tools"
GCCGO="/usr/local/bin/llvm-goc"
AR="ar"
CC="/usr/bin/clang"
CXX="/usr/bin/clang++"
CGO_ENABLED="1"
GOMOD="/home/oceanfish81/linkerd2/go.mod"
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=/tmp/go-build000799681=/tmp/go-build -gno-record-gcc-switches -funwind-tables"
What did you do?
~/linkerd2/pkg/tap$ go build
What did you expect to see?
Required sources should be pulled and all packages should be compiled, using llvm-goc, as expected.
What did you see instead?
go: downloading github.com/sirupsen/logrus v1.6.0
go: downloading k8s.io/apimachinery v0.17.4
go: downloading k8s.io/client-go v0.17.4
go: downloading github.com/servicemeshinterface/smi-sdk-go v0.3.0
go: downloading k8s.io/kube-aggregator v0.17.4
go: downloading github.com/prometheus/client_golang v1.2.1
go: downloading k8s.io/api v0.17.4
go: downloading github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4
go: downloading github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0
go: downloading k8s.io/apiextensions-apiserver v0.17.4
go: downloading github.com/prometheus/procfs v0.0.5
go: downloading github.com/prometheus/common v0.7.0
go: downloading github.com/Azure/go-autorest/autorest v0.9.0
go: downloading k8s.io/utils v0.0.0-20191114184206-e782cd3c129f
go: downloading github.com/gogo/protobuf v1.3.0
go: downloading github.com/googleapis/gnostic v0.3.1
go: downloading github.com/Azure/go-autorest/tracing v0.5.0
go: downloading github.com/Azure/go-autorest/logger v0.1.0
go: downloading github.com/gophercloud/gophercloud v0.1.0
go: downloading github.com/docker/spdystream v0.0.0-20160310174837-449fdfce4d96
go: downloading github.com/Azure/go-autorest/autorest/adal v0.5.0
go: downloading k8s.io/kube-openapi v0.0.0-20191107075043-30be4d16710a
go: downloading github.com/Azure/go-autorest/autorest/date v0.1.0
go: downloading github.com/evanphx/json-patch v4.5.0+incompatible
go: downloading github.com/cespare/xxhash v1.1.0
go: downloading github.com/cespare/xxhash/v2 v2.1.0
go: downloading github.com/dgrijalva/jwt-go v3.2.0+incompatible
go: downloading github.com/json-iterator/go v1.1.8
go: downloading github.com/pkg/errors v0.9.1google.golang.org/grpc/internal/syscall
../../../go/pkg/mod/google.golang.org/grpc@v1.29.1/internal/syscall/syscall_linux.go:50:28: error: reference to undefined identifier 'syscall.RUSAGE_SELF'
It seems that an error is related to func GetRusage() (rusage *Rusage) .
Ivan