On 2003-07-05(Sat) 14:09:40 -0400, Charles Wilson wrote: > Other than identifying the problem, I don't really know how to correct > the remaining issue. But in this message > > http://mail.gnu.org/archive/html/libtool/2003-05/msg00022.html > > I posted a test case that demonstrates the issue; if anybody can figure > out how to fix libtool, they can test their fix with this small testcase > rather than trying to build guile. :-)
Here is a patch attached, that always worked for me so far. It forcefully puts -L$inst_prefix_dir in front of all other -L and -l flags. Please tell me if this patch is appropriate or not to commit into CVS. Good to know that others are bringing up this problem again. Not only for test cases, I see the same problem in realworld cases too; it was picking up installed gettext-0.11.x while relinking gettext 0.12.x libraries. Abel -- Abel Cheung Linux counter #256983 | http://counter.li.org GPG Key: (0xC67186FF) | http://deaddog.org/gpg.asc Key fingerprint: 671C C7AE EFB5 110C D6D1 41EE 4152 E1F1 C671 86FF
Index: ChangeLog
===================================================================
RCS file: /cvsroot/libtool/libtool/ChangeLog,v
retrieving revision 1.1220.2.18
diff -u -r1.1220.2.18 ChangeLog
--- ChangeLog 26 Jun 2003 06:55:25 -0000 1.1220.2.18
+++ ChangeLog 6 Jul 2003 10:22:19 -0000
@@ -1,3 +1,9 @@
+2003-07-06 Abel Cheung <[EMAIL PROTECTED]>
+
+ * ltmain.in: Always prepend inst_prefix_dir to deplibs so that
+ system libraries won't be picked up before staging libraries during
+ relinking.
+
2003-06-25 Alexandre Oliva <[EMAIL PROTECTED]>, Tim Waugh <[EMAIL PROTECTED]>
* libtool.m4: Replace mis-uses of path with pathname.
Index: ltmain.in
===================================================================
RCS file: /cvsroot/libtool/libtool/ltmain.in,v
retrieving revision 1.334.2.5
diff -u -r1.334.2.5 ltmain.in
--- ltmain.in 3 Jun 2003 18:20:07 -0000 1.334.2.5
+++ ltmain.in 6 Jul 2003 10:23:57 -0000
@@ -3599,15 +3599,23 @@
fi
tmp_deplibs=
+ inst_prefix_arg=
for test_deplib in $deplibs; do
case " $convenience " in
*" $test_deplib "*) ;;
*)
- tmp_deplibs="$tmp_deplibs $test_deplib"
+ if test -n "$inst_prefix_dir" && (echo "$test_deplib" | grep
-- "$inst_prefix_dir" >/dev/null); then
+ inst_prefix_arg="$test_deplib"
+ else
+ tmp_deplibs="$tmp_deplibs $test_deplib"
+ fi
;;
esac
done
deplibs="$tmp_deplibs"
+ if test -n "$inst_prefix_arg"; then
+ deplibs="$inst_prefix_arg $deplibs"
+ fi
if test -n "$convenience"; then
if test -n "$whole_archive_flag_spec"; then
pgp00000.pgp
Description: PGP signature
_______________________________________________ Libtool mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/libtool
