aboutsummaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorCory Fields <cory-nospam-@coryfields.com>2023-05-10 22:48:00 +0000
committerCory Fields <cory-nospam-@coryfields.com>2023-05-12 19:13:57 +0000
commit283d95516a11166631818dd448ed53a2374b5db8 (patch)
tree42df13751f7baf1814551e17df05c3cb175c53e9 /configure.ac
parent137a98c5a22e058ed7a7997a0a4dbd75301de51e (diff)
downloadbitcoin-283d95516a11166631818dd448ed53a2374b5db8.tar.xz
build: Fix shared lib linking for darwin with lld
libtool gets a false-positive from the warning produced by lld -single_module because it is already the default and unneeded. Skip the check unconditionally for Darwin linkers.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac10
1 files changed, 10 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index cbbf8d6172..41fee5cdca 100644
--- a/configure.ac
+++ b/configure.ac
@@ -83,6 +83,16 @@ case $host in
lt_cv_prog_compiler_pic="-DPIC"
lt_cv_prog_compiler_pic_CXX="-DPIC"
;;
+ *darwin*)
+ dnl Because it prints a verbose warning, lld fails the following check
+ dnl for "-Wl,-single_module" from libtool.m4:
+ dnl # If there is a non-empty error log, and "single_module"
+ dnl # appears in it, assume the flag caused a linker warning
+ dnl "-single_module" works fine on ld64 and lld, so just bypass the test.
+ dnl Failure to set this to "yes" causes libtool to use a very broken
+ dnl link-line for shared libs.
+ lt_cv_apple_cc_single_mod="yes"
+ ;;
esac
AC_ARG_WITH([seccomp],