File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -50,10 +50,10 @@ if [[ -n "$IS_MACOS" ]]; then
5050else
5151 GIFLIB_VERSION=5.2.1
5252fi
53- if [[ -n " $IS_MACOS " ]] || [[ " $MB_ML_VER " != 2014 ]] ; then
53+ if [[ -n " $IS_MACOS " ]]; then
5454 ZLIB_VERSION=1.3.1
5555else
56- ZLIB_VERSION=1 .2.8
56+ ZLIB_NG_VERSION=2 .2.2
5757fi
5858LIBWEBP_VERSION=1.4.0
5959BZIP2_VERSION=1.0.8
@@ -74,6 +74,16 @@ function build_pkg_config {
7474 touch pkg-config-stamp
7575}
7676
77+ function build_zlib_ng {
78+ if [ -e zlib-stamp ]; then return ; fi
79+ fetch_unpack https://github.com/zlib-ng/zlib-ng/archive/$ZLIB_NG_VERSION .tar.gz zlib-ng-$ZLIB_NG_VERSION .tar.gz
80+ (cd zlib-ng-$ZLIB_NG_VERSION \
81+ && ./configure --prefix=$BUILD_PREFIX --zlib-compat \
82+ && make -j4 \
83+ && make install)
84+ touch zlib-stamp
85+ }
86+
7787function build_brotli {
7888 if [ -e brotli-stamp ]; then return ; fi
7989 local cmake=$( get_modern_cmake)
@@ -101,7 +111,11 @@ function build {
101111 if [ -z " $IS_ALPINE " ] && [ -z " $IS_MACOS " ]; then
102112 yum remove -y zlib-devel
103113 fi
104- build_new_zlib
114+ if [ -n " $IS_MACOS " ]; then
115+ build_new_zlib
116+ else
117+ build_zlib_ng
118+ fi
105119
106120 build_simple xcb-proto 1.17.0 https://xorg.freedesktop.org/archive/individual/proto
107121 if [ -n " $IS_MACOS " ]; then
Original file line number Diff line number Diff line change @@ -40,7 +40,7 @@ def test_wheel_features() -> None:
4040
4141 if sys .platform == "win32" :
4242 expected_features .remove ("xcb" )
43- else :
43+ elif sys . platform == "darwin" :
4444 expected_features .remove ("zlib_ng" )
4545
4646 assert set (features .get_supported_features ()) == expected_features
You can’t perform that action at this time.
0 commit comments