[MacPorts] #59772: python38: fails on Leopard: Undefined symbols: :info:build "_pthread_threadid_np"
MacPorts
noreply at macports.org
Fri Nov 29 01:26:29 UTC 2019
#59772: python38: fails on Leopard: Undefined symbols: :info:build
"_pthread_threadid_np"
---------------------------+----------------------
Reporter: kencu | Owner: jmroot
Type: defect | Status: assigned
Priority: Normal | Milestone:
Component: ports | Version:
Keywords: leopard tiger | Port: python38
---------------------------+----------------------
{{{
:info:build Undefined symbols:
:info:build "_pthread_threadid_np", referenced from:
:info:build _PyThread_get_thread_native_id in
libpython3.8.a(thread.o)
}}}
that symbol exists on SnowLeopard and later. In llvm-9.0, I handled it
like this:
{{{
diff --git llvm_master/lib/Support/Unix/Threading.inc
macports_master/lib/Support/Unix/Threading.inc
index ed9a9656305..e8f9a13860f 100644
--- llvm_master/lib/Support/Unix/Threading.inc
+++ macports_master/lib/Support/Unix/Threading.inc
@@ -14,6 +14,7 @@
#include "llvm/ADT/Twine.h"
#if defined(__APPLE__)
+#include <Availability.h>
#include <mach/mach_init.h>
#include <mach/mach_port.h>
#endif
@@ -153,8 +154,10 @@ void llvm::set_thread_name(const Twine &Name) {
::pthread_setname_np(::pthread_self(), "%s",
const_cast<char *>(NameStr.data()));
#elif defined(__APPLE__)
+#if __MAC_OS_X_VERSION_MAX_ALLOWED >= 1060
::pthread_setname_np(NameStr.data());
#endif
+#endif
}
void llvm::get_thread_name(SmallVectorImpl<char> &Name) {
--
}}}
--
Ticket URL: <https://trac.macports.org/ticket/59772>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list