--- configure +++ configure @@ -15866,12 +15842,31 @@ $as_echo "#define PA_USE_COREAUDIO 1" >>confdefs.h - CFLAGS="$CFLAGS -I\$(top_srcdir)/src/os/unix -Wno-deprecated" + CFLAGS="$CFLAGS -I\$(top_srcdir)/src/os/unix -Wno-deprecated -DNDEBUG" LIBS="-framework CoreAudio -framework AudioToolbox -framework AudioUnit -framework CoreFoundation -framework CoreServices" if test "x$enable_mac_universal" = "xyes" ; then - mac_version_min="-mmacosx-version-min=10.6" - mac_sysroot="-isysroot $(xcrun --sdk macosx --show-sdk-path)" + case `xcodebuild -version | sed -n 's/Xcode \(.*\)/\1/p'` in + + 3.0|3.1) + if [ -d /Developer/SDKs/MacOSX10.5.sdk ] ; then + mac_version_min="-mmacosx-version-min=10.5" + mac_sysroot="-isysroot /Developer/SDKs/MacOSX10.5.sdk" + else + mac_version_min="-mmacosx-version-min=10.4" + mac_sysroot="-isysroot /Developer/SDKs/MacOSX10.4u.sdk" + fi + ;; + + *) + if xcrun --sdk macosx10.5 --show-sdk-path >/dev/null 2>&1 ; then + mac_version_min="-mmacosx-version-min=10.5" + mac_sysroot="-isysroot $(xcrun --sdk macosx10.5 --show-sdk-path)" + else + mac_version_min="-mmacosx-version-min=10.6" + mac_sysroot="-isysroot $(xcrun --sdk macosx --show-sdk-path)" + fi + esac mac_arches="" for arch in x86_64 arm64