[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: multilib improvement?
Re: multilib improvement?
Sat, 21 Oct 2006 13:52:30 +0200
Hello Peter, Bob,
* Bob Friesenhahn wrote on Wed, Oct 18, 2006 at 06:13:39PM CEST:
> On Wed, 18 Oct 2006, Peter O'Gorman wrote:
> >This is what I came up with to take -m64/-m32 into account when using gcc.
> I am not able to spot a problem with it. Extensive testing will prove
> if it works as expected.
Except of course that no test case was added to confirm this, so there
is no way you can know it's fixed except for hoping that somebody will
test it before the release (or you do it yourself).
Taking the idealistic hat off, how can we test something like this
usefully? I think one idea may be like this: Try to link against an
installed library in one of the search paths with -L$path. If that
succeeds, then omitting -L$path should succeed as well. It's quite
a weak test; too weak for most possible errors, but at least I think
it should not have false negatives. Do you have better ideas?
And of course the patch is missing a NEWS addition, this having been
a bug that bothered many people.
OK to apply (NEWS also to branch-1-5)?
I haven't had a chance to test your actual patch yet, by the way.
* NEWS: Account for recent fix.
* tests/search-path.at: New test.
* Makefile.am: Update.
RCS file: /cvsroot/libtool/libtool/NEWS,v
retrieving revision 1.196
diff -u -r1.196 NEWS
--- NEWS 17 Sep 2006 19:30:15 -0000 1.196
+++ NEWS 21 Oct 2006 11:47:13 -0000
@@ -35,6 +35,7 @@
* Initial support for the Sun compiler suite on GNU/Linux.
* Improved support for GNU/kFreeBSD and GNU/NetBSD.
+* Search paths with GCC on multilib systems like x86_64 have been fixed.
* Bug fixes.
New in 1.9f: 2004-10-23; CVS version 1.9e, Libtool team:
RCS file: /cvsroot/libtool/libtool/Makefile.am,v
retrieving revision 1.200
diff -u -r1.200 Makefile.am
--- Makefile.am 17 Sep 2006 20:02:15 -0000 1.200
+++ Makefile.am 21 Oct 2006 11:45:02 -0000
@@ -407,6 +407,7 @@
+ tests/search-path.at \
--- /dev/null 2006-10-09 01:10:44.864355000 +0200
+++ tests/search-path.at 2006-10-21 13:49:42.000000000 +0200
@@ -0,0 +1,43 @@
+# Hand crafted tests for GNU Libtool. -*- Autotest -*-
+# Copyright 2006 Free Software Foundation, Inc.
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+# 02110-1301, USA.
+[[extern int inflate ();
+ return inflate ();
+$CC $CPPFLAGS $CFLAGS -c main.c
+eval `$LIBTOOL --config | $EGREP '^(sys_lib_search_path_spec)='`
+for path in $sys_lib_search_path; do
+ if $LIBTOOL --mode=link $CC $CFLAGS $LDFLAGS -o main main.$OBJEXT -L$path -lz
+ AT_CHECK([$LIBTOOL --mode=link $CC $CFLAGS $LDFLAGS -o main main.$OBJEXT
+ , [ignore], [ignore])