[PATCH] PR ld/18720: Properly merge non-default versioned symbol
H.J. Lu
hjl.tools@gmail.com
Mon Jul 27 19:31:00 GMT 2015
On Mon, Jul 27, 2015 at 12:27 PM, Cary Coutant <ccoutant@gmail.com> wrote:
>>> To me, if you're going to allow the two names to be the same, it
>>> should define only one symbol. That would allow a library developer to
>>> maintain multiple versions of a function in separate source files,
>>> like this:
>>
>> The current gas/linker provide flexibility to support both ways.
>
> No, it doesn't. If you try to link foo-orig.o, foo-ver1.o, and
> foo-ver2.o, you'll get multiply-defined symbol errors for "foo".
>
That is how GNU symbol version works. You can improve it only without
breaking ld testsuite.
--
H.J.
More information about the Binutils
mailing list