]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
m4/dovecot.m4: Fix including all symbols from .a libs with new glibc
authorTimo Sirainen <timo.sirainen@open-xchange.com>
Mon, 23 Jan 2023 18:53:39 +0000 (20:53 +0200)
committeraki.tuomi <aki.tuomi@open-xchange.com>
Wed, 25 Jan 2023 09:01:44 +0000 (09:01 +0000)
New glibc no longer has libdl, so the check for it no longer works.
Use -export-dynamic instead, which is used with both old and new glibc.

m4/dovecot.m4

index aeff3b802bba6f836e9697c9b25a6784abced6dd..3f9bf721e3a515cbfa8516b17530669a2f3b2f0b 100644 (file)
@@ -6,7 +6,7 @@ dnl This file is free software; the authors give
 dnl unlimited permission to copy and/or distribute it, with or without
 dnl modifications, as long as this notice is preserved.
 
-# serial 37
+# serial 38
 
 dnl
 dnl Check for support for D_FORTIFY_SOURCE=2
@@ -419,7 +419,7 @@ AC_DEFUN([DC_CC_WRAPPER],[
        cat > cc-wrapper.sh <<_DC_EOF
 #!/bin/sh
 
-if echo "\$[*]" | grep -- -ldl > /dev/null; then
+if echo "\$[*]" | grep -- -export-dynamic > /dev/null; then
   # the binary uses plugins. make sure we include everything from .a libs
   exec $CC -Wl,--whole-archive \$[*] -Wl,--no-whole-archive
 else