From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ian Lance Taylor To: hjl@nynexst.com Cc: gas2@cygnus.com Subject: Re: An ELF linker bug? Date: Mon, 11 Sep 1995 08:07:00 -0000 Message-id: <199509111507.LAA19337@sanguine.cygnus.com> References: X-SW-Source: 1995/msg00163.html From: hjl@nynexst.com (H.J. Lu) Date: Sun, 10 Sep 1995 21:33:01 -0400 (EDT) Here is a simple test. "f1" should print out "foo". Under UnixWare, it worked fine. But gas-950822 failed to pick up the strong "foo". Also Solaris 2.3 got it wrong. I think this case is undefined. You are defining a symbol twice in an archive. It does not matter that one definition is weak and one is normal. A weak definition is pulled in from an archive just as a normal one is. This case is equivalent to defining the same symbol in two different object files and including them both in an archive: you can not predict which object file will be included in the final link. Ian