You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On SLES 11 file src/lib/ares__threads.c does not compile for version 1.23.0:
ares__threads.c: In function 'ares__thread_mutex_create':
ares__threads.c:94: warning: implicit declaration of function 'pthread_mutexattr_settype'
ares__threads.c:94: warning: nested extern declaration of 'pthread_mutexattr_settype'
ares__threads.c:94: error: 'PTHREAD_MUTEX_RECURSIVE' undeclared (first use in this function)
ares__threads.c:94: error: (Each undeclared identifier is reported only once
ares__threads.c:94: error: for each function it appears in.)
Although pthread.h is included, it seems for such old Linux version one needs to either define _GNU_SOURCE or _XOPEN_SOURCE 700. For me it was sufficient to do that in ares__threads.c.
The text was updated successfully, but these errors were encountered:
I assuming you're using autotools and not cmake then? I'm showing with CMake at least _GNU_SOURCE is defined. And does it really need _XOPEN_SOURCE=700? Looks like we're setting 600.
On SLES 11 file src/lib/ares__threads.c does not compile for version 1.23.0:
ares__threads.c: In function 'ares__thread_mutex_create':
ares__threads.c:94: warning: implicit declaration of function 'pthread_mutexattr_settype'
ares__threads.c:94: warning: nested extern declaration of 'pthread_mutexattr_settype'
ares__threads.c:94: error: 'PTHREAD_MUTEX_RECURSIVE' undeclared (first use in this function)
ares__threads.c:94: error: (Each undeclared identifier is reported only once
ares__threads.c:94: error: for each function it appears in.)
Although pthread.h is included, it seems for such old Linux version one needs to either define _GNU_SOURCE or _XOPEN_SOURCE 700. For me it was sufficient to do that in ares__threads.c.
The text was updated successfully, but these errors were encountered: