From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Philippe De Muyter" To: dj@delorie.com (DJ Delorie) Cc: gas2@cygnus.com Subject: Re: why is an archive member linked in ? Date: Mon, 29 Dec 1997 20:01:00 -0000 Message-id: <199712300401.FAA31778@mail.macqel.be> References: <199712300324.WAA23012@delorie.com> X-SW-Source: 1997/msg00061.html > > > > In the specific case I encountered, removing the module from the archive > > made my link command succeed, while with the module in the archive my > > link command failed because of some unresolved symbols in the module > > that got linked in. > > Sometimes, there might be more than one object that resolves a > specific symbol. If you take one out, the other gets used, and that > changes everything. > > For example, DJGPP has two math libraries. One (libm.a) has a > complete set of conforming (but slightly slower) functions, and the > other (in libc.a) is smaller and faster, but less complete and less > conforming. If you link in libm.a, you get that set, but if you leave > it out, the ones in libc.a get used. > Thanks. I already know that but that's the (slow and ugly) method I use to find why an archive member causing a link error is linked in. What I need is a clean and fast method, e.g. a gld option or, better, a direct information in the error message. Philippe