diff options
author | Bruno Haible <bruno@clisp.org> | 2019-06-20 04:02:52 +0200 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2019-06-20 04:02:52 +0200 |
commit | 145e16d89f89e000ff6a4f1892b17e34560f9e96 (patch) | |
tree | 069f90958e8fb245aa28056b5d266a2827042aa6 /modules/pthread_mutex_timedlock | |
parent | 79c2545308000d2120009a76bea4f36f06f16b1b (diff) | |
download | gnulib-145e16d89f89e000ff6a4f1892b17e34560f9e96.tar.gz |
pthread_mutex_timedlock: New module.
* lib/pthread.in.h (pthread_mutex_timedlock): New dummy function and
new declaration.
* lib/pthread_mutex_timedlock.c: New file.
* m4/pthread_mutex_timedlock.m4: New file.
* m4/pthread.m4 (gl_PTHREAD_CHECK): Don't call AC_LIBOBJ here. Test
whether pthread_mutex_timedlock is declared.
(gl_PTHREAD_MODULE_INDICATOR): New macro.
(gl_PTHREAD_DEFAULTS): Initialize GNULIB_PTHREAD_MUTEX_TIMEDLOCK,
HAVE_PTHREAD_MUTEX_TIMEDLOCK.
* modules/pthread (configure.ac): Call AC_LIBOBJ here.
(Makefile.am): Substitute GNULIB_PTHREAD_MUTEX_TIMEDLOCK,
HAVE_PTHREAD_MUTEX_TIMEDLOCK.
* modules/pthread_mutex_timedlock: New file.
* doc/posix-functions/pthread_mutex_timedlock.texi: Mention the new
module.
Diffstat (limited to 'modules/pthread_mutex_timedlock')
-rw-r--r-- | modules/pthread_mutex_timedlock | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/modules/pthread_mutex_timedlock b/modules/pthread_mutex_timedlock new file mode 100644 index 0000000000..2ae39f497e --- /dev/null +++ b/modules/pthread_mutex_timedlock @@ -0,0 +1,28 @@ +Description: +Lock a mutex, abandoning after a certain time. + +Files: +lib/pthread_mutex_timedlock.c +m4/pthread_mutex_timedlock.m4 + +Depends-on: +pthread +nanosleep [test $HAVE_PTHREAD_T = 1 && test $HAVE_PTHREAD_MUTEX_TIMEDLOCK = 0] + +configure.ac: +gl_FUNC_PTHREAD_MUTEX_TIMEDLOCK +if test $HAVE_PTHREAD_T = 1 && test $HAVE_PTHREAD_MUTEX_TIMEDLOCK = 0; then + AC_LIBOBJ([pthread_mutex_timedlock]) +fi +gl_PTHREAD_MODULE_INDICATOR([pthread_mutex_timedlock]) + +Makefile.am: + +Include: +<pthread.h> + +License: +LGPLv2+ + +Maintainer: +all |