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: PR_SET_PTRACER_ANY missing for linux_arm conditional compilation #16682

Closed
nvanbenschoten opened this issue Aug 12, 2016 · 2 comments

Comments

@nvanbenschoten
Copy link
Contributor

The PR_SET_PTRACER_ANY system error number is missing from the // +build arm,linux version of zerror_${GOOS}_${GOARCH}.go, but is available for all other linux builds. This results in the compilation of code like https://github.com/backtrace-labs/go-bcd/blob/master/bcd_sys_linux.go to fail on 32-bit arm architectures.

I haven't been able to find any reason why this flag would be missing, so I'm curious if the correct approach would be to add something like:

#ifndef PR_SET_PTRACER_ANY
#define PR_SET_PTRACER_ANY  -0x1
#endif

directly after the other default error codes in the mkerrors.sh generation script.

@quentinmit quentinmit changed the title sys/unix: PR_SET_PTRACER_ANY missing for linux_arm conditional compilation x/sys/unix: PR_SET_PTRACER_ANY missing for linux_arm conditional compilation Aug 26, 2016
@quentinmit quentinmit added this to the Unreleased milestone Aug 26, 2016
@tklauser
Copy link
Member

tklauser commented Jun 7, 2017

This should be fixed by golang/sys@ea9bcad.

@ianlancetaylor
Copy link
Contributor

Yes, fixed by https://golang.org/cl/37943. Thanks for pointing that out.

@golang golang locked and limited conversation to collaborators Jun 7, 2018
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

5 participants