Do not override the deployment target that MacPorts sets. https://github.com/microsoft/msphpsql/commit/f59f0bcce7d0d000900c820ad4bc1917b3a20dd8 --- config.m4.orig 2020-04-14 12:16:07.000000000 -0500 +++ config.m4 2022-02-03 03:46:02.000000000 -0600 @@ -59,7 +59,6 @@ HOST_OS_ARCH=`uname` if test "${HOST_OS_ARCH}" = "Darwin"; then SQLSRV_SHARED_LIBADD="$SQLSRV_SHARED_LIBADD -Wl,-bind_at_load" - MACOSX_DEPLOYMENT_TARGET=`sw_vers -productVersion` else SQLSRV_SHARED_LIBADD="$SQLSRV_SHARED_LIBADD -Wl,-z,now" IS_ALPINE_1=`uname -a | cut -f 4 -d ' ' | cut -f 2 -d '-'`