]> git.ipfire.org Git - thirdparty/zlib-ng.git/commitdiff
make darwin cross compilation possible
authorUn1q32 <joey.t.reinhart@gmail.com>
Tue, 23 Apr 2024 23:54:05 +0000 (19:54 -0400)
committerHans Kristian Rosbach <hk-github@circlestorm.org>
Wed, 19 Jun 2024 12:15:54 +0000 (14:15 +0200)
https://github.com/madler/zlib/pull/789

configure

index 9211dcb990f3c2a1cc93dde934c8fd5f15ae02af..7543fd81e10afc27c3744715ba7c8514f795170f 100755 (executable)
--- 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"