-
-
Notifications
You must be signed in to change notification settings - Fork 30.1k
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
Properly link against functions introduced in macOS 10.12 #350
Conversation
Hello, and thanks for your contribution! I'm a bot set up to make sure that the project can legally accept your contribution by verifying you have signed the PSF contributor agreement (CLA). Unfortunately we couldn't find an account corresponding to your GitHub username on bugs.python.org (b.p.o) to verify you have signed the CLA. This is necessary for legal reasons before we can look at your contribution. Please follow these steps to help rectify the issue:
Thanks again to your contribution and we look forward to looking at it! |
Please open an issue on bugs.python.org for this. But, note that in general, we do not claim to support building Python for an older OS X version with a newer SDK using weak links. |
Hey Ned, this is following up on http://bugs.python.org/issue27596. I took a closer look at the changes made in http://bugs.python.org/issue29057 but we don't think they solve the fundamental issue for our scenario (we deploy on 10.6-10.12 using the latest SDK, as Apple recommends), particularly when using Python 3. |
Bumps [pytest-asyncio](https://github.com/pytest-dev/pytest-asyncio) from 0.12.0 to 0.14.0. - [Release notes](https://github.com/pytest-dev/pytest-asyncio/releases) - [Commits](pytest-dev/pytest-asyncio@v0.12.0...v0.14.0) Signed-off-by: dependabot-preview[bot] <[email protected]> Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
macOS Sierra/10.12 introduced new functions that are problematic to link against (i.e.
getentropy
,clock_gettime
, etc) becauseautoconf
detecting their presence isn't sufficient to guarantee they will be available downlevel. Building Python using Xcode 8 and the macOS 10.12 SDK and following Apple's recommended practices (see https://developer.apple.com/library/content/documentation/DeveloperTools/Conceptual/cross_development/Configuring/configuring.html), to setMACOSX_DEPLOYMENT_TARGET
to the minimum version to be supported (e.g.10.8
) will result in these functions being weakly linked. While testing on macOS 10.12 works properly, running Python on an older (yet declared supported) version will trigger a crash when the symbol is used, as the code doesn't appear to support the symbol being weakly defined (who would). Essentially,AC_CHECK_FUNCS
is not sufficient for these functions on macOS, so we need to do extra work.This patch alters
configure
not to check when building for Darwin andMACOSX_DEPLOYMENT_TARGET
is defined to a version below 10.12, allowing proper down-level support.