NetBSD: fixed issues with cpuinfo and pthread_setname_np (thanks, Thomas!).
Fixes Bugzilla #3176.
parent
ce0f90ffb9
commit
696cd7975c
|
@ -735,7 +735,7 @@ SDL_GetSystemRAM(void)
|
||||||
#endif
|
#endif
|
||||||
#ifdef HAVE_SYSCTLBYNAME
|
#ifdef HAVE_SYSCTLBYNAME
|
||||||
if (SDL_SystemRAM <= 0) {
|
if (SDL_SystemRAM <= 0) {
|
||||||
#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
|
#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__NetBSD__)
|
||||||
#ifdef HW_REALMEM
|
#ifdef HW_REALMEM
|
||||||
int mib[2] = {CTL_HW, HW_REALMEM};
|
int mib[2] = {CTL_HW, HW_REALMEM};
|
||||||
#else
|
#else
|
||||||
|
|
|
@ -143,7 +143,11 @@ SDL_SYS_SetupThread(const char *name)
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
#elif HAVE_PTHREAD_SETNAME_NP
|
#elif HAVE_PTHREAD_SETNAME_NP
|
||||||
|
#if defined(__NETBSD__)
|
||||||
|
pthread_setname_np(pthread_self(), "%s", name);
|
||||||
|
#else
|
||||||
pthread_setname_np(pthread_self(), name);
|
pthread_setname_np(pthread_self(), name);
|
||||||
|
#endif
|
||||||
#elif HAVE_PTHREAD_SET_NAME_NP
|
#elif HAVE_PTHREAD_SET_NAME_NP
|
||||||
pthread_set_name_np(pthread_self(), name);
|
pthread_set_name_np(pthread_self(), name);
|
||||||
#elif defined(__HAIKU__)
|
#elif defined(__HAIKU__)
|
||||||
|
|
Loading…
Reference in New Issue