Mercurial > hg > octave-lojdl > gnulib-hg
view modules/lock @ 17422:08883714ab3e
regex: adapt to locking regime instead of depending on pthread
Instead of depending on pthread, adapt to whatever thread
modules are in use. Problem reported by Ludovic Courtès in
<http://lists.gnu.org/archive/html/bug-gnulib/2013-05/msg00082.html>
and by Mats Erik Andersson in
<http://lists.gnu.org/archive/html/bug-gnulib/2013-05/msg00100.html>.
* lib/regex_internal.h (lock_define, lock_init, lock_fini):
Support either the 'lock' module, or the 'pthread' module, or
no module.
(lock_lock, lock_unlock): New macros.
* lib/regexec.c (regexec, re_search_stub): Use the new macros.
* modules/lock, modules/pthread (configure.ac): Add module indicator.
* modules/regex (Depends-on): Remove pthread.
author | Paul Eggert <eggert@cs.ucla.edu> |
---|---|
date | Wed, 29 May 2013 10:24:17 -0700 |
parents | 984531f1792d |
children |
line wrap: on
line source
Description: Locking in multithreaded situations. Files: lib/glthread/lock.h lib/glthread/lock.c m4/lock.m4 Depends-on: threadlib configure.ac: gl_LOCK gl_MODULE_INDICATOR([lock]) Makefile.am: lib_SOURCES += glthread/lock.h glthread/lock.c Include: "glthread/lock.h" Link: $(LTLIBTHREAD) when linking with libtool, $(LIBTHREAD) otherwise License: LGPLv2+ Maintainer: Bruno Haible