"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "build/apr_threads.m4" between
apr-1.6.5.tar.bz2 and apr-1.7.0.tar.bz2

About: APR (Apache Portable Runtime) project offers software libraries that provide a predictable and consistent interface to underlying platform-specific implementations (APR core library).

apr_threads.m4  (apr-1.6.5.tar.bz2):apr_threads.m4  (apr-1.7.0.tar.bz2)
skipping to change at line 261 skipping to change at line 261
int main(int argc, char **argv) int main(int argc, char **argv)
{ {
pthread_mutex_t mutex; pthread_mutex_t mutex;
pthread_mutexattr_t attr; pthread_mutexattr_t attr;
if (pthread_mutexattr_init(&attr)) if (pthread_mutexattr_init(&attr))
exit(1); exit(1);
if (pthread_mutexattr_setpshared(&attr, PTHREAD_PROCESS_SHARED)) if (pthread_mutexattr_setpshared(&attr, PTHREAD_PROCESS_SHARED))
exit(2); exit(2);
if (pthread_mutexattr_setrobust(&attr, PTHREAD_MUTEX_ROBUST))
exit(3);
if (pthread_mutexattr_setprotocol(&attr, PTHREAD_PRIO_INHERIT))
exit(4);
if (pthread_mutex_init(&mutex, &attr))
exit(5);
if (pthread_mutexattr_destroy(&attr))
exit(6);
if (pthread_mutex_destroy(&mutex))
exit(7);
exit(0);
}], [apr_cv_mutex_robust_shared=yes], [
AC_TRY_RUN([
#include <sys/types.h>
#include <pthread.h>
#include <stdlib.h>
int main(int argc, char **argv)
{
pthread_mutex_t mutex;
pthread_mutexattr_t attr;
if (pthread_mutexattr_init(&attr))
exit(1);
if (pthread_mutexattr_setpshared(&attr, PTHREAD_PROCESS_SHARED))
exit(2);
if (pthread_mutexattr_setrobust_np(&attr, PTHREAD_MUTEX_ROBUST_NP)) if (pthread_mutexattr_setrobust_np(&attr, PTHREAD_MUTEX_ROBUST_NP))
exit(3); exit(3);
if (pthread_mutexattr_setprotocol(&attr, PTHREAD_PRIO_INHERIT)) if (pthread_mutexattr_setprotocol(&attr, PTHREAD_PRIO_INHERIT))
exit(4); exit(4);
if (pthread_mutex_init(&mutex, &attr)) if (pthread_mutex_init(&mutex, &attr))
exit(5); exit(5);
if (pthread_mutexattr_destroy(&attr)) if (pthread_mutexattr_destroy(&attr))
exit(6); exit(6);
if (pthread_mutex_destroy(&mutex)) if (pthread_mutex_destroy(&mutex))
exit(7); exit(7);
exit(0); exit(0);
}], [apr_cv_mutex_robust_shared=yes], [apr_cv_mutex_robust_shared=no])]) }], [apr_cv_mutex_robust_shared=np], [apr_cv_mutex_robust_shared=no])
])])
if test "$apr_cv_mutex_robust_shared" = "yes"; then if test "$apr_cv_mutex_robust_shared" = "yes"; then
AC_DEFINE([HAVE_PTHREAD_MUTEX_ROBUST], 1, AC_DEFINE([HAVE_PTHREAD_MUTEX_ROBUST], 1,
[Define if cross-process robust mutexes are available]) [Define if cross-process robust mutexes are available])
elif test "$apr_cv_mutex_robust_shared" = "np"; then
AC_DEFINE([HAVE_PTHREAD_MUTEX_ROBUST_NP], 1,
[Define if non-posix/portable cross-process robust mutexes are avai
lable])
fi fi
]) ])
 End of changes. 3 change blocks. 
1 lines changed or deleted 33 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)