From 911b787e226f9343ba57a56fdd6e9154cddad7f9 Mon Sep 17 00:00:00 2001 From: Peter O'Gorman Date: Thu, 27 Mar 2008 17:53:46 +0000 Subject: [PATCH] * libltdl/m4/libtool.m4 [_LT_REQUIRED_DARWIN_CHECKS]: Fix the test for -single_module and log it to config.log. Reported by Torok Edwin and Nigel Home. --- ChangeLog | 6 ++++++ libltdl/m4/libtool.m4 | 14 ++++++++++---- 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 9593f9c63..d02a9c7b6 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2008-03-27 Peter O'Gorman + + * libltdl/m4/libtool.m4 [_LT_REQUIRED_DARWIN_CHECKS]: Fix the + test for -single_module and log it to config.log. + Reported by Torok Edwin and Nigel Home. + 2008-03-24 Ralf Wildenhues Document that disable-static plus -all-static is not portable. diff --git a/libltdl/m4/libtool.m4 b/libltdl/m4/libtool.m4 index 9a700e65c..d345af6b0 100644 --- a/libltdl/m4/libtool.m4 +++ b/libltdl/m4/libtool.m4 @@ -905,14 +905,20 @@ m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ # by either setting the environment variable LT_MULTI_MODULE # non-empty at configure time, or by adding -multi_module to the # link flags. + rm -rf libconftest.dylib* echo "int foo(void){return 1;}" > conftest.c + echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ +-dynamiclib -Wl,-single_module conftest.c" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ - -dynamiclib ${wl}-single_module conftest.c - if test -f libconftest.dylib; then + -dynamiclib -Wl,-single_module conftest.c 2>conftest.err + _lt_result=$? + if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then lt_cv_apple_cc_single_mod=yes - rm -rf libconftest.dylib* + else + cat conftest.err >&AS_MESSAGE_LOG_FD fi - rm conftest.c + rm -rf libconftest.dylib* + rm -f conftest.* fi]) AC_CACHE_CHECK([for -exported_symbols_list linker flag], [lt_cv_ld_exported_symbols_list], -- 2.47.2