[PATCH] ld: do not export __dso_handle for PE

Yaakov Selkowitz yselkowi@redhat.com
Mon Aug 11 19:23:00 GMT 2014


	* pe-dll.c (autofilter_symbollist_i386): Add __dso_handle.
---
This is necessary for adding __cxa_atexit support for Cygwin in GCC
without exporting __dso_handle from every DLL.  (On ELF platforms,
__dso_handle is marked hidden visibility, but we don't have support
for that yet on PE platforms.)

 ld/pe-dll.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/ld/pe-dll.c b/ld/pe-dll.c
index d38f30d..61d8fa5 100644
--- a/ld/pe-dll.c
+++ b/ld/pe-dll.c
@@ -235,6 +235,7 @@ static const autofilter_entry_type autofilter_symbollist_i386[] =
   { STRING_COMMA_LEN ("_impure_ptr") },
   { STRING_COMMA_LEN ("_fmode") },
   { STRING_COMMA_LEN ("environ") },
+  { STRING_COMMA_LEN ("__dso_handle") },
   { NULL, 0 }
 };
 
-- 
1.8.5.5



More information about the Binutils mailing list