From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ian Lance Taylor To: hjl@nynexst.com Cc: dholland@husc.harvard.edu, gas2@cygnus.com Subject: Re: problems with ld from binutils 2.5.2l.20 Date: Thu, 03 Aug 1995 08:29:00 -0000 Message-id: <199508031528.LAA03205@sanguine.cygnus.com> References: <9508031349.AA10077@nynexst.com> X-SW-Source: 1995/msg00145.html From: hjl@nynexst.com (H.J. Lu) Date: Thu, 3 Aug 95 9:49:19 EDT > > For the GNU linker, -L applies to all -l's. > > This behavior is wrong. First, it makes no sense, since the order of > -l's is significant, and second, it makes it impossible to control > which copies of which libraries are linked with, which could be > significant. The problem is twofold: 1. gcc will re-arrange the order of -L's and -l's. It puts -L's ahead of -l's. 2. One -L list is used fo all libraries in the linker. We have to change both gcc and ld to do the "right" thing. Just as a side note, the GNU linker behaviour is consistent with the SunOS linker behaviour. However, I agree that this should probably be changed. Ian