Add LDFLAGS for zlib on macOS >= 1100 (#1711)

Add LDFLAGS for Xcode SDK zlib on macOS >= 1100 to resolve build issues on Big Sur.
This commit is contained in:
Benjamin Howell 2020-11-14 16:48:15 -05:00 committed by GitHub
parent 806b30d6ce
commit 943015ebb2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1493,6 +1493,9 @@ use_xcode_sdk_zlib() {
if [ -d "$xc_sdk_path" ]; then
echo "python-build: use zlib from xcode sdk"
export CFLAGS="-I${xc_sdk_path}/usr/include ${CFLAGS}"
if is_mac -ge 1100; then
export LDFLAGS="-L${xc_sdk_path}/usr/lib ${LDFLAGS}"
fi
fi
}