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

Compilation error with ARM processor (reoccurance) #39263

Closed
Martin555 opened this issue May 26, 2020 · 5 comments
Closed

Compilation error with ARM processor (reoccurance) #39263

Martin555 opened this issue May 26, 2020 · 5 comments

Comments

@Martin555
Copy link

@Martin555 Martin555 commented May 26, 2020

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

$ go version
go version go1.14.2 linux/arm

# Also tried with 1.11, 1.12 and 1.13

Does this issue reproduce with the latest release?

Not sure, 1.14.3 is not available for arm yet.

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

go env Output
$ go env
GO111MODULE=""
GOARCH="arm"
GOBIN=""
GOCACHE="/root/.cache/go-build"
GOENV="/root/.config/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="arm"
GOHOSTOS="linux"
GOINSECURE=""
GONOPROXY=""
GONOSUMDB=""
GOOS="linux"
GOPATH="/root/go"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/lib/go-1.14"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/lib/go-1.14/pkg/tool/linux_arm"
GCCGO="gccgo"
GOARM="6"
AR="ar"
CC="gcc"
CXX="g++"
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 -marm -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build692618928=/tmp/go-build -gno-record-gcc-switches"

What did you do?

go build on https://github.com/dwoja22/ffmpeg-webrtc
-> Works flawlessly on Ubuntu amd64

What did you expect to see?

Compilation

What did you see instead?

[22:13 martin@orangepizero ffmpeg-webrtc]$ go build
# golang.org/x/sys/unix
../pkg/mod/golang.org/x/sys@v0.0.0-20191206220618-eeba5f6aabab/unix/zptrace_armnn_linux.go:45:57: cannot use uint64(unsafe.Sizeof(*regsout)) (type uint64) as type uint32 in field value
../pkg/mod/golang.org/x/sys@v0.0.0-20191206220618-eeba5f6aabab/unix/zptrace_armnn_linux.go:51:54: cannot use uint64(unsafe.Sizeof(*regs)) (type uint64) as type uint32 in field value

The same problem has been reported in issue #36032, which has been closed by gopherbot.

@randall77
Copy link
Contributor

@randall77 randall77 commented May 26, 2020

Those line numbers look like they don't correspond to tip. Could you retry with the latest x/sys?

@ianlancetaylor
Copy link
Contributor

@ianlancetaylor ianlancetaylor commented May 26, 2020

Yes, this was fixed by https://golang.org/cl/210322. You need to update your sources.

@Martin555
Copy link
Author

@Martin555 Martin555 commented May 27, 2020

@ianlancetaylor which sources are you referring to and how can I update them? The mentioned fix was merged in December 2019 and the installed go1.14.2 was released on 2020/04/08.

Thank you.

@ianlancetaylor
Copy link
Contributor

@ianlancetaylor ianlancetaylor commented May 27, 2020

Sorry, I was referring to the golang.org/x/sys sources. You need a newer version of the golang.org/x/sys/unix package.

@Martin555
Copy link
Author

@Martin555 Martin555 commented May 27, 2020

@ianlancetaylor thank you very much! Now it compiles flawlessly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants
You can’t perform that action at this time.