[PATCH,PE-COFF,PR11603] Allow ld to export symbols containing dots from DLLs.

Dave Korn dave.korn.cygwin@gmail.com
Mon May 17 16:51:00 GMT 2010


On 17/05/2010 17:30, Doug Semler wrote:
> On Mon, May 17, 2010 at 12:46 PM, Dave Korn <dave.korn.cygwin@gmail.com> wrote:
>> On 17/05/2010 17:15, Doug Semler wrote:
>>> Dave I did a test on x86_64-w64 and it's not exporting the data
>>> symbols from the DLLs.  I'm not sure whether it's another underscoring
>>> issue or a PEBKAC error but I'm investigating...i'll know more in a
>>> little while...
>>  Simple test case, by any chance?
> 
> Yeah.  Looks like gcc (4.5) isn't generating a correct .drective if
> there are both thread local data and exported functions in the same
> module.  If I take the __thread off, it exports both.  If I get rid of
> the function definition it exports i properly.

  Urgh.  Yes, this looks like a real GCC bug; it's not generating any export
directive for the tls var at all.  When there's no other export directives
(i.e. without the function) auto-export kicks in, but that behaviour gets
suppressed in the presence of any explicit exports.

  Confirmed for both 4.6.0 and 4.3.4.  Sigh, I'll go debug GCC and figure out
what's up.

    cheers,
      DaveK



More information about the Binutils mailing list