From 83e3dac813122a020e01430d4c1bd4b149f67bd3 Mon Sep 17 00:00:00 2001 From: Zanie Blue Date: Thu, 5 Sep 2024 17:29:05 -0500 Subject: [PATCH] Disable `ptsname_r` on `x86_64-apple-darwin` for Python 3.13+ --- cpython-unix/build-cpython.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/cpython-unix/build-cpython.sh b/cpython-unix/build-cpython.sh index 1c547264..25ee091b 100755 --- a/cpython-unix/build-cpython.sh +++ b/cpython-unix/build-cpython.sh @@ -444,6 +444,12 @@ if [ "${PYBUILD_PLATFORM}" = "macos" ]; then export MACOSX_DEPLOYMENT_TARGET="${APPLE_MIN_DEPLOYMENT_TARGET}" fi +# ptsrname_r is only available in SDK 13.4+ +if [ "${PYBUILD_PLATFORM}" = "macos" ]; then + echo "Disabling ptsname_r due to macOS SDK 13.4+ requirement." + CONFIGURE_FLAGS="${CONFIGURE_FLAGS} ac_cv_func_ptsname_r=no" +fi + # We use ndbm on macOS and BerkeleyDB elsewhere. if [ "${PYBUILD_PLATFORM}" = "macos" ]; then CONFIGURE_FLAGS="${CONFIGURE_FLAGS} --with-dbmliborder=ndbm"