From: Un1q32 Date: Tue, 23 Apr 2024 23:54:05 +0000 (-0400) Subject: make darwin cross compilation possible X-Git-Tag: 2.1.7~21 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=59dbca05335aa645009097d31c7bd8cf506ffa04;p=thirdparty%2Fzlib-ng.git make darwin cross compilation possible https://github.com/madler/zlib/pull/789 --- diff --git a/configure b/configure index 9211dcb9..7543fd81 100755 --- a/configure +++ b/configure @@ -471,7 +471,9 @@ if test "$gcc" -eq 1 && ($cc $CFLAGS -c $test.c) >> configure.log 2>&1; then SHAREDTARGET=$SHAREDLIBV LDSHARED=${LDSHARED-"$cc"} LDSHAREDFLAGS="-dynamiclib -install_name @rpath/${SHAREDLIBM} -compatibility_version ${VER1} -current_version ${VER3}" - if libtool -V 2>&1 | grep Apple > /dev/null; then + if "${CROSS_PREFIX}libtool" -V 2>&1 | grep Apple > /dev/null; then + AR="${CROSS_PREFIX}libtool" + elif libtool -V 2>&1 | grep Apple > /dev/null; then AR="libtool" else AR="/usr/bin/libtool"