It is local for that one particular file and should not be used by or
shared to any other file. So when it is possible, mark that variable as
static. This is currently possible only for non-msvc builds when using
__attribute__((used)).
---
mingw-w64-libraries/winpthreads/src/thread.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/mingw-w64-libraries/winpthreads/src/thread.c
b/mingw-w64-libraries/winpthreads/src/thread.c
index ce1fa076d027..73d4329c19ad 100644
--- a/mingw-w64-libraries/winpthreads/src/thread.c
+++ b/mingw-w64-libraries/winpthreads/src/thread.c
@@ -545,7 +545,7 @@ __dyn_tls_pthread (HANDLE hDllHandle, DWORD dwReason,
LPVOID lpreserved)
#endif
#if defined(__GNUC__)
-__attribute__((used))
+static __attribute__((used))
#endif
WINPTHREADS_ATTRIBUTE((WINPTHREADS_SECTION(".CRT$XLF")))
const PIMAGE_TLS_CALLBACK __xl_f = __dyn_tls_pthread;
--
2.20.1
_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public