From 3d9ba341f0db012142a014b350edeffc84b20eff Mon Sep 17 00:00:00 2001 From: Phenom Date: Fri, 5 Mar 2021 17:39:12 +0100 Subject: [PATCH] Fix Windows 64b G++ under MSys2 compil. --- libretroshare/src/util/rsthreads.cc | 4 +++- plugins/Common/retroshare_plugin.pri | 2 ++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/libretroshare/src/util/rsthreads.cc b/libretroshare/src/util/rsthreads.cc index e931c8f1f..035ad214a 100644 --- a/libretroshare/src/util/rsthreads.cc +++ b/libretroshare/src/util/rsthreads.cc @@ -43,11 +43,13 @@ int RS_pthread_setname_np(pthread_t /*__target_thread*/, const char *__buf) { return pthread_setname_np(__buf); } #else +#ifndef __WIN64__ int __attribute__((weak)) pthread_setname_np(pthread_t __target_thread, const char *__buf) ; +#endif //__WIN64__ int RS_pthread_setname_np(pthread_t __target_thread, const char *__buf) { return pthread_setname_np(__target_thread, __buf); } -#endif +#endif //__APPLE__ /******* diff --git a/plugins/Common/retroshare_plugin.pri b/plugins/Common/retroshare_plugin.pri index 77812db81..5159aa9b1 100644 --- a/plugins/Common/retroshare_plugin.pri +++ b/plugins/Common/retroshare_plugin.pri @@ -102,6 +102,8 @@ win32 { for(lib, LIB_DIR):LIBS += -L"$$lib" for(bin, BIN_DIR):LIBS += -L"$$bin" LIBS += -lpthread + + QMAKE_LFLAGS += -Wl,--end-group } macx {