From mboxrd@z Thu Jan 1 00:00:00 1970 From: DJ Delorie To: phdm@macqel.be Cc: gas2@cygnus.com Subject: Re: why is an archive member linked in ? Date: Mon, 29 Dec 1997 19:24:00 -0000 Message-id: <199712300324.WAA23012@delorie.com> References: <199712300309.EAA31445@mail.macqel.be> X-SW-Source: 1997/msg00060.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.