This is the mail archive of the
binutils@sourceware.cygnus.com
mailing list for the binutils project.
Re: binutils-20000625 ld.exe --shared broken
- To: binutils at sourceware dot cygnus dot com
- Subject: Re: binutils-20000625 ld.exe --shared broken
- From: Charles Wilson <cwilson at ece dot gatech dot edu>
- Date: Fri, 07 Jul 2000 11:58:17 -0400
- References: <396547F2.333FBD51@ece.gatech.edu> <200007070300.XAA08402@envy.delorie.com> <396574C7.924FADB6@ece.gatech.edu> <200007071339.JAA10915@envy.delorie.com>
[Just a little context on this thread, for the binutils folks who didn't
catch its beginning on the cygwin mailing list]
> I reported this previously, but in a different thread
[on the cygwin list]
> I figure this
> bug deserves its own thread. Somewhere between Mumit's custom 19990818
> version of binutils as distributed in
[the 'latest' cygwin distribution directory]
> and the more recent cygwin
> binutils (20000625) which is more-or-less direct from binutils-CVS, the
> --shared option broke.
>
> I'm getting the following error, using the ==stock== cygwin
> binutils-20000625 ld.exe:
>
> ------
> ld --shared -Bdynamic -e __cygwin_dll_entry@12 -o libz.dll
> -L/usr/lib/gcc-lib/i686-pc-cygwin/2.95.2
> -L/usr/lib/gcc-lib/i686-pc-cygwin/2.95.2/../../../../i686-pc-cygwin/lib
> --out-implib=libz.dll.a libz.def adler32.o compress.o crc32.o gzio.o
> uncompr.o deflate.o trees.o zutil.o inflate.o infblock.o inftrees.o
> infcodes.o infutil.o inffast.o -lgcc -lcygwin -luser32 -lkernel32
> -ladvapi32 -lshell32 -lgcc
>
> Creating library file: libz.dll.a
> bfd_close libz.dll.a: Invalid operation
> ------
>
> This command works fine if I simply replace ld.exe with the one from the
> 19990818 cygwin tarball.
>
> Can anybody recommend *where* in the code I should start looking for
> this problem? (Yeah, 'bfd_close' is pretty obvious, but I saw nothing
> enlightening there. The binutils code with its cross-platform-ness is
> really a tangled confusing mess...)
--------------
DJ responded:
> Try searching for BFD_IN_MEMORY. It's notoriously buggy, and used to
> build the import libraries.
--------------
And that brings us up to the message that DJ crossposted here on
binutils.
--Chuck