diff options
author | Bruno Haible <bruno@clisp.org> | 2023-03-25 20:54:29 +0100 |
---|---|---|
committer | Bruno Haible <bruno@clisp.org> | 2023-03-25 20:58:44 +0100 |
commit | 53370c23642eb6256dafd7b6abca8cc93581b7c2 (patch) | |
tree | e8fedc5095c2d787898557a2e699a52e0d812b77 /m4/threads_h.m4 | |
parent | eb8da36e0b3a667444707fb7d0182e54bb2130d0 (diff) | |
download | gnulib-53370c23642eb6256dafd7b6abca8cc93581b7c2.tar.gz |
call_once: New module, separate from mtx.
* lib/threads.in.h (call_once): Declare as part of module 'call_once',
not module 'mtx'.
* lib/call_once.c: New file, extracted from lib/mtx.c.
* lib/mtx.c (call_once): Remove function.
* m4/threads_h.m4 (gl_THREADS_H_REQUIRE_DEFAULTS): Inititalize
GNULIB_CALL_ONCE.
* modules/threads-h (Makefile.am): Substitute GNULIB_CALL_ONCE.
* modules/call_once: New file, based on modules/mtx.
* modules/threads (Depends-on): Add call_once.
* tests/test-threads-c++.cc: Update accordingly.
* modules/call_once-tests: New file, based on modules/mtx-tests.
* modules/mtx-tests (Files): Remove tests/test-call_once.c.
(Makefile.am): Don't compile test-call_once.
* doc/posix-functions/call_once.texi: Document that the relevant module
is now 'call_once'.
* NEWS: Mention the change.
Diffstat (limited to 'm4/threads_h.m4')
-rw-r--r-- | m4/threads_h.m4 | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/m4/threads_h.m4 b/m4/threads_h.m4 index 77fe20d279..851490c123 100644 --- a/m4/threads_h.m4 +++ b/m4/threads_h.m4 @@ -1,4 +1,4 @@ -# threads_h.m4 serial 10 +# threads_h.m4 serial 11 dnl Copyright (C) 2019-2023 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, @@ -156,6 +156,7 @@ AC_DEFUN([gl_THREADS_MODULE_INDICATOR], AC_DEFUN([gl_THREADS_H_REQUIRE_DEFAULTS], [ m4_defun(GL_MODULE_INDICATOR_PREFIX[_THREADS_H_MODULE_INDICATOR_DEFAULTS], [ + gl_MODULE_INDICATOR_INIT_VARIABLE([GNULIB_CALL_ONCE]) gl_MODULE_INDICATOR_INIT_VARIABLE([GNULIB_CND]) gl_MODULE_INDICATOR_INIT_VARIABLE([GNULIB_MTX]) gl_MODULE_INDICATOR_INIT_VARIABLE([GNULIB_THRD]) |