From: Ralf Wildenhues Date: Sun, 5 Feb 2006 11:08:52 +0000 (+0000) Subject: * ltmain.in (extracted_archives, extracted_serial): New globals. X-Git-Tag: release-1-5-23b~56 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=be80015b3ce0670aa07719c7e232f0061019db03;p=thirdparty%2Flibtool.git * ltmain.in (extracted_archives, extracted_serial): New globals. (func_extract_archives): Use them to rename extraction archives for linking against multiple convenience libraries with the same name. Reported by Carlo Contavalli . --- diff --git a/ChangeLog b/ChangeLog index c3fc52b80..56b3ed39e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,11 @@ 2006-02-05 Ralf Wildenhues + * ltmain.in (extracted_archives, extracted_serial): New globals. + (func_extract_archives): Use them to rename extraction archives + for linking against multiple convenience libraries with the same + name. + Reported by Carlo Contavalli . + * ltmain.in (link mode) < test_compile >: Fix a couple of instances where `test .. -ne ..' would possibly compare non-numbers. Clean up a bit. diff --git a/ltmain.in b/ltmain.in index 37398b54e..981cc3129 100644 --- a/ltmain.in +++ b/ltmain.in @@ -136,6 +136,8 @@ duplicate_deps=no preserve_args= lo2o="s/\\.lo\$/.${objext}/" o2lo="s/\\.${objext}\$/.lo/" +extracted_archives= +extracted_serial=0 ##################################### # Shell function definitions: @@ -333,7 +335,17 @@ func_extract_archives () *) my_xabs=`pwd`"/$my_xlib" ;; esac my_xlib=`$echo "X$my_xlib" | $Xsed -e 's%^.*/%%'` - my_xdir="$my_gentop/$my_xlib" + my_xlib_u=$my_xlib + while :; do + case " $extracted_archives " in + *" $my_xlib_u "*) + extracted_serial=`expr $extracted_serial + 1` + my_xlib_u=lt$extracted_serial-$my_xlib ;; + *) break ;; + esac + done + extracted_archives="$extracted_archives $my_xlib_u" + my_xdir="$my_gentop/$my_xlib_u" $show "${rm}r $my_xdir" $run ${rm}r "$my_xdir"