Mercurial > mplayer.hg
changeset 36358:d53606fdb693
Autodetect if pthread_cancel is available.
Necessary for properly working reception of streams
via UDP, e.g. via FFmpeg's RTSP-over-UDP implementation.
author | reimar |
---|---|
date | Sat, 21 Sep 2013 16:39:24 +0000 |
parents | 7dca7d4d4e54 |
children | dba1b5aa72c1 |
files | configure |
diffstat | 1 files changed, 17 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/configure Sat Sep 21 15:55:28 2013 +0000 +++ b/configure Sat Sep 21 16:39:24 2013 +0000 @@ -3843,6 +3843,22 @@ fi echores "$_pthreads" +pthread_cancel=no +if test "$_pthreads" = yes ; then + echocheck "pthread_cancel" +cat > $TMPC << EOF +#include <pthread.h> +int main(void) { pthread_t t; return pthread_cancel(t); } +EOF + cc_check $ld_pthread && pthread_cancel=yes + echores "$pthread_cancel" +fi +if test "$pthread_cancel" = yes ; then + def_pthread_cancel='#define HAVE_PTHREAD_CANCEL 1' +else + def_pthread_cancel='#define HAVE_PTHREAD_CANCEL 0' +fi + if cygwin ; then if test "$_pthreads" = yes ; then def_pthread_cache="#define PTHREAD_CACHE 1" @@ -9038,6 +9054,7 @@ $def_os2threads $def_pic $def_pthreads +$def_pthread_cancel $def_socklen_t $def_struct_addrinfo $def_struct_ipv6_mreq @@ -9124,7 +9141,6 @@ #define HAVE_MIPSDSPR1 0 #define HAVE_MIPSFPU 0 #define HAVE_MM_EMPTY 0 -#define HAVE_PTHREAD_CANCEL 0 #define HAVE_PPC4XX 0 #define HAVE_RDTSC 0 #define HAVE_STRERROR_R 0