-
-
Notifications
You must be signed in to change notification settings - Fork 31.9k
gh-129296: Fix pyatomic.h
include paths
#129320
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
Conversation
I'm unsure if this is worth backporting to 3.13 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
I will tentatively label this as "needs backport to 3.13", but will wait for feedback from @Yhg1s. |
This comment was marked as off-topic.
This comment was marked as off-topic.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Would you mind to update also |
Thanks for updating Include/cpython/pythread.h. I enabled automerge. |
I don't think that it's worth it to backport this change to 3.12 and 3.13. It's nice to have in the main branch, but it doesn't fix a build error, since it's not needed to backport it. |
I've actually been seeing this error when running
It's fairly annoying to have to either:
I would really appreciate if there was either a good workaround, or this was back ported to 3.12 and 3.13. |
Use relative includes in Include/cpython/pyatomic.h for pyatomic_gcc.h, pyatomic_std.h and pyatomic_msc.h. Do a similar change in Include/cpython/pythread.h for pthread_stubs.h include. (cherry picked from commit 3a974e3) Co-authored-by: Zanie Blue <[email protected]>
GH-130667 is a backport of this pull request to the 3.13 branch. |
Sorry, @zanieb and @vstinner, I could not cleanly backport this to
|
GH-130668 is a backport of this pull request to the 3.12 branch. |
Ah. When #129296 was reported, it wasn't clear if it was a compiler error. If you're unable to build Python, I'm ok to backport the changes to 3.12 and 3.13. Note that Python 3.12 only needs the pythread.h change (pyatomic.h doesn't exist in Python 3.12). |
gh-129296: Fix `pythread.h` include paths (#129320) Use relative includes in Include/cpython/pythread.h for pthread_stubs.h. (cherry picked from commit 3a974e3) Co-authored-by: Zanie Blue <[email protected]>
gh-129296: Fix `pyatomic.h` include paths (GH-129320) Use relative includes in Include/cpython/pyatomic.h for pyatomic_gcc.h, pyatomic_std.h and pyatomic_msc.h. Do a similar change in Include/cpython/pythread.h for pthread_stubs.h include. (cherry picked from commit 3a974e3) Co-authored-by: Zanie Blue <[email protected]>
As reported in the issue, these paths are relative to the base include directory instead of the header file. While this is fine in practice because the compiler falls back to the base include directory, it doesn't match the style of other includes in the project.
Originally added in