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] | |
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
void __f () { /* do something */; }
void f () __attribute__ ((weak, alias ("__f")));
declares f to be a weak alias for __f. In C++, the mangled name for the target
must be used.
And it actually works as advertised on cygwin? Cool. Thanks for the
correction. (I knew you could do this on ELF, but windows? Neato.)| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |