rra@stanford.edu writes:
(...) libtool does not pass -pthread through, -lpthread seems to work though.
(...)
OL_PTHREAD_TRY([-lpthread], [ol_cv_pthread_lpthread]) OL_PTHREAD_TRY([-pthread], [ol_cv_pthread_pthread])
(...)
This may be correct for Debian, but looks dubious as a general patch. On other systems that have a thread compiler switch it may be wrong to link the thread library "by hand" and omit the compiler switch, otherwise what's the compiler switch for?
Their comments seem to indicate libtool is a better place to fix it. An OpenLDAP patch would likely need some 'if <debian>' code.
(Note, I do not know Debian, nor specifics about differing Linux variants.)