◐ Shell
reader mode source ↗
Skip to content

bpo-41100: add runtime checks for MACOSX_DEPLOYMENT_TARGET=10.10#21577

Closed
lawrence-danna-apple wants to merge 7 commits into
python:masterfrom
lawrence-danna-apple:postback-runtime-checks
Closed

bpo-41100: add runtime checks for MACOSX_DEPLOYMENT_TARGET=10.10#21577
lawrence-danna-apple wants to merge 7 commits into
python:masterfrom
lawrence-danna-apple:postback-runtime-checks

Conversation

@lawrence-danna-apple

@lawrence-danna-apple lawrence-danna-apple commented Jul 21, 2020

Copy link
Copy Markdown
Contributor

In order to support a universal2 build, supporitng Mac OS 11 on arm64 and Mac OS on
x86_64 going back to 10.10, we need to add in runtime checks for functions that will
be detected as present by autoconf, because they are in the SDK, but which did not
exist in Mac OS 10.10. This fixes all the instances of -WWunguarded-availability-new
when building with MACOSX_DEPLOYMENT_TARGET=10.10

https://bugs.python.org/issue41100

In order to support a universal2 build, supporitng Mac OS 11 on arm64 and Mac OS on
x86_64 going back to 10.10, we need to add in runtime checks for functions that will
be detected as present by autoconf, because they are in the SDK, but which did not
exist  in Mac OS 10.10.    This fixes all the instances of -WWunguarded-availability-new
when building with MACOSX_DEPLOYMENT_TARGET=10.10
@ned-deily

Copy link
Copy Markdown
Member

Thanks for the PR. @ronaldoussoren is working on a similar one at the moment. He can review and resolve differences.

@ronaldoussoren

Copy link
Copy Markdown
Contributor

I have a similar patch in #21583, but that one is targeting macOS 10.9 instead of 10.10 and is incomplete and as of yet untested ("it compiles therefore it is correct").

I like your approach with HAVE_..._RUNTIME macro's, that reduces the amount of cruft compared with my approach.

@ronaldoussoren ronaldoussoren left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Hide comment

Just some comments at this time. The basic approach looks sane, but I haven't look at the changes in detail yet.

These complications were needed on a previous build of Xcode but as of
XCode 12 beta 3 it works without them.
@ned-deily

Copy link
Copy Markdown
Member

Thanks for the PR. The changes in the PR have been used as the basis for changes in GH-22855.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants