This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: binutils-2.11 ld testsuite problems + PATCH
"H . J . Lu" wrote:
>
> On Tue, May 08, 2001 at 10:58:31AM -0700, Matthew Schalit wrote:
> >
> > > # readelf -d some DSO in /usr/lib other than libc.so.1.
> >
> > Here's -lnsl and -lsocket, so you can see a little variety,
> > but still have them both be SCO system libraries:
> >
> > Yoda:/usr/lib>$readelf -d ./libsocket.so
> >
> > Dynamic segment at offset 0x41d4 contains 16 entries:
> > Tag Type Name/Value
> > 0x00000001 (NEEDED) Shared library: [/usr/lib/libnsl.so.1]
> >
>
> Bad SCO. That means you have to have libnsl.so.1 in /usr/lib. I hate
> the hard coded things like that.
It appears that about 20 different libs in /usr/lib have
dependencies on other libraries and show the NEEDED flag.
All the NEEDED libs are listed with hard coded paths.
> > I'll download CVS after lunch, build it and run a gmake check-ld
> > on it. Isn't this "can't find -lc" problem I'm having with netpbm
> > the same as the check-ld problem finding -lc?
>
> It is very possible. It sounds like I have to modify elf32.em to
> deal with SCO :-(.
Ok, I just downloaded CVS binutils, configured it with
./configure --enable-shared
and built it with
gmake
and applied the my PATCH to ld/configure.host (attached) so that
I could gmake check-ld without a gmake error.
I get the exact same errors with ld not finding -lc:
------------------------------------------------------------
=== ld Summary ===
# of expected passes 10
# of unexpected failures 7
# of untested testcases 9
-------------------------------------------------------------
My attached patch is the same one as I offered in my first
post from this thread. I think an attachment is the appropriate
way to deal with the long lines in it.
Please note we haven't covered the other check-ld error I was
getting:
-------------------------------------------------------------------------
lt-ld-new: Dwarf Error: Can't find .debug_abbrev section.
tmpdir/sr1.o(.debug_info+0x6): undefined reference to `__abbr_table_1.0'
lt-ld-new: Dwarf Error: Can't find .debug_abbrev section.
tmpdir/sr2.o(.debug_info+0x6): undefined reference to `__abbr_table_1.0'
FAIL: S-records
-------------------------------------------------------------------------
Thanks again,
Matthew
> H.J.
--- ld/configure.host.orig Tue May 8 12:48:15 2001
+++ ld/configure.host Tue May 8 12:59:42 2001
@@ -55,6 +55,11 @@
HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else ${CC} -print-libgcc-file-name; fi` -lc `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; else ${CC} -print-file-name=crtend.o; fi`'
;;
+i[3456]86-sco-sysv5uw7*)
+ HOSTING_CRT0='/usr/ccs/lib/crt1.o `if [ -f ../gcc/crtbegin.o ]; then echo ../gcc/crtbegin.o; fi`'
+ HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; elif [ "${CC}" = gcc ]; then ${CC} -print-libgcc-file-name; fi;` -lc `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; fi` /usr/ccs/lib/crtn.o'
+ ;;
+
i[3456]86-*-sysv*)
HOSTING_CRT0='/lib/crt1.o `if [ -f ../gcc/crtbegin.o ]; then echo ../gcc/crtbegin.o; fi`'
HOSTING_LIBS='`if [ -f ../gcc/libgcc.a ] ; then echo ../gcc/libgcc.a ; else ${CC} -print-libgcc-file-name; fi` -lc `if [ -f ../gcc/crtend.o ]; then echo ../gcc/crtend.o; fi` /lib/crtn.o'