| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
Reported by Pierre Labastie <pierre.labastie@neuf.fr> in
<https://lists.gnu.org/archive/html/bug-gnulib/2023-04/msg00220.html>.
* m4/stdlib_h.m4 (gl_STDLIB_H): Provide a 4th argument to AC_RUN_IFELSE.
|
|
|
|
|
|
|
|
|
|
|
| |
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize
HAVE_DECL_PROGRAM_INVOCATION_NAME.
* m4/getprogname.m4 (gl_FUNC_GETPROGNAME): Require gl_STDLIB_H_DEFAULTS
and gl_USE_SYSTEM_EXTENSIONS. Set HAVE_DECL_PROGRAM_INVOCATION_NAME.
* modules/stdlib (Makefile.am): Substitute
HAVE_DECL_PROGRAM_INVOCATION_NAME.
* lib/stdlib.in.h (getprogname): Test HAVE_DECL_PROGRAM_INVOCATION_NAME
as an Autoconf variable.
|
|
|
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h (gl_MB_CUR_MAX): New function.
(MB_CUR_MAX, GNULIB_defined_MB_CUR_MAX): New macros.
* m4/stdlib_h.m4 (gl_STDLIB_H): Test whether MB_CUR_MAX is correct.
(gl_STDLIB_H_DEFAULTS): Initialize REPLACE_MB_CUR_MAX.
* modules/stdlib (Files): Add m4/locale-fr.m4.
(Makefile.am): Substitute REPLACE_MB_CUR_MAX.
* doc/posix-headers/stdlib.texi: Mention the Solaris 10 bug.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h (mbstowcs): New declaration.
* lib/mbstowcs.c: New file, based on lib/mbstoc32s.c.
* m4/mbstowcs.m4: New file.
* m4/stdlib_h.m4 (gl_STDLIB_H): Test whether mbstowcs is declared.
(gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize GNULIB_MBSTOWCS.
(gl_STDLIB_H_DEFAULTS): Initialize REPLACE_MBSTOWCS.
* modules/stdlib (Makefile.am): Substitute GNULIB_MBSTOWCS,
REPLACE_MBSTOWCS.
* modules/mbstowcs: New file.
* tests/test-stdlib-c++.cc (mbstowcs): Check signature.
* doc/posix-functions/mbstowcs.texi: Mention the C locale behaviour bug
and the new module.
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h (getloadavg): Consider REPLACE_GETLOADAVG. Disable
_GL_CXXALIASWARN invocation on non-glibc systems.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_GETLOADAVG.
* modules/stdlib (Makefile.am): Substitute REPLACE_GETLOADAVG.
* m4/getloadavg.m4 (gl_GETLOADAVG): Conditionally set
REPLACE_GETLOADAVG.
* modules/getloadavg (Depends-on, configure.ac): Consider
REPLACE_GETLOADAVG.
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h (getsubopt): Consider REPLACE_GETSUBOPT. Disable
_GL_CXXALIASWARN invocation on non-glibc systems.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_GETSUBOPT.
* modules/stdlib (Makefile.am): Substitute REPLACE_GETSUBOPT.
* m4/getsubopt.m4 (gl_FUNC_GETSUBOPT): Conditionally set
REPLACE_GETSUBOPT.
* modules/getsubopt (Depends-on, configure.ac): Consider
REPLACE_GETSUBOPT.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h (mkostemp): Consider REPLACE_MKOSTEMP. Disable
_GL_CXXALIASWARN invocation on non-glibc systems.
(mkostemps): Consider REPLACE_MKOSTEMPS. Disable _GL_CXXALIASWARN
invocation on non-glibc systems.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_MKOSTEMP,
REPLACE_MKOSTEMPS.
* modules/stdlib (Makefile.am): Substitute REPLACE_MKOSTEMP,
REPLACE_MKOSTEMPS.
* m4/mkostemp.m4 (gl_FUNC_MKOSTEMP): Conditionally set REPLACE_MKOSTEMP.
* modules/mkostemp (Depends-on, configure.ac): Consider
REPLACE_MKOSTEMP.
* m4/mkostemps.m4 (gl_FUNC_MKOSTEMPS): Conditionally set
REPLACE_MKOSTEMPS.
* modules/mkostemps (Depends-on, configure.ac): Consider
REPLACE_MKOSTEMPS.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h (_Exit): Consider REPLACE__EXIT. Disable
_GL_CXXALIASWARN invocation on non-glibc systems.
(getprogname): Consider REPLACE_GETPROGNAME. Disable _GL_CXXALIASWARN
invocation on non-glibc systems.
(posix_openpt): Consider REPLACE_POSIX_OPENPT. Disable _GL_CXXALIASWARN
invocation on non-glibc systems.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE__EXIT,
REPLACE_GETPROGNAME, REPLACE_POSIX_OPENPT.
* modules/stdlib (Makefile.am): Substitute REPLACE__EXIT,
REPLACE_GETPROGNAME, REPLACE_POSIX_OPENPT.
* m4/_Exit.m4 (gl_FUNC__EXIT): Conditionally set REPLACE__EXIT.
* modules/_Exit (configure.ac): Consider REPLACE__EXIT.
* m4/getprogname.m4 (gl_FUNC_GETPROGNAME): Conditionally set
REPLACE_GETPROGNAME.
* modules/getprogname (configure.ac): Consider REPLACE_GETPROGNAME.
* m4/posix_openpt.m4 (gl_FUNC_POSIX_OPENPT): Conditionally set
REPLACE_POSIX_OPENPT.
* modules/posix_openpt (configure.ac): Consider REPLACE_POSIX_OPENPT.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h (getprogname): New declaration.
* lib/getprogname.h: Add deprecation warning.
(getprogname): Remove declaration.
* lib/getprogname.c: Include <stdlib.h> instead of getprogname.h.
* m4/stdlib_h.m4 (gl_STDLIB_H): Test whether getprogname is declared.
(gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize GNULIB_GETPROGNAME.
(gl_STDLIB_H_DEFAULTS): Initialize HAVE_GETPROGNAME.
* m4/getprogname.m4 (gl_PREREQ_GETPROGNAME): New macro, extracted from
gl_FUNC_GETPROGNAME. Set HAVE_GETPROGNAME.
(gl_FUNC_GETPROGNAME): Remove code that was moved to
gl_PREREQ_GETPROGNAME.
* modules/stdlib (Makefile.am): Substitute GNULIB_GETPROGNAME and
HAVE_GETPROGNAME.
* modules/getprogname (Depends-on): Add stdlib.
(configure.ac): Define a module indicator. Invoke gl_PREREQ_GETPROGNAME.
(Makefile.am): Don't compile getprogname.c if not needed.
(Include): List <stdlib.h> instead of getprogname.h.
* tests/test-getprogname.c: Include <stdlib.h> instead of getprogname.h.
* NEWS: Mention the change.
* lib/argmatch.c: Don't include getprogname.h.
* lib/c-stack.c: Likewise.
* lib/error.c: Likewise.
* lib/git-merge-changelog.c: Likewise.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* m4/realloc.m4 (gl_FUNC_REALLOC_GNU): Set
REPLACE_REALLOC_FOR_REALLOC_GNU instead of REPLACE_REALLOC.
(gl_FUNC_REALLOC_POSIX): Set REPLACE_REALLOC_FOR_REALLOC_POSIX instead
of REPLACE_REALLOC.
* m4/stdlib_h.m4 (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize the
realloc-gnu module indicator.
(gl_STDLIB_H_DEFAULTS): Initialize REPLACE_REALLOC_FOR_REALLOC_GNU,
REPLACE_REALLOC_FOR_REALLOC_POSIX, not REPLACE_REALLOC.
* modules/stdlib (Makefile.am): Substitute GNULIB_REALLOC_GNU,
REPLACE_REALLOC_FOR_REALLOC_GNU, REPLACE_REALLOC_FOR_REALLOC_POSIX, not
REPLACE_REALLOC.
* modules/realloc-posix (Depends-on, configure.ac): Test
REPLACE_REALLOC_FOR_REALLOC_POSIX instead of REPLACE_REALLOC.
* modules/realloc-gnu (Comment): Remove section.
(Depends-on): Add free-posix, malloc-gnu, xalloc-oversized.
(configure.ac): Test REPLACE_REALLOC_FOR_REALLOC_GNU instead of
REPLACE_REALLOC. Set a module indicator.
* lib/stdlib.in.h (realloc): Test REPLACE_REALLOC_FOR_REALLOC_POSIX,
REPLACE_REALLOC_FOR_REALLOC_GNU, and the respective module indicators
instead of just REPLACE_REALLOC.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* m4/calloc.m4 (gl_FUNC_CALLOC_GNU): Set REPLACE_CALLOC_FOR_CALLOC_GNU
instead of REPLACE_CALLOC.
(gl_FUNC_CALLOC_POSIX): Set REPLACE_CALLOC_FOR_CALLOC_POSIX instead of
REPLACE_CALLOC.
* m4/stdlib_h.m4 (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize the
calloc-gnu module indicator.
(gl_STDLIB_H_DEFAULTS): Initialize REPLACE_CALLOC_FOR_CALLOC_GNU,
REPLACE_CALLOC_FOR_CALLOC_POSIX, not REPLACE_CALLOC.
* modules/stdlib (Makefile.am): Substitute GNULIB_CALLOC_GNU,
REPLACE_CALLOC_FOR_CALLOC_GNU, REPLACE_CALLOC_FOR_CALLOC_POSIX, not
REPLACE_CALLOC.
* modules/calloc-posix (Depends-on, configure.ac): Test
REPLACE_CALLOC_FOR_CALLOC_POSIX instead of REPLACE_CALLOC.
* modules/calloc-gnu (Depends-on): Add xalloc-oversized.
(configure.ac): Test REPLACE_CALLOC_FOR_CALLOC_GNU instead of
REPLACE_CALLOC. Set a module indicator.
* lib/stdlib.in.h (calloc): Test REPLACE_CALLOC_FOR_CALLOC_POSIX,
REPLACE_CALLOC_FOR_CALLOC_GNU, and the respective module indicators
instead of just REPLACE_CALLOC.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* m4/malloc.m4 (gl_FUNC_MALLOC_GNU): Set REPLACE_MALLOC_FOR_MALLOC_GNU
instead of REPLACE_MALLOC.
(gl_FUNC_MALLOC_PTRDIFF, gl_FUNC_MALLOC_POSIX): Set
REPLACE_MALLOC_FOR_MALLOC_POSIX instead of REPLACE_MALLOC.
* m4/calloc.m4 (gl_FUNC_CALLOC_POSIX): Test
REPLACE_MALLOC_FOR_MALLOC_POSIX instead of REPLACE_MALLOC.
* m4/realloc.m4 (gl_FUNC_REALLOC_POSIX): Likewise.
* m4/stdlib_h.m4 (gl_STDLIB_H_REQUIRE_DEFAULTS): Initialize the
malloc-gnu module indicator.
(gl_STDLIB_H_DEFAULTS): Initialize REPLACE_MALLOC_FOR_MALLOC_GNU,
REPLACE_MALLOC_FOR_MALLOC_POSIX, not REPLACE_MALLOC.
* modules/stdlib (Makefile.am): Substitute GNULIB_MALLOC_GNU,
REPLACE_MALLOC_FOR_MALLOC_GNU, REPLACE_MALLOC_FOR_MALLOC_POSIX, not
REPLACE_MALLOC.
* modules/malloc-posix (Depends-on, configure.ac): Test
REPLACE_MALLOC_FOR_MALLOC_POSIX instead of REPLACE_MALLOC.
* modules/malloc-gnu (Comment): Remove section.
(Depends-on): Add xalloc-oversized.
(configure.ac): Test REPLACE_MALLOC_FOR_MALLOC_GNU instead of
REPLACE_MALLOC. Set a module indicator.
* lib/stdlib.in.h (malloc): Test REPLACE_MALLOC_FOR_MALLOC_POSIX,
REPLACE_MALLOC_FOR_MALLOC_GNU, and the respective module indicators
instead of just REPLACE_MALLOC.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* doc/glibc-functions/reallocarray.texi (reallocarray):
Mention ptrdiff_t overflow.
* lib/reallocarray.c (reallocarray): Reindent as per usual GNU.
* lib/stdlib.in.h (reallocarray): Allow reallocarray to be replaced.
* m4/reallocarray.m4 (gl_FUNC_REALLOCARRAY):
Check for ptrdiff_t overflow.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Set up REPLACE_REALLOCARRAY.
* modules/reallocarray (Files): Add malloc.m4.
(configure.ac): Also test REPLACE_REALLOCARRAY.
* modules/reallocarray-tests (Depends-on): Add stdint.
* modules/stdlib (stdlib.h): Substitute REPLACE_REALLOCARRAY.
* tests/test-reallocarray.c: Include stdint.h.
(main): Check for ptrdiff_t overflow.
|
|
|
|
|
| |
* m4/*_h.m4: Add comments regarding *_REQUIRE_DEFAULTS and
*_MODULE_INDICATOR macros.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reported by Reuben Thomas <rrt@sc3d.org> in
<https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00104.html>.
This is done by defining the Gnulib module indicator variables per
gnulib-tool invocation. So that a generated .h file is no longer
influenced by the set of modules used in other gnulib-tool invocations.
* gnulib-tool (func_compute_include_guard_prefix): Set
module_indicator_prefix.
(func_emit_lib_Makefile_am, func_emit_tests_Makefile_am): Use it to
modify $(GNULIB_*) variable references in the Automake snippets.
(func_emit_initmacro_start): Push macro definitions for GL_MACRO_PREFIX
and GL_MODULE_INDICATOR_PREFIX.
(func_emit_initmacro_end): Pop these macro definitions.
* pygnulib/GLConfig.py (GLConfig.getIncludeGuardPrefix): New method.
* pygnulib/GLEmiter.py (GLEmiter.initmacro_start): Push macro
definitions for GL_MACRO_PREFIX and GL_MODULE_INDICATOR_PREFIX.
(GLEmiter.initmacro_end): Pop these macro definitions.
(GLEmiter.lib_Makefile_am, GLEmiter.tests_Makefile_am): Use the module
indicator prefix to modify $(GNULIB_*) variable references in the
Automake snippets.
* m4/gnulib-common.m4 (gl_MODULE_INDICATOR_INIT_VARIABLE,
gl_MODULE_INDICATOR_SET_VARIABLE): Use the value of
GL_MODULE_INDICATOR_PREFIX.
* m4/arpa_inet_h.m4: Use new idiom for header files that contain
references to Gnulib module indicator variables:
- Define the main macro through AC_DEFUN_ONCE.
- Define a macro gl_*_H_REQUIRE_DEFAULTS that initializes the Gnulib
module indicator variables (each prefixed with
GL_MODULE_INDICATOR_PREFIX).
- Invoke this macro in the gl_*_MODULE_INDICATOR macro.
* m4/ctype.m4: Likewise.
* m4/dirent_h.m4: Likewise.
* m4/fcntl_h.m4: Likewise.
* m4/fnmatch_h.m4: Likewise.
* m4/glob_h.m4: Likewise.
* m4/iconv_h.m4: Likewise.
* m4/inttypes.m4: Likewise.
* m4/langinfo_h.m4: Likewise.
* m4/locale_h.m4: Likewise.
* m4/malloc_h.m4: Likewise.
* m4/math_h.m4: Likewise.
* m4/monetary_h.m4: Likewise.
* m4/netdb_h.m4: Likewise.
* m4/poll_h.m4: Likewise.
* m4/pthread_h.m4: Likewise.
* m4/pty_h.m4: Likewise.
* m4/sched_h.m4: Likewise.
* m4/search_h.m4: Likewise.
* m4/signal_h.m4: Likewise.
* m4/spawn_h.m4: Likewise.
* m4/stddef_h.m4: Likewise.
* m4/stdio_h.m4: Likewise.
* m4/stdlib_h.m4: Likewise.
* m4/string_h.m4: Likewise.
* m4/strings_h.m4: Likewise.
* m4/sys_file_h.m4: Likewise.
* m4/sys_ioctl_h.m4: Likewise.
* m4/sys_random_h.m4: Likewise.
* m4/sys_resource_h.m4: Likewise.
* m4/sys_select_h.m4: Likewise.
* m4/sys_socket_h.m4: Likewise.
* m4/sys_stat_h.m4: Likewise.
* m4/sys_time_h.m4: Likewise.
* m4/sys_times_h.m4: Likewise.
* m4/sys_types_h.m4: Likewise.
* m4/sys_uio_h.m4: Likewise.
* m4/sys_utsname_h.m4: Likewise.
* m4/sys_wait_h.m4: Likewise.
* m4/termios_h.m4: Likewise.
* m4/threads.m4: Likewise.
* m4/time_h.m4: Likewise.
* m4/uchar.m4: Likewise.
* m4/unistd_h.m4: Likewise.
* m4/utime_h.m4: Likewise.
* m4/wchar_h.m4: Likewise.
* m4/wctype_h.m4: Likewise.
* modules/arpa_inet (configure.ac): Invoke the macro
gl_*_H_REQUIRE_DEFAULTS explicitly.
* modules/ctype (configure.ac): Likewise.
* modules/dirent (configure.ac): Likewise.
* modules/fcntl-h (configure.ac): Likewise.
* modules/fnmatch-h (configure.ac): Likewise.
* modules/glob-h (configure.ac): Likewise.
* modules/iconv-h (configure.ac): Likewise.
* modules/inttypes-incomplete (configure.ac): Likewise.
* modules/langinfo (configure.ac): Likewise.
* modules/locale (configure.ac): Likewise.
* modules/malloc-h (configure.ac): Likewise.
* modules/math (configure.ac): Likewise.
* modules/monetary (configure.ac): Likewise.
* modules/netdb (configure.ac): Likewise.
* modules/poll-h (configure.ac): Likewise.
* modules/pthread-h (configure.ac): Likewise.
* modules/pty (configure.ac): Likewise.
* modules/sched (configure.ac): Likewise.
* modules/search (configure.ac): Likewise.
* modules/signal-h (configure.ac): Likewise.
* modules/spawn (configure.ac): Likewise.
* modules/stddef (configure.ac): Likewise.
* modules/stdio (configure.ac): Likewise.
* modules/stdlib (configure.ac): Likewise.
* modules/string (configure.ac): Likewise.
* modules/strings (configure.ac): Likewise.
* modules/sys_file (configure.ac): Likewise.
* modules/sys_ioctl (configure.ac): Likewise.
* modules/sys_random (configure.ac): Likewise.
* modules/sys_resource (configure.ac): Likewise.
* modules/sys_select (configure.ac): Likewise.
* modules/sys_socket (configure.ac): Likewise.
* modules/sys_stat (configure.ac): Likewise.
* modules/sys_time (configure.ac): Likewise.
* modules/sys_times (configure.ac): Likewise.
* modules/sys_types (configure.ac): Likewise.
* modules/sys_uio (configure.ac): Likewise.
* modules/sys_utsname (configure.ac): Likewise.
* modules/sys_wait (configure.ac): Likewise.
* modules/termios (configure.ac): Likewise.
* modules/threads-h (configure.ac): Likewise.
* modules/time (configure.ac): Likewise.
* modules/uchar (configure.ac): Likewise.
* modules/unistd (configure.ac): Likewise.
* modules/utime-h (configure.ac): Likewise.
* modules/wchar (configure.ac): Likewise.
* modules/wctype-h (configure.ac): Likewise.
* m4/af_alg.m4: Update after a macro name changed.
* m4/ctime.m4: Likewise.
* m4/explicit_bzero.m4: Likewise.
* m4/ffs.m4: Likewise.
* m4/ffsl.m4: Likewise.
* m4/ffsll.m4: Likewise.
* m4/flock.m4: Likewise.
* m4/fstat.m4: Likewise.
* m4/getaddrinfo.m4: Likewise.
* m4/getdomainname.m4: Likewise.
* m4/gettimeofday.m4: Likewise.
* m4/hostent.m4: Likewise.
* m4/ioctl.m4: Likewise.
* m4/localtime.m4: Likewise.
* m4/mbslen.m4: Likewise.
* m4/memchr.m4: Likewise.
* m4/memmem.m4: Likewise.
* m4/mempcpy.m4: Likewise.
* m4/memrchr.m4: Likewise.
* m4/mktime.m4: Likewise.
* m4/nanosleep.m4: Likewise.
* m4/passfd.m4: Likewise.
* m4/pselect.m4: Likewise.
* m4/rawmemchr.m4: Likewise.
* m4/select.m4: Likewise.
* m4/servent.m4: Likewise.
* m4/sigabbrev_np.m4: Likewise.
* m4/sigdescr_np.m4: Likewise.
* m4/sockpfaf.m4: Likewise.
* m4/stat.m4: Likewise.
* m4/stpcpy.m4: Likewise.
* m4/stpncpy.m4: Likewise.
* m4/strcase.m4: Likewise.
* m4/strcasestr.m4: Likewise.
* m4/strchrnul.m4: Likewise.
* m4/strdup.m4: Likewise.
* m4/strerror.m4: Likewise.
* m4/strerror_r.m4: Likewise.
* m4/strerrorname_np.m4: Likewise.
* m4/strftime-fixes.m4: Likewise.
* m4/strncat.m4: Likewise.
* m4/strndup.m4: Likewise.
* m4/strnlen.m4: Likewise.
* m4/strpbrk.m4: Likewise.
* m4/strptime.m4: Likewise.
* m4/strsep.m4: Likewise.
* m4/strsignal.m4: Likewise.
* m4/strstr.m4: Likewise.
* m4/strtok_r.m4: Likewise.
* m4/strverscmp.m4: Likewise.
* m4/time_r.m4: Likewise.
* m4/time_rz.m4: Likewise.
* m4/timegm.m4: Likewise.
* m4/timespec_get.m4: Likewise.
* m4/tzset.m4: Likewise.
* modules/accept (configure.ac): Likewise.
* modules/bind (configure.ac): Likewise.
* modules/connect (configure.ac): Likewise.
* modules/flock (configure.ac): Likewise.
* modules/getpeername (configure.ac): Likewise.
* modules/getsockname (configure.ac): Likewise.
* modules/getsockopt (configure.ac): Likewise.
* modules/listen (configure.ac): Likewise.
* modules/recv (configure.ac): Likewise.
* modules/recvfrom (configure.ac): Likewise.
* modules/send (configure.ac): Likewise.
* modules/sendto (configure.ac): Likewise.
* modules/setsockopt (configure.ac): Likewise.
* modules/shutdown (configure.ac): Likewise.
* modules/socket (configure.ac): Likewise. Use the
gl_*_H_REQUIRE_DEFAULTS macros.
* modules/nonblocking (configure.ac): Use the gl_*_H_REQUIRE_DEFAULTS
and gl_MODULE_INDICATOR_INIT_VARIABLE macros.
* modules/sigpipe (configure.ac): Likewise.
* modules/windows-stat-override (configure.ac): Likewise.
* m4/nonblocking.m4: Update a comment.
* m4/sigpipe.m4: Likewise.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* modules/gnulib-common.m4 (gl_MODULE_INDICATOR_INIT_VARIABLE): New
macro.
* m4/arpa_inet_h.m4 (gl_ARPA_INET_H_DEFAULTS): Use it.
* m4/ctype.m4 (gl_CTYPE_H_DEFAULTS): Likewise.
* m4/dirent_h.m4 (gl_DIRENT_H_DEFAULTS): Likewise.
* m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Likewise.
* m4/fnmatch_h.m4 (gl_FNMATCH_H_DEFAULTS): Likewise.
* m4/glob_h.m4 (gl_GLOB_H_DEFAULTS): Likewise.
* m4/iconv_h.m4 (gl_ICONV_H_DEFAULTS): Likewise.
* m4/inttypes.m4 (gl_INTTYPES_H_DEFAULTS): Likewise.
* m4/langinfo_h.m4 (gl_LANGINFO_H_DEFAULTS): Likewise.
* m4/locale_h.m4 (gl_LOCALE_H_DEFAULTS): Likewise.
* m4/malloc_h.m4 (gl_MALLOC_H_DEFAULTS): Likewise.
* m4/math_h.m4 (gl_MATH_H_DEFAULTS): Likewise.
* m4/monetary_h.m4 (gl_MONETARY_H_DEFAULTS): Likewise.
* m4/netdb_h.m4 (gl_NETDB_H_DEFAULTS): Likewise.
* m4/poll_h.m4 (gl_POLL_H_DEFAULTS): Likewise.
* m4/pthread_h.m4 (gl_PTHREAD_H_DEFAULTS): Likewise.
* m4/pty_h.m4 (gl_PTY_H_DEFAULTS): Likewise.
* m4/sched_h.m4 (gl_SCHED_H_DEFAULTS): Likewise.
* m4/search_h.m4 (gl_SEARCH_H_DEFAULTS): Likewise.
* m4/signal_h.m4 (gl_SIGNAL_H_DEFAULTS): Likewise.
* m4/spawn_h.m4 (gl_SPAWN_H_DEFAULTS): Likewise.
* m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Likewise.
* m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Likewise.
* m4/strings_h.m4 (gl_HEADER_STRINGS_H_DEFAULTS): Likewise.
* m4/sys_file_h.m4 (gl_HEADER_SYS_FILE_H_DEFAULTS): Likewise.
* m4/sys_ioctl_h.m4 (gl_SYS_IOCTL_H_DEFAULTS): Likewise.
* m4/sys_random_h.m4 (gl_SYS_RANDOM_H_DEFAULTS): Likewise.
* m4/sys_resource_h.m4 (gl_SYS_RESOURCE_H_DEFAULTS): Likewise.
* m4/sys_select_h.m4 (gl_SYS_SELECT_H_DEFAULTS): Likewise.
* m4/sys_socket_h.m4 (gl_SYS_SOCKET_H_DEFAULTS): Likewise.
* m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Likewise.
* m4/sys_time_h.m4 (gl_HEADER_SYS_TIME_H_DEFAULTS): Likewise.
* m4/sys_times_h.m4 (gl_SYS_TIMES_H_DEFAULTS): Likewise.
* m4/sys_utsname_h.m4 (gl_SYS_UTSNAME_H_DEFAULTS): Likewise.
* m4/sys_wait_h.m4 (gl_SYS_WAIT_H_DEFAULTS): Likewise.
* m4/termios_h.m4 (gl_TERMIOS_H_DEFAULTS): Likewise.
* m4/threads.m4 (gl_THREADS_H_DEFAULTS): Likewise.
* m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Likewise.
* m4/uchar.m4 (gl_UCHAR_H_DEFAULTS): Likewise.
* m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Likewise.
* m4/utime_h.m4 (gl_UTIME_H_DEFAULTS): Likewise.
* m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Likewise.
* m4/wctype_h.m4 (gl_WCTYPE_H_DEFAULTS): Likewise.
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h (strtoll): Override if REPLACE_STRTOLL is 1.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_STRTOLL.
* m4/strtoll.m4 (gl_FUNC_STRTOLL): Test whether strtoll works. Set
REPLACE_STRTOLL.
* modules/stdlib (Makefile.am): Substitute REPLACE_STRTOLL.
* modules/strtoll (configure.ac): Test REPLACE_STRTOLL.
* tests/test-strtoll.c (main): Add tests of hexadecimal integer syntax.
* doc/posix-functions/strtoll.texi: Mention the bug.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h (strtol): New declaration.
* m4/stdlib_h.m4 (gl_STDLIB_H): Test whether strtol is declared.
(gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOL, HAVE_STRTOL,
REPLACE_STRTOL.
* m4/strtol.m4 (gl_FUNC_STRTOL): Require gl_STDLIB_H_DEFAULTS. Test
whether strtol works. Set REPLACE_STRTOL.
* modules/stdlib (Makefile.am): Substitute GNULIB_STRTOL, HAVE_STRTOL,
REPLACE_STRTOL.
* modules/strtol (Status, Notice): Remove.
(Depends-on): Add stdlib.
(configure.ac): Test HAVE_STRTOL and REPLACE_STRTOL. Invoke
gl_STDLIB_MODULE_INDICATOR.
* tests/test-strtol.c (main): Add tests of hexadecimal integer syntax.
* doc/posix-functions/strtol.texi: Mention the bug.
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h (strtoull): Override if REPLACE_STRTOULL is 1.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize REPLACE_STRTOULL.
* m4/strtoull.m4 (gl_FUNC_STRTOULL): Test whether strtoull works. Set
REPLACE_STRTOULL.
* modules/stdlib (Makefile.am): Substitute REPLACE_STRTOULL.
* modules/strtoull (configure.ac): Test REPLACE_STRTOULL.
* tests/test-strtoull.c (main): Add tests of hexadecimal integer syntax.
* doc/posix-functions/strtoull.texi: Mention the bug.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reported by Eric Blake <eblake@redhat.com> in
<https://lists.gnu.org/archive/html/bug-gnulib/2021-03/msg00082.html>.
* lib/stdlib.in.h (strtoul): New declaration.
* m4/stdlib_h.m4 (gl_STDLIB_H): Test whether strtoul is declared.
(gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOUL, HAVE_STRTOUL,
REPLACE_STRTOUL.
* m4/strtoul.m4 (gl_FUNC_STRTOUL): Require gl_STDLIB_H_DEFAULTS. Test
whether strtoul works. Set REPLACE_STRTOUL.
* modules/stdlib (Makefile.am): Substitute GNULIB_STRTOUL, HAVE_STRTOUL,
REPLACE_STRTOUL.
* modules/strtoul (Status, Notice): Remove.
(Depends-on): Add stdlib.
(configure.ac): Test HAVE_STRTOUL and REPLACE_STRTOUL. Invoke
gl_STDLIB_MODULE_INDICATOR.
* tests/test-strtoul.c (main): Add tests of hexadecimal integer syntax.
* doc/posix-functions/strtoul.texi: Mention the bug.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/fcntl.in.h (creat, open): Conditionalize each of the Windows
oldnames workarounds through a GNULIB_MDA_<func> symbol.
* lib/math.in.h (j0, j1, jn, y0, y1, yn): Likewise.
* lib/search.in.h (lfind, lsearch): Likewise.
* lib/stdio.in.h (fcloseall, fdopen, fileno, getw, putw, tempnam):
Likewise.
* lib/stdlib.in.h (ecvt, fcvt, gcvt, mktemp, putenv): Likewise.
* lib/string.in.h (memccpy, strdup): Likewise.
* lib/sys_stat.in.h (chmod, umask): Likewise.
* lib/time.in.h (tzset): Likewise.
* lib/unistd.in.h (access, chdir, close, dup, dup2, execl, execle,
execlp, execv, execve, execvp, execvpe, getcwd, getpid, isatty, lseek,
read, rmdir, swab, unlink, write): Likewise.
* lib/utime.in.h (utime): Likewise.
* lib/wchar.in.h (wcsdup): Likewise.
* m4/fcntl_h.m4 (gl_FCNTL_H_DEFAULTS): Initialize these
GNULIB_MDA_<func> symbols.
* m4/math_h.m4 (gl_MATH_H_DEFAULTS): Likewise.
* m4/search_h.m4 (gl_SEARCH_H_DEFAULTS): Likewise.
* m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Likewise.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Likewise.
* m4/string_h.m4 (gl_HEADER_STRING_H_DEFAULTS): Likewise.
* m4/sys_stat_h.m4 (gl_SYS_STAT_H_DEFAULTS): Likewise.
* m4/time_h.m4 (gl_HEADER_TIME_H_DEFAULTS): Likewise.
* m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Likewise.
* m4/utime_h.m4 (gl_UTIME_H_DEFAULTS): Likewise.
* m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Likewise.
* modules/fcntl-h (Makefile.am): Substitute these GNULIB_MDA_<func>
symbols.
* modules/math (Makefile.am): Likewise.
* modules/search (Makefile.am): Likewise.
* modules/stdio (Makefile.am): Likewise.
* modules/stdlib (Makefile.am): Likewise.
* modules/string (Makefile.am): Likewise.
* modules/sys_stat (Makefile.am): Likewise.
* modules/time (Makefile.am): Likewise.
* modules/unistd (Makefile.am): Likewise.
* modules/utime-h (Makefile.am): Likewise.
* modules/wchar (Makefile.am): Likewise.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* modules/free-posix: Renamed from modules/free.
(configure.ac): Update gl_STDLIB_MODULE_INDICATOR invocation.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_FREE_POSIX,
not GNULIB_FREE.
* modules/stdlib (Makefile.am): Substitute GNULIB_FREE_POSIX, not
GNULIB_FREE.
* lib/stdlib.in.h (free): Test GNULIB_FREE_POSIX, not GNULIB_FREE.
* doc/posix-functions/free.texi: Mention the module 'free-posix' and
what it does.
* NEWS: Mention that module 'free' no longer exists.
* modules/canonicalize (Depends-on): Add free-posix. Remove free.
* modules/canonicalize-lgpl (Depends-on): Likewise.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reported by Pádraig Brady <P@draigBrady.com> in
<https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00148.html>.
* lib/stdlib.in.h (free): New declaration.
* m4/stdlib_h.m4 (gl_STDLIB_H): Test whether 'free' is declared.
(gl_STDLIB_H_DEFAULTS): Initialize GNULIB_FREE, REPLACE_FREE.
* modules/stdlib (Makefile.am): Substitute GNULIB_FREE, REPLACE_FREE.
* m4/free.m4 (gl_FUNC_FREE): Set REPLACE_FREE, instead of defining
'free' as a macro here.
* modules/free (Depends-on): Add stdlib.
(configure.ac): Test REPLACE_FREE. Invoke gl_STDLIB_MODULE_INDICATOR.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reported by Daniel R. Hurtmans <Daniel.Hurtmans@ulb.ac.be> in
<https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00029.html>.
* lib/c++defs.h (_GL_CXXALIAS_MDA_CAST): New macro.
* lib/fcntl.in.h (creat, open): In C++ mode, when GNULIB_NAMESPACE is
defined: 1. Define a symbol in this namespace. 2. Don't redirect using
a preprocessor #define.
* lib/math.in.h (j0, j1, jn, y0, y1, yn): Likewise.
* lib/search.in.h (lfind, lsearch): Likewise.
* lib/stdio.in.h (fcloseall, fdopen, fileno, getw, putw, tempnam):
Likewise.
* lib/stdlib.in.h (ecvt, fcvt, gcvt, mktemp, putenv): Likewise.
* lib/string.in.h (memccpy, strdup): Likewise.
* lib/sys_stat.in.h (chmod, umask): Likewise.
* lib/time.in.h (tzset): Likewise.
* lib/unistd.in.h (access, chdir, close, dup, dup2, execl, execle,
execlp, execv, execve, execvp, execvpe, getcwd, getpid, isatty, lseek,
read, rmdir, swab, unlink, write): Likewise.
* lib/utime.in.h (utime): Likewise.
* lib/wchar.in.h (wcsdup): Likewise.
* m4/stdio_h.m4 (gl_STDIO_H_DEFAULTS): Initialize HAVE_DECL_FCLOSEALL.
(gl_STDIO_H): Set HAVE_DECL_FCLOSEALL.
* modules/stdio (Makefile.am): Substitute HAVE_DECL_FCLOSEALL.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize HAVE_DECL_ECVT,
HAVE_DECL_FCVT, HAVE_DECL_GCVT.
(gl_STDLIB_H): Set HAVE_DECL_ECVT, HAVE_DECL_FCVT, HAVE_DECL_GCVT.
* modules/stdlib (Makefile.am): Substitute HAVE_DECL_ECVT,
HAVE_DECL_FCVT, HAVE_DECL_GCVT.
* m4/unistd_h.m4 (gl_UNISTD_H_DEFAULTS): Initialize HAVE_DECL_EXECVPE.
(gl_UNISTD_H): Set HAVE_DECL_EXECVPE.
* modules/unistd (Makefile.am): Substitute HAVE_DECL_EXECVPE.
* m4/wchar_h.m4 (gl_WCHAR_H_DEFAULTS): Initialize HAVE_DECL_WCSDUP.
(gl_WCHAR_H): Set HAVE_DECL_WCSDUP.
* modules/wchar (Makefile.am): Substitute HAVE_DECL_WCSDUP.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h (aligned_alloc): New declaration.
* lib/aligned_alloc.c: New file.
* m4/aligned_alloc.m4: New file.
* m4/stdlib_h.m4 (gl_STDLIB_H): Test whether aligned_alloc is declared.
(gl_STDLIB_H_DEFAULTS): Initialize GNULIB_ALIGNED_ALLOC,
HAVE_ALIGNED_ALLOC, REPLACE_ALIGNED_ALLOC.
* modules/stdlib (Makefile.am): Substitute GNULIB_ALIGNED_ALLOC,
HAVE_ALIGNED_ALLOC, REPLACE_ALIGNED_ALLOC.
* modules/aligned_alloc: New file.
* tests/test-stdlib-c++.cc (aligned_alloc): Check signature.
* doc/posix-functions/aligned_alloc.texi: Mention the new module and the
AIX bug.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h (posix_memalign): New declaration.
* lib/posix_memalign.c: New file.
* m4/posix_memalign.m4: New file.
* m4/stdlib_h.m4 (gl_STDLIB_H): Test whether posix_memalign is declared.
(gl_STDLIB_H_DEFAULTS): Initialize GNULIB_POSIX_MEMALIGN,
HAVE_POSIX_MEMALIGN, REPLACE_POSIX_MEMALIGN.
* modules/stdlib (Makefile.am): Substitute GNULIB_POSIX_MEMALIGN,
HAVE_POSIX_MEMALIGN, REPLACE_POSIX_MEMALIGN.
* modules/posix_memalign: New file.
* tests/test-stdlib-c++.cc (posix_memalign): Check signature.
* doc/posix-functions/posix_memalign.texi: Mention the new module and
the OpenBSD bug.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/iconv.in.h (iconv): Use 'restrict'.
* lib/inttypes.in.h (strtoimax, strtoumax): Likewise.
* lib/monetary.in.h (strfmon_l): Likewise.
* lib/pthread.in.h (pthread_create, pthread_mutex_init,
pthread_mutexattr_gettype, pthread_mutexattr_getrobust,
pthread_mutex_timedlock, pthread_rwlock_init,
pthread_rwlock_timedrdlock, pthread_rwlock_timedwrlock,
pthread_cond_init, pthread_cond_wait, pthread_cond_timedwait): Likewise.
* lib/search.in.h (tdelete): Likewise.
* lib/signal.in.h (pthread_sigmask, sigprocmask): Likewise.
* lib/stdio.in.h (dprintf, fgets, fopen, fprintf, fputs, fread, freopen,
fscanf, fwrite, getdelim, getline, printf, scanf, snprintf, sprintf,
vdprintf, vfprintf, vfscanf, vprintf, vscanf, vsnprintf, vsprintf):
Likewise.
* lib/stdlib.in.h (mbtowc, realpath, strtod, strtold, strtoll,
strtoull): Likewise.
* lib/string.in.h (strncat): Likewise.
* lib/sys_socket.in.h (accept, getpeername, getsockname, getsockopt,
recvfrom): Likewise.
* lib/sys_stat.in.h (fstatat, lstat, stat): Likewise.
* lib/time.in.h (strftime): Likewise.
* lib/unistd.in.h (readlink, readlinkat): Likewise.
* lib/wchar.in.h (mbrtowc, mbrlen, mbsrtowcs, mbsnrtowcs, wcrtomb,
wcsrtombs, wcsnrtombs, wmemcpy, wcscpy, wcpcpy, wcsncpy, wcpncpy,
wcscat, wcsncat, wcsxfrm, wcsstr, wcstok, wcsftime): Likewise.
* m4/iconv_h.m4 (gl_ICONV_H): Require AC_C_RESTRICT.
* m4/inttypes.m4 (gl_INTTYPES_INCOMPLETE): Likewise.
* m4/monetary_h.m4 (gl_MONETARY_H): Likewise.
* m4/search_h.m4 (gl_SEARCH_H): Likewise.
* m4/signal_h.m4 (gl_SIGNAL_H): Likewise.
* m4/stdio_h.m4 (gl_STDIO_H): Likewise.
* m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
* m4/sys_socket_h.m4 (gl_HEADER_SYS_SOCKET): Likewise.
* m4/sys_stat_h.m4 (gl_HEADER_SYS_STAT_H): Likewise.
* m4/unistd_h.m4 (gl_UNISTD_H): Likewise.
* m4/wchar_h.m4 (gl_WCHAR_H): Likewise.
* m4/string_h.m4 (gl_HEADER_STRING_H_BODY): Make consistent with the
other *_h.m4 files.
* m4/time_h.m4 (gl_HEADER_TIME_H): Likewise.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h (strtold): New declaration.
* lib/strtold.c: New file.
* lib/strtod.c: Consider USE_LONG_DOUBLE.
(STRTOD, LDEXP, HAVE_UNDERLYING_STRTOD, DOUBLE, MIN, MAX, L_,
USE_LDEXP): New macros.
(LDEXP, scale_radix_exp, parse_number, STRTOD): Adapt for
USE_LONG_DOUBLE.
(underlying_strtod): Remove function. Replace with some macros.
Re-add the code for a missing underlying function that was removed on
2013-02-19.
* m4/strtold.m4: New file.
* m4/stdlib_h.m4 (gl_STDLIB_H): Test whether strtold is declared.
(gl_STDLIB_H_DEFAULTS): Initialize GNULIB_STRTOLD, HAVE_STRTOLD,
REPLACE_STRTOLD.
* modules/stdlib (Makefile.am): Substitute GNULIB_STRTOLD, HAVE_STRTOLD,
REPLACE_STRTOLD.
* modules/strtold: New file.
* doc/posix-functions/strtold.texi: Document the new module.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h (random, srandom): Test also REPLACE_RANDOM.
(initstate): Test REPLACE_INITSTATE and HAVE_INITSTATE, not HAVE_RANDOM.
(setstate): Test REPLACE_SETSTATE and HAVE_SETSTATE, not HAVE_RANDOM.
* m4/random.m4 (gl_FUNC_RANDOM): Set HAVE_INITSTATE, HAVE_SETSTATE,
REPLACE_RANDOM, REPLACE_INITSTATE, REPLACE_SETSTATE.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize HAVE_INITSTATE,
HAVE_SETSTATE, REPLACE_RANDOM, REPLACE_INITSTATE, REPLACE_SETSTATE.
* modules/stdlib (Makefile.am): Substitute HAVE_INITSTATE, HAVE_SETSTATE,
REPLACE_RANDOM, REPLACE_INITSTATE, REPLACE_SETSTATE.
* modules/random (Depends-on, configure.ac): Test also REPLACE_RANDOM,
REPLACE_INITSTATE, REPLACE_SETSTATE.
* doc/posix-functions/random.texi: Correct the description of the
situation on Android.
* doc/posix-functions/srandom.texi: Likewise.
* doc/posix-functions/rand.texi: Likewise.
* doc/posix-functions/srand.texi: Likewise.
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h (mbtowc): Test also HAVE_MBTOWC.
* m4/mbtowc.m4 (gl_FUNC_MBTOWC): Test whether mbtowc exists. Set
HAVE_MBTOWC.
* m4/stdlib_h.m4 (gl_STDLIB_H): Test whether mbtowc is declared.
(gl_STDLIB_H_DEFAULTS): Initialize HAVE_MBTOWC.
* modules/stdlib (Makefile.am): Substitute HAVE_MBTOWC.
* modules/mbtowc (Depends-on, configure.ac): Test also HAVE_MBTOWC.
* doc/posix-functions/mbtowc.texi: Mention the change.
|
| |
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h: Before including <sys/loadavg.h>, include
<sys/time.h>.
* m4/stdlib_h.m4 (gl_STDLIB_H): Likewise.
* m4/getloadavg.m4 (gl_GETLOADAVG): Likewise.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize HAVE_DECL_INITSTATE,
HAVE_DECL_SETSTATE.
* m4/random.m4 (gl_FUNC_RANDOM): Test whether initstate and setstate are
declared.
* modules/stdlib (Makefile.am): Substitute HAVE_DECL_INITSTATE,
HAVE_DECL_SETSTATE.
* lib/stdlib.in.h (initstate): Declare also if HAVE_DECL_INITSTATE is 0.
(setstate): Declare also if HAVE_DECL_SETSTATE is 0.
* doc/posix-functions/initstate.texi: Mention the Cygwin 1.5.x problem.
* doc/posix-functions/random.texi: Likewise.
* doc/posix-functions/setstate.texi: Likewise.
* doc/posix-functions/srandom.texi: Likewise.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
reallocarray is a new function in glibc 2.26 to safely allocate an array
of memory locations with integer overflow protection.
* MODULES.html.sh: Add reallocarray.
* doc/glibc-functions/reallocarray.texi: Documentation for reallocarray.
* lib/reallocarray.c: New file to implement module reallocarray.
* lib/stdlib.in.h: Add function declarations for reallocarray.
* m4/reallocarray.m4: New file.
* m4/stdlib_h.m4: Declare reallocarray.
* modules/reallocarray: New file.
* modules/reallocarray-test: New file.
* modules/stdlib: Coerce stdlib.h to export reallocarray.
* tests/test-reallocarray.c: New test.
|
|
|
|
|
|
|
|
|
|
| |
* build-aux/gendocs.sh (version):
* doc/gendocs_template:
* doc/gendocs_template_min:
* doc/gnulib.texi:
* lib/version-etc.c (COPYRIGHT_YEAR):
Update copyright dates by hand in templates and the like.
* all files: Run 'make update-copyright'.
|
|
|
|
|
|
|
|
|
|
|
| |
* m4/stdlib_h.m4 (gl_STDLIB_H): Check for qsort_r.
(gl_STDLIB_H_DEFAULTS): Initialize HAVE_QSORT_R.
* modules/stdlib (Makefile.am): Substitute HAVE_QSORT_R.
* lib/stdlib.in.h (qsort_r): Provide declaration if the function does
not exist.
* m4/qsort_r.m4 (gl_FUNC_QSORT_R): Use AC_CHECK_FUNCS to test whether
the function exists.
* modules/qsort_r: Add comments.
|
|
|
|
|
|
|
|
|
|
| |
* build-aux/gendocs.sh (version):
* doc/gendocs_template:
* doc/gendocs_template_min:
* doc/gnulib.texi:
* lib/version-etc.c (COPYRIGHT_YEAR):
Update copyright dates by hand in templates and the like.
* all files: Run 'make update-copyright'.
|
|
|
|
|
|
| |
* doc/gnulib.texi:
* lib/version-etc.c (COPYRIGHT_YEAR): Update copyright date.
* all files: Run 'make update-copyright'.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This works even on FreeBSD, which has an incompatible qsort_r API.
* MODULES.html.sh: Add it.
* doc/glibc-functions/qsort_r.texi: It's now supported.
* lib/qsort.c: New file, taken from glibc with minor changes
inside "#ifndef _LIBC" and with an unnecessary "#include <alloca.h>"
removed.
* lib/qsort_r.c: New file, compiled only on FreeBSD.
* lib/stdlib.in.h (qsort_r): Declare in the usual way.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS):
* modules/qsort_r, modules/qsort_r-tests: New files.
* modules/stdlib (Makefile): Set up its defaults.
* tests/test-qsort_r.c: New file.
|
|
|
|
|
|
| |
I ran 'make update-copyright'.
Signed-off-by: Eric Blake <eblake@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* MODULES.html.sh (Extra functions based on ANSI C 89):
Add secure_getenv.
* doc/glibc-functions/secure_getenv.texi: New file.
* doc/gnulib.texi: Include it.
* lib/secure_getenv.c, m4/secure_getenv.m4, modules/secure_getenv:
New files.
* lib/stdlib.in.h (secure_getenv): New decl.
* m4/stdlib_h.m4 (gl_STDLIB_H, gl_STDLIB_H_DEFAULTS):
* modules/stdlib (stdlib.h):
Add secure_getenv checks.
|
|
|
|
|
|
| |
Run "make update-copyright". Compare to commit 1602f0a from last year.
Signed-off-by: Eric Blake <eblake@redhat.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
POSIX left errno undefined on ptsname() failure, although there
has at least been an effort to specify reasonable values to use:
http://www.austingroupbugs.net/view.php?id=503
However, our tests for ptsname and ptsname_r already require errno
to be set to useful values (as in glibc), so it is worth replacing
ptsname on FreeBSD 8.2 in order to get better QoI and pass the test.
* m4/ptsname.m4 (gl_FUNC_PTSNAME): Probe for FreeBSD bug.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Add new witness.
* modules/stdlib (Makefile.am): Replace witness.
* lib/stdlib.in.h (ptsname): Allow for replacement.
* modules/ptsname (configure.ac): Trigger replacement.
* doc/posix-functions/ptsname.texi (ptsname): Document this.
|
|
|
|
|
| |
* m4/stdlib_h.m4 (gl_STDLIB_H): Test whether random, srandom,
initstate, setstate are declared.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/stdlib.in.h (random, srandom, initstate, setstate): New
declarations.
* lib/random.c: New file, based on glibc/stdlib/random.c.
* m4/random.m4: New file.
* m4/stdlib_h.m4 (gl_STDLIB_H_DEFAULTS): Initialize GNULIB_RANDOM,
HAVE_RANDOM.
* modules/stdlib (Makefile.am): Substitute GNULIB_RANDOM, HAVE_RANDOM.
* modules/random: New file.
* config/srclist.txt: Add an entry for random.c.
* doc/posix-functions/random.texi: Mention the 'random' module.
* doc/posix-functions/initstate.texi: Likewise.
* doc/posix-functions/setstate.texi: Likewise.
* doc/posix-functions/srandom.texi: Likewise.
|