Properly detect background thread support on Darwin.

When cross-compile, the host type / abi should be checked to determine
background thread compatibility.
This commit is contained in:
Qi Wang 2022-02-14 17:30:11 -08:00 committed by Qi Wang
parent a4e81221cc
commit 063d134aeb

View File

@ -2394,7 +2394,8 @@ fi
dnl ============================================================================
dnl Enable background threads if possible.
if test "x${have_pthread}" = "x1" -a "x${je_cv_os_unfair_lock}" != "xyes" ; then
if test "x${have_pthread}" = "x1" -a "x${je_cv_os_unfair_lock}" != "xyes" -a \
"x${abi}" != "xmacho" ; then
AC_DEFINE([JEMALLOC_BACKGROUND_THREAD], [ ], [ ])
fi