Repository navigation
Prevent segfaults by adding macOS weaklinking for mkfifoat and mknodat system calls added in macOS 13 Ventura #97897
Copy link
Copy link
Closed
Labels
3.10 (EOL)end of lifeend of life3.11only security fixesonly security fixes3.12only security fixesonly security fixes3.9 (EOL)end of lifeend of lifeOS-macrelease-blockertype-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or errortype-crashA hard crash of the interpreter, possibly with a core dumpA hard crash of the interpreter, possibly with a core dump
Description
Activity
- addedtype-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or errorneeds backport to 3.10only security fixesonly security fixes3.11only security fixesonly security fixes3.10 (EOL)end of lifeend of lifetype-crashA hard crash of the interpreter, possibly with a core dumpA hard crash of the interpreter, possibly with a core dump3.12only security fixesonly security fixesneeds backport to 3.11only security fixesonly security fixes
on Oct 5, 2022 Since this could potentially cause segfaults on 3.9, perhaps a 3.9 backport should be considered (@ambv ?). (We do not support this kind of macOS weaklinking on 3.8 and earlier systems.)
- added a commit that references this issue
on Oct 6, 2022 2 remaining items
Marking as release blocker for @pablogsal's review with regard to 3.11.0.
- removedneeds backport to 3.10only security fixesonly security fixesneeds backport to 3.11only security fixesonly security fixes
on Oct 6, 2022 - added a commit that references this issue
on Oct 6, 2022 Backports to all current branches have been merged.
- added a commit that references this issue
on Oct 8, 2022 - added a commit that references this issue
on Oct 11, 2022 - added a commit that references this issue
on Oct 22, 2022 - added a commit that references this issue
on May 11, 2023
Metadata
Metadata
Assignees
Labels
3.10 (EOL)end of lifeend of life3.11only security fixesonly security fixes3.12only security fixesonly security fixes3.9 (EOL)end of lifeend of lifeOS-macrelease-blockertype-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or errortype-crashA hard crash of the interpreter, possibly with a core dumpA hard crash of the interpreter, possibly with a core dump
Projects
- StatusShow more project fieldsDone
macOS 13 Ventura adds support for the POSIX
mkfifoatandmknodatsystem calls which are used in the Python os module via posixmodule.c when available on the OS. In order to continue to support building Python on a newer macOS version to also run on older systems, we need to add weaklinking support for them in posixmodule.c as was done for other similar system calls added in recent macOS releases.Unfortunately, while macOS 13 has not yet been released as of this moment, Apple has pushed out a new version of the Command Line Tools for macOS 12 Monterey,
Command Line Tools beta 3 for Xcode 14.1, which changes the default macOS SDK version to MacOSX13.0. When building on macOS 12 with the macOS 13 SDK, posixmodule compiles support formkfifoatandmknodatwhich will cause Python segfaults when attempting to use thedir_fdoption ofos.mkfifo()oros.mknod()on macOS 12 (or older). An easily overlooked symptom of the problem is the following set of warning messages during compilation:One workaround is to force use of the macOS 12 SDK:
SDKROOT=$(xcrun --show-sdk-path --sdk macosx12.3) ./configure ...