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]
Other format: [Raw text]

RE: ld-auto-import documentation update



> -----Original Message-----
> From: binutils-owner@sources.redhat.com
> [mailto:binutils-owner@sources.redhat.com]On Behalf Of Christopher
> Faylor
> Sent: Sunday, December 22, 2002 11:05 PM
> To: Binutils
> Subject: Re: ld-auto-import documentation update
>
>
> On Sun, Dec 22, 2002 at 02:29:15PM +0100, Ralf Habacker wrote:
> >Charles Wilson writes:
> >
> >+2. Sometimes, it is useful to rename exports.  For instance, the cygwin
> >+kernel does this regularly: a symbol @samp{_foo} will be exported as
> >+@samp{_foo}, but also as @samp{foo} by using special directives in the
> >+DEF file when creating the import library.  This ability is not
> >+present without import libs.
> >
> >This isn't true. The gcc manual in
> >http://gcc.gnu.org/onlinedocs/gcc-3.2/gcc/Function-Attributes.html#Fu
nction%20At
> >tributes says:
>
> It's true for the way cygwin does it.  We don't necessarily export the
> function using the same name as the global, i.e., a function declared
> 'foo' may be exported as 'cygwin_foo' and we don't want 'foo' exported
> at all.
>
This is another topic as Charles have told about and you'r right, for this there
isn't another way, so DEF files are necessary and the ld documentation has to be
updated.

But this does not depends on using import libraries. Renaming symbols with a def
file affect the dll too and could be used without import library.

> Are there other ways to accomplish this by standing on our heads and
> using defines?  Probably?  Do we want to change Cygwin to use these
> other methods?  No.
>
Ralf





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