This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: A patch for default version and archive


Ian Lance Taylor <ian@zembu.com> writes:

> One is to make it possible to specify the version of a symbol in a
> .o file rather than requiring a version script when building a
> shared object.  The other is to simplify the implementation within
> the existing GNU linker code, except that that turned out to be a
> mistake, since it actually makes the implementation more complex and
> harder to understand.

Actually no.  The version script serves mainly the purpose of hiding
symbols from not being exported.  This was before the introduction of
the .protected and .private attributes.  Today we would do it
differently.

> If we eliminated the @ symbols,

You mean "eliminating the version script"?  The @ symbols cannot be
eliminated.

> hen the creator of a shared object would have to specify the
> versions at creation time, and I believe the situation would be more
> comprehensible, albeit much harder on library maintainers.

We have to do this anyway.  Plus, ld has still bugs with exporting
symbols which are not meant to be exported.

> What I think we really need to do is to write down the semantics of
> versioned symbols.

I did this quite some time ago.  Don't know whether it's to the level
you want but it's documented.

> It's impossible for third parties to adjudicate them, because nobody
> knows what is supposed to happen.  So I think that arguing over the
> patch is putting the cart before the horse.

Not really.  What you see HJ trying to do is extending the versioning
handling in areas which it was not used before.  If you feel that
already the existing implementation is problematic you should be
completely opposed to any further extensions given there are other
solutions for the issues which motivated these changes.

-- 
---------------.                          ,-.   1325 Chesapeake Terrace
Ulrich Drepper  \    ,-------------------'   \  Sunnyvale, CA 94089 USA
Red Hat          `--' drepper at redhat.com   `------------------------

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]