FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-99337: Fix compile errors with gcc 12 on macOS by ronaldoussoren · Pull Request #99470 · python/cpython · GitHub

/ cpython Public

gh-99337: Fix compile errors with gcc 12 on macOS - #99470

Merged
ronaldoussoren merged 6 commits into
python:mainfrom
ronaldoussoren:gh-99337
Nov 21, 2022
Merged

gh-99337: Fix compile errors with gcc 12 on macOS#99470
ronaldoussoren merged 6 commits into
python:mainfrom
ronaldoussoren:gh-99337

Conversation

ronaldoussoren commented Nov 14, 2022
edited by bedevere-bot
Loading

Copy link
Copy Markdown
Contributor

When compiling with GCC 12 on a macOS 12 system I get three groups of errors:

  1. In pylifecycle.c the compile rejects _Pragma within a declaration
  2. posixmodule.c was missing a number of ..._RUNTIME macros for non-clang on macOS
  3. _ctypes assumed that __builtin_available is always present on macOS

ronaldoussoren self-assigned this Nov 15, 2022
ronaldoussoren marked this pull request as ready for review November 15, 2022 08:41
Comment thread Modules/_ctypes/malloc_closure.c Outdated
Comment thread Python/pylifecycle.c
The new form matches the way we test for other weak
symbols (for example in posixmodule.c)
I earlier moved the pragma, but not the comment that explains
why it is necessary.

vstinner left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

LGTM.

Oh ok, now with the fixed test if (ffi_closure_free != NULL) {, I get it :-)

Copy link
Copy Markdown
Contributor

Thanks @ronaldoussoren for the PR 🌮🎉.. I'm working now to backport this PR to: 3.10, 3.11.
🐍🍒⛏🤖

Copy link
Copy Markdown
Contributor

Sorry, @ronaldoussoren, I could not cleanly backport this to 3.10 due to a conflict.
Please backport using cherry_picker on command line.
cherry_picker cdde29dde90947df9bac39c1d19479914fb3db09 3.10

Copy link
Copy Markdown

GH-99638 is a backport of this pull request to the 3.11 branch.

bedevere-bot removed the needs backport to 3.11 only security fixes label Nov 21, 2022
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Nov 21, 2022
Fix a number of compile errors with GCC-12 on macOS:

1. In pylifecycle.c the compile rejects _Pragma within a declaration
2. posixmodule.c was missing a number of ..._RUNTIME macros for non-clang on macOS
3. _ctypes assumed that __builtin_available is always present on macOS
(cherry picked from commit cdde29d)

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
ronaldoussoren added a commit that referenced this pull request Nov 21, 2022
…99638)

gh-99337: Fix compile errors with gcc 12 on macOS (GH-99470)

Fix a number of compile errors with GCC-12 on macOS:

1. In pylifecycle.c the compile rejects _Pragma within a declaration
2. posixmodule.c was missing a number of ..._RUNTIME macros for non-clang on macOS
3. _ctypes assumed that __builtin_available is always present on macOS
(cherry picked from commit cdde29d)

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
ZeroIntensity removed the needs backport to 3.10 only security fixes label Feb 17, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants


Back | FazBrowse Home | New Git URL