]> git.ipfire.org Git - thirdparty/libtool.git/commitdiff
* ltmain.sh: Allow link against an archive when building a
authorH.J. Lu <hjl@gnu.org>
Wed, 24 Oct 2001 14:30:22 +0000 (14:30 +0000)
committerRobert Boehne <rboehne@gnu.org>
Wed, 24 Oct 2001 14:30:22 +0000 (14:30 +0000)
shared library.
* libtool.m4 (lt_cv_deplibs_check_method): Always use
file_magic for Linux ELF.

ChangeLog
libtool.m4
ltmain.in

index a1291d51015ed889f800ba372f4c94ba6e8721fa..55a29b50bb0cdf111c3860be6769e3ad74909fd4 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2001-10-24  H.J. Lu <hjl@gnu.org>
+
+       * ltmain.sh: Allow link against an archive when building a
+       shared library.
+       * libtool.m4 (lt_cv_deplibs_check_method): Always use
+       file_magic for Linux ELF.
+
 2001-10-12 Guido Draheim  <guidod-2001q3@gmx.de>
 
        * ltdl.m4: Changed "underscode to underscore".
index 76a970ce028f61c1168c42d9731242318efe1881..8fe14b50af16942402c61a51272891ae1648b9d1 100644 (file)
@@ -1944,6 +1944,7 @@ linux*)
     # glibc up to 2.1.1 does not perform some relocations on ARM
     lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' ;;
   esac
+  lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )'
   lt_cv_file_magic_test_file=`echo /lib/libc.so* /lib/libc-*.so`
   ;;
 
index 3fa03c956d558659c2db28051444249a351ce3df..0db856cd0f1fd03a1aa1314ce146862cfc8cb02e 100644 (file)
--- a/ltmain.in
+++ b/ltmain.in
@@ -2973,6 +2973,13 @@ EOF
                        *) potlib=`$echo "X$potlib" | $Xsed -e 's,[^/]*$,,'`"$potliblink";;
                        esac
                      done
+                     # It is ok to link against an archive when
+                     # building a shared library.
+                     if $AR -t $potlib > /dev/null 2>&1; then
+                       newdeplibs="$newdeplibs $a_deplib"
+                       a_deplib=""
+                       break 2
+                     fi
                      if eval $file_magic_cmd \"\$potlib\" 2>/dev/null \
                         | sed 10q \
                         | egrep "$file_magic_regex" > /dev/null; then